소스 검색

add content description to activity icon

AndyScherzinger 7 년 전
부모
커밋
b8260646da
1개의 변경된 파일27개의 추가작업 그리고 10개의 파일을 삭제
  1. 27 10
      src/main/res/layout/activity_row.xml

+ 27 - 10
src/main/res/layout/activity_row.xml

@@ -16,18 +16,35 @@
   You should have received a copy of the GNU General Public License
   along with this program.  If not, see <http://www.gnu.org/licenses/>.
 -->
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+	android:id="@+id/list_item"
+	android:layout_width="match_parent"
+	android:layout_height="48dp"
+	android:background="?android:attr/activatedBackgroundIndicator"
+	android:minWidth="@dimen/activity_row_layout_min_width_independent"
+	android:orientation="horizontal"
+	android:paddingEnd="@dimen/standard_padding"
+	android:paddingLeft="@dimen/standard_padding"
+	android:paddingRight="@dimen/standard_padding"
+	android:paddingStart="@dimen/standard_padding">
 
-	<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-		android:id="@+id/list_item"
+	<ImageView
+		android:id="@+id/icon"
+		android:layout_width="@dimen/user_icon_size_independent"
+		android:layout_height="@dimen/user_icon_size_independent"
+		android:layout_gravity="center_vertical"
+		android:layout_marginEnd="@dimen/standard_padding"
+		android:layout_marginRight="@dimen/standard_padding"
+		android:contentDescription="@string/activity_icon" />
+
+	<TextView
+		android:id="@+id/title"
 		android:layout_width="match_parent"
-		android:layout_height="48dp"
-		android:paddingStart="@dimen/standard_padding"
-		android:paddingEnd="@dimen/standard_padding"
-		android:paddingRight="@dimen/standard_padding"
-		android:paddingLeft="@dimen/standard_padding"
-		android:minWidth="@dimen/activity_row_layout_min_width_independent"
-		android:background="?android:attr/activatedBackgroundIndicator"
-		android:orientation="horizontal" >
+		android:layout_height="wrap_content"
+		android:layout_gravity="center_vertical"
+		android:ellipsize="marquee"
+		android:singleLine="true"
+		android:textAppearance="?android:attr/textAppearanceLargePopupMenu" />
 
 		<ImageView
 			android:id="@+id/icon"