1 <?xml version="1.0" encoding="utf-8"?> 2 <!-- 3 ~ Copyright (C) 2015 The Android Open Source Project 4 ~ 5 ~ Licensed under the Apache License, Version 2.0 (the "License"); 6 ~ you may not use this file except in compliance with the License. 7 ~ You may obtain a copy of the License at 8 ~ 9 ~ http://www.apache.org/licenses/LICENSE-2.0 10 ~ 11 ~ Unless required by applicable law or agreed to in writing, software 12 ~ distributed under the License is distributed on an "AS IS" BASIS, 13 ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 ~ See the License for the specific language governing permissions and 15 ~ limitations under the License. 16 --> 17 18 <com.android.tv.menu.ActionCardView 19 xmlns:android="http://schemas.android.com/apk/res/android" 20 android:layout_width="@dimen/action_card_width" 21 android:layout_height="@dimen/action_card_height" 22 android:orientation="vertical" 23 android:focusable="true" 24 android:background="@drawable/action_card_background"> 25 26 <LinearLayout 27 android:orientation="vertical" 28 android:layout_width="match_parent" 29 android:layout_height="wrap_content" 30 android:padding="@dimen/action_card_padding" 31 android:clipChildren="false" 32 android:clipToPadding="false" 33 android:layout_gravity="top"> 34 35 <TextView 36 android:id="@+id/action_card_label" 37 android:layout_width="match_parent" 38 android:layout_height="wrap_content" 39 android:layout_marginTop="-6dp" 40 android:singleLine="true" 41 android:fontFamily="@string/condensed_font" 42 android:textColor="@color/action_card_label_color" 43 android:textSize="@dimen/action_card_label_font_size" /> 44 45 <TextView 46 android:id="@+id/action_card_state" 47 android:layout_width="match_parent" 48 android:layout_height="wrap_content" 49 android:paddingTop="4dp" 50 android:singleLine="true" 51 android:fontFamily="@string/condensed_font" 52 android:textColor="@color/action_card_state_color" 53 android:textSize="@dimen/action_card_state_font_size" /> 54 55 </LinearLayout> 56 57 <ImageView 58 android:id="@+id/action_card_icon" 59 android:layout_width="@dimen/action_card_icon_width" 60 android:layout_height="@dimen/action_card_icon_height" 61 android:layout_margin="@dimen/action_card_icon_padding" 62 android:layout_gravity="end|bottom" 63 android:contentDescription="@null" 64 android:scaleType="fitCenter" 65 android:src="@drawable/ic_tvoption_aspect" 66 android:duplicateParentState="true" /> 67 68 </com.android.tv.menu.ActionCardView> 69