• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (C) 2011 The Android Open Source Project
3
4     Licensed under the Apache License, Version 2.0 (the "License");
5     you may not use this file except in compliance with the License.
6     You may obtain a copy of the License at
7
8          http://www.apache.org/licenses/LICENSE-2.0
9
10     Unless required by applicable law or agreed to in writing, software
11     distributed under the License is distributed on an "AS IS" BASIS,
12     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13     See the License for the specific language governing permissions and
14     limitations under the License.
15-->
16
17<view
18    xmlns:android="http://schemas.android.com/apk/res/android"
19    class="com.android.contacts.detail.CarouselTab"
20    android:layout_width="0dip"
21    android:layout_height="match_parent"
22    android:layout_weight="1">
23
24    <RelativeLayout
25        android:layout_width="match_parent"
26        android:layout_height="match_parent" >
27
28        <ImageView android:id="@+id/photo"
29            android:scaleType="centerCrop"
30            android:layout_width="match_parent"
31            android:layout_height="match_parent"
32            android:layout_alignParentTop="true"
33            android:layout_alignParentLeft="true"
34            android:layout_alignParentStart="true"/>
35
36        <View android:id="@+id/photo_overlay"
37            android:background="?android:attr/selectableItemBackground"
38            android:layout_width="match_parent"
39            android:layout_height="match_parent"
40            android:layout_alignParentTop="true"
41            android:layout_alignParentLeft="true"
42            android:layout_alignParentStart="true"/>
43
44        <!-- Transparent view to overlay on the contact's photo
45        (to allow white text to appear over a white photo). -->
46        <View android:id="@+id/label_background"
47            android:layout_width="match_parent"
48            android:layout_height="@dimen/detail_tab_carousel_tab_label_height"
49            android:layout_alignParentLeft="true"
50            android:layout_alignParentStart="true"
51            android:layout_alignParentBottom="true"
52            android:background="#7F000000" />
53
54        <View
55            android:id="@+id/alpha_overlay"
56            android:layout_width="match_parent"
57            android:layout_height="match_parent"
58            android:layout_alignParentLeft="true"
59            android:layout_alignParentStart="true"
60            android:layout_alignParentTop="true"
61            android:layout_marginBottom="@dimen/detail_tab_carousel_tab_label_height"/>
62
63        <TextView
64            android:id="@+id/label"
65            android:layout_width="match_parent"
66            android:layout_height="@dimen/detail_tab_carousel_tab_label_height"
67            android:layout_alignParentLeft="true"
68            android:layout_alignParentStart="true"
69            android:layout_alignParentBottom="true"
70            android:paddingLeft="@dimen/detail_tab_carousel_tab_label_indent"
71            android:paddingStart="@dimen/detail_tab_carousel_tab_label_indent"
72            android:singleLine="true"
73            android:gravity="left|center_vertical"
74            android:textAppearance="?android:attr/textAppearanceMedium"
75            android:textColor="@color/detail_tab_carousel_tab_label_color"
76            style="@android:style/Widget.Holo.ActionBar.TabView" />
77
78    </RelativeLayout>
79
80</view>
81