diff options
author | Daniel Gultsch <daniel@gultsch.de> | 2016-09-18 20:09:39 +0200 |
---|---|---|
committer | Christian Schneppe <christian@pix-art.de> | 2016-09-23 21:30:21 +0200 |
commit | 449aa682f03acb6c4d49dfb5ed7b00bde65e8491 (patch) | |
tree | ba8d6bc15321d7a4522b501e25a7ebde9f798a2d /src | |
parent | 61bb0b682ddbca7cad006622e7811162a1fb4f5b (diff) |
use proper paddings in dialogs on android < 5
Diffstat (limited to 'src')
-rw-r--r-- | src/main/res/layout/create_conference_dialog.xml | 16 | ||||
-rw-r--r-- | src/main/res/layout/dialog_clear_history.xml | 7 | ||||
-rw-r--r-- | src/main/res/layout/dialog_show_password.xml | 5 | ||||
-rw-r--r-- | src/main/res/layout/enter_jid_dialog.xml | 20 | ||||
-rw-r--r-- | src/main/res/values-v21/themes.xml | 3 | ||||
-rw-r--r-- | src/main/res/values/attrs.xml | 8 | ||||
-rw-r--r-- | src/main/res/values/themes.xml | 3 |
7 files changed, 42 insertions, 20 deletions
diff --git a/src/main/res/layout/create_conference_dialog.xml b/src/main/res/layout/create_conference_dialog.xml index d7eef989a..822deb48c 100644 --- a/src/main/res/layout/create_conference_dialog.xml +++ b/src/main/res/layout/create_conference_dialog.xml @@ -1,12 +1,12 @@ <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" - android:layout_width="match_parent" - android:layout_height="match_parent" - android:orientation="vertical" - android:paddingBottom="8dp" - android:paddingLeft="24dp" - android:paddingRight="24dp" - android:paddingTop="16dp"> + android:layout_width="match_parent" + android:layout_height="match_parent" + android:orientation="vertical" + android:paddingBottom="?attr/dialog_vertical_padding" + android:paddingLeft="?attr/dialog_horizontal_padding" + android:paddingRight="?attr/dialog_horizontal_padding" + android:paddingTop="?attr/dialog_vertical_padding"> <TextView android:id="@+id/your_account" @@ -39,6 +39,6 @@ android:inputType="textAutoComplete" android:textColor="@color/black87" android:textColorHint="@color/black54" - android:textSize="?attr/TextSizeBody"/> + android:textSize="?attr/TextSizeBody" /> </LinearLayout>
\ No newline at end of file diff --git a/src/main/res/layout/dialog_clear_history.xml b/src/main/res/layout/dialog_clear_history.xml index 3d738e8a1..4dd709415 100644 --- a/src/main/res/layout/dialog_clear_history.xml +++ b/src/main/res/layout/dialog_clear_history.xml @@ -3,11 +3,15 @@ android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical" - android:padding="8dp" > + android:paddingLeft="?attr/dialog_horizontal_padding" + android:paddingRight="?attr/dialog_horizontal_padding" + android:paddingBottom="?attr/dialog_vertical_padding" + android:paddingTop="?attr/dialog_vertical_padding"> <TextView android:layout_width="wrap_content" android:layout_height="wrap_content" + android:textColor="?attr/color_text_primary" android:paddingBottom="8dp" android:text="@string/clear_histor_msg" android:textSize="?attr/TextSizeBody" /> @@ -15,6 +19,7 @@ <CheckBox android:id="@+id/end_conversation_checkbox" android:layout_width="wrap_content" + android:textColor="?attr/color_text_primary" android:layout_height="wrap_content" android:text="@string/also_end_conversation" android:visibility="gone" /> diff --git a/src/main/res/layout/dialog_show_password.xml b/src/main/res/layout/dialog_show_password.xml index dba0690cb..167659637 100644 --- a/src/main/res/layout/dialog_show_password.xml +++ b/src/main/res/layout/dialog_show_password.xml @@ -3,7 +3,10 @@ android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical" - android:padding="16dp" > + android:paddingLeft="?attr/dialog_horizontal_padding" + android:paddingRight="?attr/dialog_horizontal_padding" + android:paddingBottom="?attr/dialog_vertical_padding" + android:paddingTop="?attr/dialog_vertical_padding"> <TextView android:id="@+id/password" diff --git a/src/main/res/layout/enter_jid_dialog.xml b/src/main/res/layout/enter_jid_dialog.xml index d5c4fc0eb..765c438ce 100644 --- a/src/main/res/layout/enter_jid_dialog.xml +++ b/src/main/res/layout/enter_jid_dialog.xml @@ -1,12 +1,12 @@ <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" - android:layout_width="match_parent" - android:layout_height="match_parent" - android:orientation="vertical" - android:paddingBottom="8dp" - android:paddingLeft="24dp" - android:paddingRight="24dp" - android:paddingTop="16dp"> + android:layout_width="match_parent" + android:layout_height="match_parent" + android:orientation="vertical" + android:paddingBottom="?attr/dialog_vertical_padding" + android:paddingLeft="?attr/dialog_horizontal_padding" + android:paddingRight="?attr/dialog_horizontal_padding" + android:paddingTop="?attr/dialog_vertical_padding"> <TextView android:id="@+id/your_account" @@ -15,13 +15,13 @@ android:text="@string/your_account" android:textColor="@color/black87" android:textSize="?attr/TextSizeBody" - android:visibility="gone"/> + android:visibility="gone" /> <Spinner android:id="@+id/account" android:layout_width="fill_parent" android:layout_height="wrap_content" - android:visibility="gone"/> + android:visibility="gone" /> <TextView android:id="@+id/jabber_id" @@ -30,7 +30,7 @@ android:layout_marginTop="8dp" android:text="@string/account_settings_jabber_id" android:textColor="@color/black87" - android:textSize="?attr/TextSizeBody"/> + android:textSize="?attr/TextSizeBody" /> <AutoCompleteTextView android:id="@+id/jid" diff --git a/src/main/res/values-v21/themes.xml b/src/main/res/values-v21/themes.xml index 6dd41ed26..b686c5f6d 100644 --- a/src/main/res/values-v21/themes.xml +++ b/src/main/res/values-v21/themes.xml @@ -14,6 +14,9 @@ <item name="TextSizeBody">16sp</item> <item name="TextSizeHeadline">22sp</item> + <item name="attr/dialog_horizontal_padding">24dp</item> + <item name="attr/dialog_vertical_padding">16dp</item> + <item name="attr/icon_add_group">@drawable/ic_group_add_white_24dp</item> <item name="attr/icon_add_person">@drawable/ic_person_add_white_24dp</item> <item name="attr/icon_cancel">@drawable/ic_cancel_white_24dp</item> diff --git a/src/main/res/values/attrs.xml b/src/main/res/values/attrs.xml index 901ea7547..526ab66be 100644 --- a/src/main/res/values/attrs.xml +++ b/src/main/res/values/attrs.xml @@ -27,4 +27,12 @@ <attr name="icon_share" format="reference"/> <attr name="icon_import_export" format="reference"/> + <attr name="icon_notifications" format="reference"/> + <attr name="icon_notifications_off" format="reference"/> + <attr name="icon_notifications_paused" format="reference"/> + <attr name="icon_notifications_none" format="reference"/> + + <attr name="dialog_horizontal_padding" format="dimension"/> + <attr name="dialog_vertical_padding" format="dimension"/> + </resources>
\ No newline at end of file diff --git a/src/main/res/values/themes.xml b/src/main/res/values/themes.xml index c5ece29cf..9837b8588 100644 --- a/src/main/res/values/themes.xml +++ b/src/main/res/values/themes.xml @@ -32,6 +32,9 @@ <item name="attr/icon_settings">@drawable/ic_settings_grey600_24dp</item> <item name="attr/icon_import_export">@drawable/ic_import_export_white_24dp</item> <item name="attr/icon_share">@drawable/ic_share_white_24dp</item> + + <item name="attr/dialog_horizontal_padding">16dp</item> + <item name="attr/dialog_vertical_padding">16dp</item> </style> <style name="ConversationsTheme.LargerText" parent="ConversationsTheme"> |