Pixel perfect work for phone contact editor
- Always show account header for raw contacts
- Align text fields and titles along the left margin
- Align spinners
- Use "Add new" as the default text if there's no value
in Event or Groups field yet
- Restyle account header
- Use primary/secondary colors everywhere
- Non-editable contact fixes: remove "not editable on
this device" and replace it with a toast when the
user clicks on the header, restyle item_read_only_field
Bug: 5097095
Change-Id: I94a6c91b05344028b64c62735fb4559f9944529d
diff --git a/AndroidManifest.xml b/AndroidManifest.xml
index 9d5381a..3f5d15c 100644
--- a/AndroidManifest.xml
+++ b/AndroidManifest.xml
@@ -389,7 +389,7 @@
<!-- Create a new or edit an existing group -->
<activity
android:name=".activities.GroupEditorActivity"
- android:theme="@style/ContactEditorActivityTheme"
+ android:theme="@style/EditorActivityTheme"
android:windowSoftInputMode="adjustResize" />
<!-- Used to show QuickContact window over a translucent activity, which is a
@@ -503,7 +503,7 @@
<!-- Create a new or edit an existing contact -->
<activity
android:name=".activities.ContactEditorActivity"
- android:theme="@style/ContactEditorActivityTheme"
+ android:theme="@style/EditorActivityTheme"
android:uiOptions="splitActionBarWhenNarrow"
android:windowSoftInputMode="adjustResize">
diff --git a/res/drawable-hdpi/change_photo_box_focused_holo_light.9.png b/res/drawable-hdpi/change_photo_box_focused_holo_light.9.png
deleted file mode 100644
index 5254473..0000000
--- a/res/drawable-hdpi/change_photo_box_focused_holo_light.9.png
+++ /dev/null
Binary files differ
diff --git a/res/drawable-hdpi/change_photo_box_normal_holo_light.9.png b/res/drawable-hdpi/change_photo_box_normal_holo_light.9.png
deleted file mode 100644
index f026cc8..0000000
--- a/res/drawable-hdpi/change_photo_box_normal_holo_light.9.png
+++ /dev/null
Binary files differ
diff --git a/res/drawable-hdpi/change_photo_box_pressed_holo_light.9.png b/res/drawable-hdpi/change_photo_box_pressed_holo_light.9.png
deleted file mode 100644
index a0770ea..0000000
--- a/res/drawable-hdpi/change_photo_box_pressed_holo_light.9.png
+++ /dev/null
Binary files differ
diff --git a/res/drawable-mdpi/change_photo_box_focused_holo_light.9.png b/res/drawable-mdpi/change_photo_box_focused_holo_light.9.png
deleted file mode 100644
index 47fb773..0000000
--- a/res/drawable-mdpi/change_photo_box_focused_holo_light.9.png
+++ /dev/null
Binary files differ
diff --git a/res/drawable-mdpi/change_photo_box_normal_holo_light.9.png b/res/drawable-mdpi/change_photo_box_normal_holo_light.9.png
deleted file mode 100644
index 591e6d5..0000000
--- a/res/drawable-mdpi/change_photo_box_normal_holo_light.9.png
+++ /dev/null
Binary files differ
diff --git a/res/drawable-mdpi/change_photo_box_pressed_holo_light.9.png b/res/drawable-mdpi/change_photo_box_pressed_holo_light.9.png
deleted file mode 100644
index 5d5eee2..0000000
--- a/res/drawable-mdpi/change_photo_box_pressed_holo_light.9.png
+++ /dev/null
Binary files differ
diff --git a/res/drawable-xhdpi/change_photo_box_focused_holo_light.9.png b/res/drawable-xhdpi/change_photo_box_focused_holo_light.9.png
deleted file mode 100644
index 7dbd1e6..0000000
--- a/res/drawable-xhdpi/change_photo_box_focused_holo_light.9.png
+++ /dev/null
Binary files differ
diff --git a/res/drawable-xhdpi/change_photo_box_normal_holo_light.9.png b/res/drawable-xhdpi/change_photo_box_normal_holo_light.9.png
deleted file mode 100644
index 7e1e97f..0000000
--- a/res/drawable-xhdpi/change_photo_box_normal_holo_light.9.png
+++ /dev/null
Binary files differ
diff --git a/res/drawable-xhdpi/change_photo_box_pressed_holo_light.9.png b/res/drawable-xhdpi/change_photo_box_pressed_holo_light.9.png
deleted file mode 100644
index e98266f..0000000
--- a/res/drawable-xhdpi/change_photo_box_pressed_holo_light.9.png
+++ /dev/null
Binary files differ
diff --git a/res/drawable/change_photo_box_holo_light.xml b/res/drawable/change_photo_box_holo_light.xml
deleted file mode 100644
index f08beb0..0000000
--- a/res/drawable/change_photo_box_holo_light.xml
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2009 The Android Open Source Project
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
--->
-
-<selector xmlns:android="http://schemas.android.com/apk/res/android">
- <item android:state_window_focused="false"
- android:drawable="@drawable/change_photo_box_normal_holo_light" />
- <item android:state_pressed="true"
- android:drawable="@drawable/change_photo_box_pressed_holo_light" />
- <item android:state_focused="true"
- android:drawable="@drawable/change_photo_box_focused_holo_light" />
- <item
- android:drawable="@drawable/change_photo_box_normal_holo_light" />
-</selector>
diff --git a/res/layout-sw580dp/event_field_editor_view.xml b/res/layout-sw580dp/event_field_editor_view.xml
index f31b283..822de37 100644
--- a/res/layout-sw580dp/event_field_editor_view.xml
+++ b/res/layout-sw580dp/event_field_editor_view.xml
@@ -39,7 +39,6 @@
<include
android:id="@+id/spinner"
layout="@layout/edit_spinner"
- android:paddingTop="15dip"
android:visibility="gone" />
<include
diff --git a/res/layout-sw580dp/external_raw_contact_editor_view.xml b/res/layout-sw580dp/external_raw_contact_editor_view.xml
index b185c8a..fba5220 100644
--- a/res/layout-sw580dp/external_raw_contact_editor_view.xml
+++ b/res/layout-sw580dp/external_raw_contact_editor_view.xml
@@ -22,8 +22,7 @@
android:orientation="vertical">
<include
- layout="@layout/raw_contact_editor_header"
- android:id="@+id/header" />
+ layout="@layout/editor_account_header" />
<LinearLayout
android:id="@+id/body"
diff --git a/res/layout-sw580dp/raw_contact_editor_header.xml b/res/layout-sw580dp/raw_contact_editor_header.xml
deleted file mode 100644
index 498998d..0000000
--- a/res/layout-sw580dp/raw_contact_editor_header.xml
+++ /dev/null
@@ -1,68 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2010 The Android Open Source Project
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
--->
-
-
-<!-- Account info header -->
-<FrameLayout
- xmlns:android="http://schemas.android.com/apk/res/android"
- android:layout_height="64dip"
- android:layout_width="match_parent">
-
- <RelativeLayout
- android:id="@+id/account"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:background="?android:attr/selectableItemBackground">
-
- <ImageView
- android:id="@+id/account_icon"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:layout_marginLeft="7dip"
- android:layout_marginRight="7dip"
- android:layout_centerVertical="true"
- android:layout_alignParentRight="true"
- android:layout_below="@id/header_color_bar" />
-
- <TextView
- android:id="@+id/account_type"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:layout_toLeftOf="@+id/account_icon"
- android:layout_alignTop="@id/account_icon"
- android:layout_marginTop="-4dip"
- android:textAppearance="?android:attr/textAppearanceMedium"
- android:textColor="?android:attr/textColorPrimary"
- android:singleLine="true" />
-
- <TextView
- android:id="@+id/account_name"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:layout_toLeftOf="@+id/account_icon"
- android:layout_alignBottom="@+id/account_icon"
- android:layout_marginBottom="2dip"
-
- android:textAppearance="?android:attr/textAppearanceSmall"
- android:textColor="?android:attr/textColorPrimary"
- android:singleLine="true" />
-
- <include
- android:id="@+id/divider"
- android:layout_alignParentBottom="true"
- layout="@layout/edit_divider" />
- </RelativeLayout>
-</FrameLayout>
\ No newline at end of file
diff --git a/res/layout-sw580dp/raw_contact_editor_view.xml b/res/layout-sw580dp/raw_contact_editor_view.xml
index 9c3f708..11fc161 100644
--- a/res/layout-sw580dp/raw_contact_editor_view.xml
+++ b/res/layout-sw580dp/raw_contact_editor_view.xml
@@ -21,14 +21,8 @@
android:layout_height="wrap_content"
android:orientation="vertical">
- <FrameLayout
- android:id="@+id/anchor_for_account_switcher"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content">
- <include
- layout="@layout/raw_contact_editor_header"
- android:id="@+id/header" />
- </FrameLayout>
+ <include
+ layout="@layout/editor_account_header" />
<LinearLayout
android:id="@+id/body"
@@ -124,8 +118,8 @@
<com.android.contacts.widget.InterpolatingLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_marginTop="10dip"
- android:layout_marginBottom="42dip">
+ android:layout_marginTop="16dip"
+ android:layout_marginBottom="32dip">
<Button
android:id="@+id/button_add_field"
android:text="@string/add_field"
diff --git a/res/layout/edit_add_field.xml b/res/layout/edit_add_field.xml
index 31ea05d..b17185d 100644
--- a/res/layout/edit_add_field.xml
+++ b/res/layout/edit_add_field.xml
@@ -17,7 +17,8 @@
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:paddingLeft="13dip"
+ android:minHeight="48dip"
+ android:paddingLeft="16dip"
android:background="?android:attr/selectableItemBackground">
<TextView
android:id="@+id/add_text"
@@ -26,6 +27,6 @@
android:layout_height="wrap_content"
android:duplicateParentState="true"
android:textAppearance="?android:attr/textAppearanceMedium"
- android:textColor="?android:attr/textColorTertiary"
+ android:textColor="?android:attr/textColorSecondary"
android:text="@string/add_new_entry_for_section" />
</FrameLayout>
\ No newline at end of file
diff --git a/res/layout/edit_date_picker.xml b/res/layout/edit_date_picker.xml
index c18d607..5122bbe 100644
--- a/res/layout/edit_date_picker.xml
+++ b/res/layout/edit_date_picker.xml
@@ -19,10 +19,11 @@
<Button
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/date_view"
+ style="?android:attr/spinnerStyle"
android:layout_width="0dip"
android:layout_height="wrap_content"
android:layout_weight="1"
android:layout_marginLeft="@dimen/editor_field_left_padding"
android:layout_marginRight="@dimen/editor_field_right_padding"
android:textAppearance="?android:attr/textAppearanceMedium"
- style="@android:style/Widget.Holo.Light.Spinner" />
\ No newline at end of file
+ android:paddingLeft="16dip" />
\ No newline at end of file
diff --git a/res/layout/edit_expansion_view.xml b/res/layout/edit_expansion_view.xml
index 96fe8de..267593d 100644
--- a/res/layout/edit_expansion_view.xml
+++ b/res/layout/edit_expansion_view.xml
@@ -19,12 +19,12 @@
<FrameLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:layout_gravity="top">
+ android:layout_height="match_parent">
<ImageView
android:id="@+id/expansion_view"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
+ android:layout_gravity="top"
android:duplicateParentState="true"
android:background="?android:attr/selectableItemBackground"
android:paddingLeft="@dimen/editor_round_button_padding_left"
diff --git a/res/layout/edit_kind_title.xml b/res/layout/edit_kind_title.xml
index 619ba49..0f755ee 100644
--- a/res/layout/edit_kind_title.xml
+++ b/res/layout/edit_kind_title.xml
@@ -21,22 +21,23 @@
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:paddingLeft="@dimen/editor_field_left_padding"
- android:paddingRight="@dimen/editor_field_right_padding"
+ android:minHeight="24dip"
+ android:paddingLeft="8dip"
+ android:paddingRight="8dip"
android:orientation="vertical">
<TextView
android:id="@+id/kind_title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:paddingLeft="@dimen/editor_field_left_padding"
+ android:paddingLeft="8dip"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="@color/people_app_theme_color"
android:textStyle="bold"
+ android:textAllCaps="true"
android:singleLine="true"
android:ellipsize="end"
- android:paddingTop="5dip"
- android:paddingBottom="2dip" />
+ android:layout_gravity="center_vertical" />
<ImageView
android:id="@+id/divider"
diff --git a/res/layout/edit_spinner.xml b/res/layout/edit_spinner.xml
index 325eb50..37edcbd 100644
--- a/res/layout/edit_spinner.xml
+++ b/res/layout/edit_spinner.xml
@@ -20,8 +20,8 @@
<Spinner
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/spinner"
+ android:layout_gravity="top"
android:layout_width="@dimen/editor_type_label_width"
android:layout_height="wrap_content"
android:paddingLeft="5dip"
- android:paddingRight="20dip"
- android:textAppearance="?android:attr/textAppearanceSmall"/>
\ No newline at end of file
+ android:paddingRight="20dip"/>
\ No newline at end of file
diff --git a/res/layout/editor_account_header.xml b/res/layout/editor_account_header.xml
index fbce1f9..5181708 100644
--- a/res/layout/editor_account_header.xml
+++ b/res/layout/editor_account_header.xml
@@ -16,11 +16,16 @@
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
+ android:id="@+id/account_container"
android:layout_height="wrap_content"
android:layout_width="match_parent"
+ android:minHeight="48dip"
+ android:background="#EEEEEE"
android:orientation="horizontal"
- android:paddingLeft="10dip"
- android:paddingRight="10dip">
+ android:paddingTop="8dip"
+ android:paddingBottom="8dip"
+ android:paddingLeft="16dip"
+ android:paddingRight="16dip">
<LinearLayout
android:id="@+id/account"
@@ -53,8 +58,8 @@
<ImageView
android:id="@+id/account_icon"
- android:layout_width="45dip"
- android:layout_height="45dip"
+ android:layout_width="32dip"
+ android:layout_height="32dip"
android:layout_gravity="center_vertical" />
</FrameLayout>
diff --git a/res/layout/event_field_editor_view.xml b/res/layout/event_field_editor_view.xml
index 0dceafc..6903772 100644
--- a/res/layout/event_field_editor_view.xml
+++ b/res/layout/event_field_editor_view.xml
@@ -35,10 +35,14 @@
android:id="@+id/date_view"
layout="@layout/edit_date_picker" />
- <include
+ <Spinner
android:id="@+id/spinner"
- layout="@layout/edit_spinner"
- android:visibility="gone" />
+ android:layout_width="@dimen/editor_type_label_width"
+ android:layout_height="wrap_content"
+ android:paddingLeft="5dip"
+ android:paddingRight="20dip"
+ android:layout_gravity="bottom"
+ android:visibility="gone"/>
<include
android:id="@+id/delete_button_container"
diff --git a/res/layout/external_raw_contact_editor_view.xml b/res/layout/external_raw_contact_editor_view.xml
index 661371d..6f39b34 100644
--- a/res/layout/external_raw_contact_editor_view.xml
+++ b/res/layout/external_raw_contact_editor_view.xml
@@ -19,90 +19,54 @@
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:orientation="horizontal"
- android:paddingBottom="10dip">
+ android:orientation="vertical">
- <!-- Left side color bar -->
- <ImageView
- android:id="@+id/color_bar"
- android:layout_width="4dip"
- android:layout_height="match_parent"
- android:visibility="gone"/>
+ <include
+ layout="@layout/editor_account_header" />
- <!-- The content -->
<LinearLayout
- android:layout_width="0dip"
android:layout_height="wrap_content"
- android:layout_weight="1"
- android:orientation="vertical">
+ android:layout_width="match_parent"
+ android:orientation="horizontal"
+ android:paddingLeft="16dip"
+ android:paddingRight="16dip">
- <!-- Account info header -->
- <ImageView android:id="@+id/header_color_bar"
- android:layout_width="match_parent"
- android:layout_height="4dip"
- android:layout_marginBottom="5dip"
- android:background="@color/edit_divider"/>
+ <TextView android:id="@+id/read_only_name"
+ android:layout_width="0dip"
+ android:layout_height="match_parent"
+ android:layout_weight="1"
+ android:gravity="center_vertical"
+ android:singleLine="true"
+ android:ellipsize="end"
+ android:textAppearance="?android:attr/textAppearanceMedium"
+ android:textColor="?android:attr/textColorSecondary"
+ android:textStyle="bold"/>
- <TextView
- android:id="@+id/read_only_warning"
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:paddingTop="10dip"
- android:paddingLeft="10dip"
- android:paddingRight="10dip"
- android:textAppearance="?android:attr/textAppearanceSmall"
- android:textColor="?android:attr/textColorTertiary"/>
+ <FrameLayout
+ android:id="@+id/stub_photo"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content">
- <include
- android:id="@+id/account_header"
- layout="@layout/editor_account_header" />
+ <include
+ android:id="@+id/edit_photo"
+ layout="@layout/item_photo_editor" />
- <LinearLayout
- android:layout_height="wrap_content"
- android:layout_width="match_parent"
- android:orientation="horizontal"
- android:paddingTop="20dip"
- android:paddingLeft="10dip"
- android:paddingRight="10dip">
-
- <TextView android:id="@+id/read_only_name"
- android:layout_width="0dip"
- android:layout_height="match_parent"
- android:layout_weight="1"
- android:gravity="center_vertical"
- android:singleLine="true"
- android:ellipsize="end"
- android:textAppearance="?android:attr/textAppearanceMedium"
- android:textColor="?android:attr/textColorTertiary"
- android:textStyle="bold"/>
-
- <FrameLayout
- android:id="@+id/stub_photo"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content">
-
- <include
- android:id="@+id/edit_photo"
- layout="@layout/item_photo_editor" />
-
- </FrameLayout>
-
- </LinearLayout>
-
- <Button
- android:id="@+id/button_edit_externally"
- android:text="@string/edit_contact"
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:layout_marginTop="13dip"
- android:layout_marginBottom="13dip"
- android:layout_marginLeft="13dip"/>
-
- <LinearLayout android:id="@+id/sect_general"
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:orientation="vertical"/>
+ </FrameLayout>
</LinearLayout>
+ <Button
+ android:id="@+id/button_edit_externally"
+ android:text="@string/edit_contact"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_marginTop="13dip"
+ android:layout_marginBottom="13dip"
+ android:layout_marginLeft="13dip"/>
+
+ <LinearLayout android:id="@+id/sect_general"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:orientation="vertical"/>
+
</com.android.contacts.editor.ExternalRawContactEditorView>
diff --git a/res/layout/item_group_membership.xml b/res/layout/item_group_membership.xml
index 62d06ea..b6d11f2 100644
--- a/res/layout/item_group_membership.xml
+++ b/res/layout/item_group_membership.xml
@@ -34,6 +34,6 @@
android:gravity="left|center_vertical"
android:ellipsize="end"
android:focusable="true"
- android:paddingLeft="@dimen/editor_field_left_padding" />
+ android:paddingLeft="16dip" />
</com.android.contacts.editor.GroupMembershipView>
diff --git a/res/layout/item_kind_section.xml b/res/layout/item_kind_section.xml
index 0b6017c..157ca1c 100644
--- a/res/layout/item_kind_section.xml
+++ b/res/layout/item_kind_section.xml
@@ -20,7 +20,6 @@
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:paddingBottom="@dimen/editor_field_bottom_padding"
android:orientation="vertical">
<include
diff --git a/res/layout/item_photo_editor.xml b/res/layout/item_photo_editor.xml
index 3590963..2e73cb2 100644
--- a/res/layout/item_photo_editor.xml
+++ b/res/layout/item_photo_editor.xml
@@ -36,6 +36,6 @@
android:clickable="true"
android:focusable="true"
android:contentDescription="@string/description_contact_photo"
- android:background="@drawable/change_photo_box_holo_light"
+ android:background="?android:attr/selectableItemBackground"
/>
</view>
diff --git a/res/layout/item_read_only_field.xml b/res/layout/item_read_only_field.xml
index 9e0967e..03778cc 100644
--- a/res/layout/item_read_only_field.xml
+++ b/res/layout/item_read_only_field.xml
@@ -16,37 +16,20 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
- android:layout_height="?android:attr/listPreferredItemHeight"
+ android:layout_height="wrap_content"
+ android:orientation="vertical">
- android:orientation="vertical"
->
-
- <TextView android:id="@+id/label"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:layout_marginLeft="10dip"
- android:layout_marginTop="2dip"
-
- android:textAppearance="?android:attr/textAppearanceLarge"
- android:singleLine="true"
- />
+ <include
+ android:id="@+id/kind_title_layout"
+ layout="@layout/edit_kind_title" />
<TextView android:id="@+id/data"
android:layout_width="wrap_content"
android:layout_height="0px"
android:layout_weight="1"
- android:layout_marginLeft="10dip"
- android:layout_marginBottom="4dip"
-
+ android:layout_marginLeft="16dip"
android:textAppearance="?android:attr/textAppearanceMedium"
- android:singleLine="true"
- />
-
- <View
- android:layout_width="match_parent"
- android:layout_height="1px"
-
- android:background="?android:attr/listDivider"
- />
+ android:textColor="?android:attr/textColorSecondary"
+ android:singleLine="true"/>
</LinearLayout>
\ No newline at end of file
diff --git a/res/layout/organization_editor_view_switcher.xml b/res/layout/organization_editor_view_switcher.xml
index c6e16ae..fb21626 100644
--- a/res/layout/organization_editor_view_switcher.xml
+++ b/res/layout/organization_editor_view_switcher.xml
@@ -23,19 +23,22 @@
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:paddingLeft="@dimen/editor_field_left_padding"
- android:paddingRight="@dimen/editor_field_right_padding"
+ android:minHeight="48dip"
android:background="?android:attr/selectableItemBackground">
<TextView
android:id="@+id/add_organization_button"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:paddingLeft="@dimen/editor_field_left_padding"
+ android:paddingLeft="16dip"
+ android:paddingRight="16dip"
+ android:layout_gravity="center_vertical"
+ android:duplicateParentState="true"
android:textAppearance="?android:attr/textAppearanceMedium"
- android:text="@string/organizationLabelsGroup"
- android:duplicateParentState="true"/>
+ android:textColor="?android:attr/textColorSecondary"
+ android:text="@string/add_organization"/>
+ <!-- This is later populated with the actual editable text fields for "organization" -->
<FrameLayout
android:id="@+id/container"
android:layout_width="match_parent"
diff --git a/res/layout/phonetic_name_editor_view.xml b/res/layout/phonetic_name_editor_view.xml
index 832ca2c..6084d3f 100644
--- a/res/layout/phonetic_name_editor_view.xml
+++ b/res/layout/phonetic_name_editor_view.xml
@@ -18,7 +18,6 @@
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:paddingBottom="@dimen/editor_field_bottom_padding"
android:orientation="vertical">
<include
@@ -29,7 +28,6 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_weight="1"
android:orientation="horizontal"
android:gravity="center_vertical"
android:focusable="true"
diff --git a/res/layout/raw_contact_editor_view.xml b/res/layout/raw_contact_editor_view.xml
index 79183cd..b4aa766 100644
--- a/res/layout/raw_contact_editor_view.xml
+++ b/res/layout/raw_contact_editor_view.xml
@@ -20,58 +20,8 @@
android:layout_height="wrap_content"
android:orientation="vertical">
- <LinearLayout
- android:id="@+id/anchor_for_account_switcher"
- android:layout_height="wrap_content"
- android:layout_width="match_parent"
- android:padding="@dimen/account_header_padding"
- android:orientation="horizontal">
-
- <!--
- TODO: Make this "?android:attr/spinnerStyle" but disable the style if this is not a new
- contact. Since styles aren't easily toggled dynamically, it's easier to just create a
- drawable with the spinner triangle as a background asset and just toggle the background.
- -->
- <LinearLayout
- android:id="@+id/account"
- android:layout_height="wrap_content"
- android:layout_width="0dip"
- android:layout_weight="1"
- android:orientation="vertical"
- android:background="?android:attr/selectableItemBackground">
-
- <TextView
- android:id="@+id/account_type"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:textAppearance="?android:attr/textAppearanceMedium"
- android:singleLine="true" />
-
- <TextView
- android:id="@+id/account_name"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:textAppearance="?android:attr/textAppearanceSmall"
- android:textColor="?android:attr/textColorTertiary"
- android:singleLine="true" />
-
- </LinearLayout>
-
- <FrameLayout
- android:layout_width="wrap_content"
- android:layout_height="match_parent">
-
- <ImageView
- android:id="@+id/account_icon"
- android:layout_width="32dip"
- android:layout_height="32dip"
- android:layout_marginLeft="24dip"
- android:layout_marginRight="24dip"
- android:layout_gravity="center_vertical" />
-
- </FrameLayout>
-
- </LinearLayout>
+ <include
+ layout="@layout/editor_account_header" />
<LinearLayout
android:id="@+id/body"
@@ -82,18 +32,30 @@
<LinearLayout
android:layout_height="wrap_content"
android:layout_width="match_parent"
- android:layout_marginRight="4dip"
- android:orientation="horizontal">
+ android:orientation="horizontal"
+ android:paddingTop="8dip">
- <include
- android:id="@+id/edit_name"
- layout="@layout/structured_name_editor_view" />
+ <LinearLayout
+ android:layout_height="wrap_content"
+ android:layout_width="0dip"
+ android:layout_weight="1"
+ android:orientation="vertical">
+
+ <include
+ android:id="@+id/edit_name"
+ layout="@layout/structured_name_editor_view" />
+
+ <include
+ android:id="@+id/edit_phonetic_name"
+ layout="@layout/phonetic_name_editor_view" />
+
+ </LinearLayout>
<FrameLayout
android:id="@+id/stub_photo"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:layout_marginRight="16dip">
+ android:layout_marginRight="8dip">
<include
android:id="@+id/edit_photo"
@@ -103,10 +65,6 @@
</LinearLayout>
- <include
- android:id="@+id/edit_phonetic_name"
- layout="@layout/phonetic_name_editor_view" />
-
<ViewStub android:id="@+id/aggregation_suggestion_stub"
android:inflatedId="@+id/aggregation_suggestion"
android:layout="@layout/aggregation_suggestions"
@@ -126,8 +84,8 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
- android:layout_marginTop="10dip"
- android:layout_marginBottom="10dip"/>
+ android:layout_marginTop="16dip"
+ android:layout_marginBottom="32dip"/>
</LinearLayout>
</com.android.contacts.editor.RawContactEditorView>
diff --git a/res/layout/structured_name_editor_view.xml b/res/layout/structured_name_editor_view.xml
index 3a66d5e..979a0f3 100644
--- a/res/layout/structured_name_editor_view.xml
+++ b/res/layout/structured_name_editor_view.xml
@@ -16,9 +16,8 @@
<com.android.contacts.editor.StructuredNameEditorView
xmlns:android="http://schemas.android.com/apk/res/android"
- android:layout_width="0dip"
+ android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_weight="1"
android:orientation="vertical">
<include
@@ -29,7 +28,6 @@
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_weight="1"
android:orientation="horizontal"
android:focusable="true"
android:clickable="true">
diff --git a/res/layout/text_fields_editor_view.xml b/res/layout/text_fields_editor_view.xml
index c8d35a4..89970c6 100644
--- a/res/layout/text_fields_editor_view.xml
+++ b/res/layout/text_fields_editor_view.xml
@@ -34,13 +34,13 @@
layout="@layout/edit_field_list" />
<include
- android:id="@+id/spinner"
- layout="@layout/edit_spinner"
+ android:id="@+id/expansion_view_container"
+ layout="@layout/edit_expansion_view"
android:visibility="gone" />
<include
- android:id="@+id/expansion_view_container"
- layout="@layout/edit_expansion_view"
+ android:id="@+id/spinner"
+ layout="@layout/edit_spinner"
android:visibility="gone" />
<include
diff --git a/res/values/dimens.xml b/res/values/dimens.xml
index a4a6112..ae2bed5 100644
--- a/res/values/dimens.xml
+++ b/res/values/dimens.xml
@@ -25,7 +25,6 @@
<dimen name="aggregation_suggestion_icon_size">40dip</dimen>
- <dimen name="account_header_padding">10dip</dimen>
<dimen name="account_selector_popup_width">400dip</dimen>
<dimen name="photo_action_popup_width">400dip</dimen>
@@ -37,17 +36,17 @@
<!-- Padding of the rounded plus/minus/expand/collapse buttons in the editor -->
<dimen name="editor_round_button_padding_left">2dip</dimen>
<dimen name="editor_round_button_padding_right">2dip</dimen>
- <dimen name="editor_round_button_padding_top">8dip</dimen>
- <dimen name="editor_round_button_padding_bottom">8dip</dimen>
+ <dimen name="editor_round_button_padding_top">4dip</dimen>
+ <dimen name="editor_round_button_padding_bottom">4dip</dimen>
<!-- Width of the Type-Label in the Editor -->
<dimen name="editor_type_label_width">100dip</dimen>
<!-- Left padding of a field in the Editor -->
- <dimen name="editor_field_left_padding">5dip</dimen>
+ <dimen name="editor_field_left_padding">4dip</dimen>
<!-- Right padding of a field in the Editor -->
- <dimen name="editor_field_right_padding">5dip</dimen>
+ <dimen name="editor_field_right_padding">4dip</dimen>
<!-- Top padding of a field in the Editor -->
<dimen name="editor_field_top_padding">10dip</dimen>
diff --git a/res/values/strings.xml b/res/values/strings.xml
index 5bb6c2b..5aada70 100644
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -1292,8 +1292,8 @@
<!-- Checkbox asking the user if they want to display a particular photo for a contact -->
<string name="use_photo_as_primary">Use this photo</string>
- <!-- Text used to explain that a contact cannot be edited since the data is read only [CHAR LIMIT=40] -->
- <string name="contact_read_only">Not editable on this device</string>
+ <!-- Text used to explain that a contact cannot be edited from the People application since the data is read only [CHAR LIMIT=40] -->
+ <string name="contact_read_only">Not editable from this application</string>
<!-- Text describing that a contact has no information available other than name and photo -->
<string name="no_contact_details">No additional information for this contact</string>
@@ -1386,6 +1386,9 @@
<!-- The button to add another entry of a specific data type (i.e. email, phone, address) to a contact in the Raw Contact Editor [CHAR LIMIT=22] -->
<string name="add_new_entry_for_section">Add new</string>
+ <!-- The button to add an organization field to a contact in the Raw Contact Editor [CHAR LIMIT=22] -->
+ <string name="add_organization">Add organization</string>
+
<!-- Attbution of a contact status update, when the time of update is unknown -->
<string name="contact_status_update_attribution">via <xliff:g id="source" example="Google Talk">%1$s</xliff:g></string>
diff --git a/res/values/styles.xml b/res/values/styles.xml
index c125698..c2d10e0 100644
--- a/res/values/styles.xml
+++ b/res/values/styles.xml
@@ -79,9 +79,12 @@
<item name="android:textColorPrimary">@color/primary_text_color</item>
<item name="android:textColorSecondary">@color/secondary_text_color</item>
</style>
- <style name="ContactEditorActivityTheme" parent="@android:style/Theme.Holo.Light.DarkActionBar">
+
+ <style name="EditorActivityTheme" parent="@android:style/Theme.Holo.Light.DarkActionBar">
<item name="android:actionBarStyle">@style/ContactsActionBarStyle</item>
<item name="android:windowContentOverlay">@null</item>
+ <item name="android:textColorPrimary">@color/primary_text_color</item>
+ <item name="android:textColorSecondary">@color/secondary_text_color</item>
</style>
<style name="BackgroundOnly">
diff --git a/src/com/android/contacts/editor/ContactEditorFragment.java b/src/com/android/contacts/editor/ContactEditorFragment.java
index e0f99ce..0227b13 100644
--- a/src/com/android/contacts/editor/ContactEditorFragment.java
+++ b/src/com/android/contacts/editor/ContactEditorFragment.java
@@ -600,14 +600,8 @@
R.layout.external_raw_contact_editor_view, mContent, false);
((ExternalRawContactEditorView) editor).setListener(this);
} else {
- final RawContactEditorView rawContactEditor = (RawContactEditorView)
- inflater.inflate(R.layout.raw_contact_editor_view, mContent, false);
- // For existing contacts, only show the account header if there is more than 1 raw
- // contact in the aggregate contact.
- if (Intent.ACTION_EDIT.equals(mAction)) {
- rawContactEditor.setAccountHeaderVisible(numRawContacts > 1);
- }
- editor = rawContactEditor;
+ editor = (RawContactEditorView) inflater.inflate(R.layout.raw_contact_editor_view,
+ mContent, false);
}
if (Intent.ACTION_INSERT.equals(mAction) && numRawContacts == 1) {
final List<AccountWithDataSet> accounts =
@@ -695,7 +689,7 @@
values.getAsString(RawContacts.ACCOUNT_TYPE),
values.getAsString(RawContacts.DATA_SET));
final View accountView = editor.findViewById(R.id.account);
- final View anchorView = editor.findViewById(R.id.anchor_for_account_switcher);
+ final View anchorView = editor.findViewById(R.id.account_container);
accountView.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
diff --git a/src/com/android/contacts/editor/EventFieldEditorView.java b/src/com/android/contacts/editor/EventFieldEditorView.java
index 4c5affd..e7da6c1 100644
--- a/src/com/android/contacts/editor/EventFieldEditorView.java
+++ b/src/com/android/contacts/editor/EventFieldEditorView.java
@@ -29,6 +29,8 @@
import android.app.Dialog;
import android.content.Context;
+import android.content.res.ColorStateList;
+import android.content.res.Resources;
import android.os.Bundle;
import android.text.TextUtils;
import android.util.AttributeSet;
@@ -49,6 +51,13 @@
*/
private final static int DEFAULT_HOUR = 8;
+ /**
+ * Default string to show when there is no date selected yet.
+ */
+ private String mNoDateString;
+ private int mPrimaryTextColor;
+ private int mSecondaryTextColor;
+
private Button mDateView;
public EventFieldEditorView(Context context) {
@@ -68,6 +77,11 @@
protected void onFinishInflate() {
super.onFinishInflate();
+ Resources resources = mContext.getResources();
+ mPrimaryTextColor = resources.getColor(R.color.primary_text_color);
+ mSecondaryTextColor = resources.getColor(R.color.secondary_text_color);
+ mNoDateString = mContext.getString(R.string.add_new_entry_for_section);
+
mDateView = (Button) findViewById(R.id.date_view);
mDateView.setOnClickListener(new OnClickListener() {
@Override
@@ -105,12 +119,14 @@
final String column = editField.column;
String data = DateUtils.formatDate(getContext(), getEntry().getAsString(column));
if (TextUtils.isEmpty(data)) {
- data = " ";
+ mDateView.setText(mNoDateString);
+ mDateView.setTextColor(mSecondaryTextColor);
setDeleteButtonVisible(false);
} else {
+ mDateView.setText(data);
+ mDateView.setTextColor(mPrimaryTextColor);
setDeleteButtonVisible(true);
}
- mDateView.setText(data);
}
@Override
@@ -246,7 +262,8 @@
@Override
public void clearAllFields() {
// Update UI
- mDateView.setText("");
+ mDateView.setText(mNoDateString);
+ mDateView.setTextColor(mSecondaryTextColor);
// Update state
final String column = getKind().fieldList.get(0).column;
diff --git a/src/com/android/contacts/editor/ExternalRawContactEditorView.java b/src/com/android/contacts/editor/ExternalRawContactEditorView.java
index 734f013..04f4140 100644
--- a/src/com/android/contacts/editor/ExternalRawContactEditorView.java
+++ b/src/com/android/contacts/editor/ExternalRawContactEditorView.java
@@ -43,6 +43,7 @@
import android.widget.Button;
import android.widget.ImageView;
import android.widget.TextView;
+import android.widget.Toast;
import java.util.ArrayList;
@@ -55,10 +56,10 @@
private View mPhotoStub;
private TextView mName;
- private TextView mReadOnlyWarning;
private Button mEditExternallyButton;
private ViewGroup mGeneral;
+ private View mAccountContainer;
private ImageView mAccountIcon;
private TextView mAccountTypeTextView;
private TextView mAccountNameTextView;
@@ -97,11 +98,11 @@
mPhotoStub = findViewById(R.id.stub_photo);
mName = (TextView) findViewById(R.id.read_only_name);
- mReadOnlyWarning = (TextView) findViewById(R.id.read_only_warning);
mEditExternallyButton = (Button) findViewById(R.id.button_edit_externally);
mEditExternallyButton.setOnClickListener(this);
mGeneral = (ViewGroup)findViewById(R.id.sect_general);
+ mAccountContainer = findViewById(R.id.account_container);
mAccountIcon = (ImageView) findViewById(R.id.account_icon);
mAccountTypeTextView = (TextView) findViewById(R.id.account_type);
mAccountNameTextView = (TextView) findViewById(R.id.account_name);
@@ -168,11 +169,17 @@
mName.setText(primary.getAsString(StructuredName.DISPLAY_NAME));
if (type.readOnly) {
- mReadOnlyWarning.setText(mContext.getString(R.string.contact_read_only));
- mReadOnlyWarning.setVisibility(View.VISIBLE);
+ mAccountContainer.setOnClickListener(new OnClickListener() {
+ @Override
+ public void onClick(View v) {
+ Toast.makeText(mContext, mContext.getString(R.string.contact_read_only),
+ Toast.LENGTH_SHORT).show();
+ }
+ });
mEditExternallyButton.setVisibility(View.GONE);
} else {
- mReadOnlyWarning.setVisibility(View.GONE);
+ mAccountContainer.setBackgroundDrawable(null);
+ mAccountContainer.setEnabled(false);
mEditExternallyButton.setVisibility(View.VISIBLE);
}
@@ -183,7 +190,7 @@
View field = mInflater.inflate(
R.layout.item_read_only_field, mGeneral, false);
TextView v;
- v = (TextView) field.findViewById(R.id.label);
+ v = (TextView) field.findViewById(R.id.kind_title);
v.setText(mContext.getText(R.string.phoneLabelsGroup));
v = (TextView) field.findViewById(R.id.data);
v.setText(PhoneNumberUtils.formatNumber(phone.getAsString(Phone.NUMBER),
@@ -200,7 +207,7 @@
View field = mInflater.inflate(
R.layout.item_read_only_field, mGeneral, false);
TextView v;
- v = (TextView) field.findViewById(R.id.label);
+ v = (TextView) field.findViewById(R.id.kind_title);
v.setText(mContext.getText(R.string.emailLabelsGroup));
v = (TextView) field.findViewById(R.id.data);
v.setText(email.getAsString(Email.DATA));
diff --git a/src/com/android/contacts/editor/GroupMembershipView.java b/src/com/android/contacts/editor/GroupMembershipView.java
index 9693915..042b80a 100644
--- a/src/com/android/contacts/editor/GroupMembershipView.java
+++ b/src/com/android/contacts/editor/GroupMembershipView.java
@@ -27,6 +27,8 @@
import android.app.Activity;
import android.content.Context;
+import android.content.res.ColorStateList;
+import android.content.res.Resources;
import android.database.Cursor;
import android.provider.ContactsContract.CommonDataKinds.GroupMembership;
import android.provider.ContactsContract.RawContacts;
@@ -95,6 +97,10 @@
private boolean mDefaultGroupVisibilityKnown;
private boolean mDefaultGroupVisible;
+ private String mNoGroupString;
+ private int mPrimaryTextColor;
+ private int mSecondaryTextColor;
+
public GroupMembershipView(Context context) {
super(context);
}
@@ -104,6 +110,15 @@
}
@Override
+ protected void onFinishInflate() {
+ super.onFinishInflate();
+ Resources resources = mContext.getResources();
+ mPrimaryTextColor = resources.getColor(R.color.primary_text_color);
+ mSecondaryTextColor = resources.getColor(R.color.secondary_text_color);
+ mNoGroupString = mContext.getString(R.string.add_new_entry_for_section);
+ }
+
+ @Override
public void setEnabled(boolean enabled) {
super.setEnabled(enabled);
if (mGroupList != null) {
@@ -187,9 +202,11 @@
mGroupList.setEnabled(isEnabled());
if (sb.length() == 0) {
- mGroupList.setText(" ");
+ mGroupList.setText(mNoGroupString);
+ mGroupList.setTextColor(mSecondaryTextColor);
} else {
mGroupList.setText(sb);
+ mGroupList.setTextColor(mPrimaryTextColor);
}
setVisibility(VISIBLE);
diff --git a/src/com/android/contacts/editor/KindSectionView.java b/src/com/android/contacts/editor/KindSectionView.java
index 3b46307..686939c 100644
--- a/src/com/android/contacts/editor/KindSectionView.java
+++ b/src/com/android/contacts/editor/KindSectionView.java
@@ -140,7 +140,7 @@
mTitleString = (kind.titleRes == -1 || kind.titleRes == 0)
? ""
: getResources().getString(kind.titleRes);
- mTitle.setText(mTitleString.toUpperCase());
+ mTitle.setText(mTitleString);
rebuildFromState();
updateAddFooterVisible();
diff --git a/src/com/android/contacts/editor/LabeledEditorView.java b/src/com/android/contacts/editor/LabeledEditorView.java
index 5bba2c4..bb25ea0 100644
--- a/src/com/android/contacts/editor/LabeledEditorView.java
+++ b/src/com/android/contacts/editor/LabeledEditorView.java
@@ -465,10 +465,12 @@
private class EditTypeAdapter extends ArrayAdapter<EditType> {
private final LayoutInflater mInflater;
private boolean mHasCustomSelection;
+ private int mTextColor;
public EditTypeAdapter(Context context) {
super(context, 0);
mInflater = (LayoutInflater) context.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
+ mTextColor = context.getResources().getColor(R.color.secondary_text_color);
if (mType != null && mType.customColumn != null) {
@@ -501,17 +503,18 @@
private View createViewFromResource(int position, View convertView, ViewGroup parent,
int resource) {
- View view;
TextView textView;
if (convertView == null) {
- view = mInflater.inflate(resource, parent, false);
+ textView = (TextView) mInflater.inflate(resource, parent, false);
+ textView.setAllCaps(true);
+ textView.setGravity(Gravity.RIGHT);
+ textView.setTextAppearance(mContext, android.R.style.TextAppearance_Small);
+ textView.setTextColor(mTextColor);
} else {
- view = convertView;
+ textView = (TextView) convertView;
}
- textView = (TextView) view;
-
EditType type = getItem(position);
String text;
if (type == CUSTOM_SELECTION) {
@@ -519,10 +522,8 @@
} else {
text = getContext().getString(type.labelRes);
}
- textView.setText(text.toUpperCase());
- textView.setGravity(Gravity.RIGHT);
- textView.setTextColor(Color.GRAY);
- return view;
+ textView.setText(text);
+ return textView;
}
}
}
diff --git a/src/com/android/contacts/editor/RawContactEditorView.java b/src/com/android/contacts/editor/RawContactEditorView.java
index 41f2ebd..6335cb6 100644
--- a/src/com/android/contacts/editor/RawContactEditorView.java
+++ b/src/com/android/contacts/editor/RawContactEditorView.java
@@ -70,7 +70,6 @@
private ViewGroup mFields;
- private View mAccountContainer;
private ImageView mAccountIcon;
private TextView mAccountTypeTextView;
private TextView mAccountNameTextView;
@@ -139,7 +138,6 @@
mFields = (ViewGroup)findViewById(R.id.sect_fields);
- mAccountContainer = findViewById(R.id.anchor_for_account_switcher);
mAccountIcon = (ImageView) findViewById(R.id.account_icon);
mAccountTypeTextView = (TextView) findViewById(R.id.account_type);
mAccountNameTextView = (TextView) findViewById(R.id.account_name);
@@ -153,10 +151,6 @@
});
}
- public void setAccountHeaderVisible(boolean visible) {
- mAccountContainer.setVisibility(visible ? View.VISIBLE : View.GONE);
- }
-
/**
* Set the internal state for this view, given a current
* {@link EntityDelta} state and the {@link AccountType} that
diff --git a/src/com/android/contacts/editor/TextFieldsEditorView.java b/src/com/android/contacts/editor/TextFieldsEditorView.java
index 0d8aba6..d3fa3b7 100644
--- a/src/com/android/contacts/editor/TextFieldsEditorView.java
+++ b/src/com/android/contacts/editor/TextFieldsEditorView.java
@@ -60,6 +60,7 @@
private ImageView mExpansionView;
private boolean mHideOptional = true;
private boolean mHasShortAndLongForms;
+ private int mHintTextColor;
public TextFieldsEditorView(Context context) {
super(context);
@@ -81,6 +82,7 @@
setDrawingCacheEnabled(true);
setAlwaysDrawnWithCacheEnabled(true);
+ mHintTextColor = getContext().getResources().getColor(R.color.secondary_text_color);
mFields = (ViewGroup) findViewById(R.id.editors);
mExpansionView = (ImageView) findViewById(R.id.expansion_view);
mExpansionViewContainer = findViewById(R.id.expansion_view_container);
@@ -173,6 +175,7 @@
fieldView.setLayoutParams(new LinearLayout.LayoutParams(LayoutParams.MATCH_PARENT,
LayoutParams.WRAP_CONTENT));
fieldView.setTextAppearance(getContext(), kind.textAppearanceResourceId);
+ fieldView.setHintTextColor(mHintTextColor);
fieldView.setGravity(Gravity.TOP);
mFieldEditTexts[index] = fieldView;
fieldView.setId(vig.getId(state, kind, entry, index));