• 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<!-- tablet -->
18
19<RelativeLayout
20    xmlns:android="http://schemas.android.com/apk/res/android"
21    android:layout_width="match_parent"
22    android:layout_height="49dip"
23    android:layout_marginBottom="-1dip"
24    >
25    <View
26        android:id="@+id/divider"
27        android:layout_width="match_parent"
28        android:layout_marginRight="@dimen/message_compose_header_button_area_width"
29        android:layout_alignParentBottom="true"
30        style="@style/message_compose_horizontal_divider"
31        />
32    <ImageView
33        android:id="@+id/icon"
34        android:layout_width="wrap_content"
35        android:layout_height="48dip"
36        android:layout_marginRight="16dip"
37        android:layout_alignParentTop="true"
38        android:layout_alignParentLeft="true"
39        android:src="@drawable/ic_attachment_holo_light"
40        android:gravity="center"
41        />
42    <!--
43        Use FrameLayout to left-align the button image, within the width of
44        @dimen/message_compose_header_button_area_width
45    -->
46    <FrameLayout
47        android:id="@+id/attachment_delete_frame"
48        android:layout_width="@dimen/message_compose_header_button_area_width"
49        android:layout_height="48dip"
50        android:layout_alignParentTop="true"
51        android:layout_alignParentRight="true"
52        android:layout_gravity="center_vertical|left"
53        >
54        <ImageButton
55            android:id="@+id/attachment_delete"
56            android:layout_width="wrap_content"
57            android:layout_height="match_parent"
58            style="@android:style/Widget.Holo.Button.Borderless"
59            android:src="@drawable/ic_remove_attachment_holo_light"
60            android:gravity="left|center_vertical"
61            android:paddingTop="0dip"
62            android:paddingBottom="0dip"
63            android:paddingLeft="16dip"
64            android:paddingRight="0dip"
65            />
66    </FrameLayout>
67    <TextView
68        android:id="@+id/attachment_size"
69        android:layout_width="wrap_content"
70        android:layout_height="48dip"
71        android:layout_marginLeft="8dip"
72        android:layout_alignParentTop="true"
73        android:layout_toLeftOf="@id/attachment_delete_frame"
74        android:textSize="14dip"
75        android:textColor="@color/text_secondary_color"
76        android:gravity="center_vertical|right"
77        android:singleLine="true"
78        />
79    <TextView
80        android:id="@+id/attachment_name"
81        android:layout_width="0dip"
82        android:layout_height="48dip"
83        android:layout_alignParentTop="true"
84        android:layout_toRightOf="@id/icon"
85        android:layout_toLeftOf="@id/attachment_size"
86        android:textSize="18dip"
87        android:textColor="@color/text_secondary_color"
88        android:gravity="center_vertical|left"
89        android:singleLine="true"
90        android:ellipsize="start"
91        />
92    <!-- TODO Show file size -->
93</RelativeLayout>
94