Style quick responses to Dialer Material.
This is replicating some assets and styles (in part) from Telephony,
but unlike Telephony we don't compile PhoneCommon into Telecom at
this time.
Most of this is to style the action bar the same as the "Dialer"
Telephony settings.
Bug: 18300861
Change-Id: Ic9eed11c81bf9205c89a508bb9271b621a9dc688
diff --git a/AndroidManifest.xml b/AndroidManifest.xml
index 9a8d0cc..d0ae09c 100644
--- a/AndroidManifest.xml
+++ b/AndroidManifest.xml
@@ -191,7 +191,8 @@
<activity android:name=".RespondViaSmsSettings$Settings"
android:label="@string/respond_via_sms_setting_title"
- android:configChanges="orientation|screenSize|keyboardHidden">
+ android:configChanges="orientation|screenSize|keyboardHidden"
+ android:theme="@style/Theme.Telecom.DialerSettings">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
</intent-filter>
diff --git a/res/drawable-hdpi/ic_arrow_back_white_24dp.png b/res/drawable-hdpi/ic_arrow_back_white_24dp.png
new file mode 100644
index 0000000..5fa4948
--- /dev/null
+++ b/res/drawable-hdpi/ic_arrow_back_white_24dp.png
Binary files differ
diff --git a/res/drawable-hdpi/ic_more_vert_white_24dp.png b/res/drawable-hdpi/ic_more_vert_white_24dp.png
new file mode 100644
index 0000000..675f3ee
--- /dev/null
+++ b/res/drawable-hdpi/ic_more_vert_white_24dp.png
Binary files differ
diff --git a/res/drawable-mdpi/ic_arrow_back_white_24dp.png b/res/drawable-mdpi/ic_arrow_back_white_24dp.png
new file mode 100644
index 0000000..9e662f6
--- /dev/null
+++ b/res/drawable-mdpi/ic_arrow_back_white_24dp.png
Binary files differ
diff --git a/res/drawable-mdpi/ic_more_vert_white_24dp.png b/res/drawable-mdpi/ic_more_vert_white_24dp.png
new file mode 100644
index 0000000..1d8ad18
--- /dev/null
+++ b/res/drawable-mdpi/ic_more_vert_white_24dp.png
Binary files differ
diff --git a/res/drawable-xhdpi/ic_arrow_back_white_24dp.png b/res/drawable-xhdpi/ic_arrow_back_white_24dp.png
new file mode 100644
index 0000000..addbfc8
--- /dev/null
+++ b/res/drawable-xhdpi/ic_arrow_back_white_24dp.png
Binary files differ
diff --git a/res/drawable-xhdpi/ic_more_vert_white_24dp.png b/res/drawable-xhdpi/ic_more_vert_white_24dp.png
new file mode 100644
index 0000000..1b04eda
--- /dev/null
+++ b/res/drawable-xhdpi/ic_more_vert_white_24dp.png
Binary files differ
diff --git a/res/drawable-xxhdpi/ic_arrow_back_white_24dp.png b/res/drawable-xxhdpi/ic_arrow_back_white_24dp.png
new file mode 100644
index 0000000..4057cc5
--- /dev/null
+++ b/res/drawable-xxhdpi/ic_arrow_back_white_24dp.png
Binary files differ
diff --git a/res/drawable-xxhdpi/ic_more_vert_white_24dp.png b/res/drawable-xxhdpi/ic_more_vert_white_24dp.png
new file mode 100644
index 0000000..2955c02
--- /dev/null
+++ b/res/drawable-xxhdpi/ic_more_vert_white_24dp.png
Binary files differ
diff --git a/res/drawable-xxxhdpi/ic_arrow_back_white_24dp.png b/res/drawable-xxxhdpi/ic_arrow_back_white_24dp.png
new file mode 100644
index 0000000..02f2f6f
--- /dev/null
+++ b/res/drawable-xxxhdpi/ic_arrow_back_white_24dp.png
Binary files differ
diff --git a/res/drawable-xxxhdpi/ic_more_vert_white_24dp.png b/res/drawable-xxxhdpi/ic_more_vert_white_24dp.png
new file mode 100644
index 0000000..25b6f9f
--- /dev/null
+++ b/res/drawable-xxxhdpi/ic_more_vert_white_24dp.png
Binary files differ
diff --git a/res/drawable/ic_back_arrow.xml b/res/drawable/ic_back_arrow.xml
new file mode 100644
index 0000000..cbb4c11
--- /dev/null
+++ b/res/drawable/ic_back_arrow.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2014 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
+ -->
+<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
+ android:src="@drawable/ic_arrow_back_white_24dp"
+ android:autoMirrored="true" />
diff --git a/res/values/colors.xml b/res/values/colors.xml
index e93e855..64db085 100644
--- a/res/values/colors.xml
+++ b/res/values/colors.xml
@@ -16,4 +16,8 @@
<resources>
<color name="theme_color">#0288d1</color>
+
+ <color name="dialer_settings_actionbar_text_color">#ffffff</color>
+ <color name="dialer_settings_actionbar_background_color">@color/theme_color</color>
+ <color name="dialer_settings_color_dark">#0277bd</color>
</resources>
diff --git a/res/values/dimens.xml b/res/values/dimens.xml
index 86d803d..f7ad003 100644
--- a/res/values/dimens.xml
+++ b/res/values/dimens.xml
@@ -18,4 +18,6 @@
<!-- Dimension used to possibly down-scale high-res photo into what is suitable
for notification's large icon. -->
<dimen name="notification_icon_size">64dp</dimen>
+
+ <dimen name="dialer_settings_actionbar_elevation">2dp</dimen>
</resources>
diff --git a/res/values/styles.xml b/res/values/styles.xml
index 6b6c1bb..f073906 100644
--- a/res/values/styles.xml
+++ b/res/values/styles.xml
@@ -24,4 +24,30 @@
<item name="android:backgroundDimEnabled">true</item>
<item name="android:windowAnimationStyle">@android:style/Animation.Dialog</item>
</style>
+
+ <style name="Theme.Telecom.DialerSettings" parent="@android:style/Theme.Material.Light">
+ <item name="android:actionBarStyle">@style/TelecomDialerSettingsActionBarStyle</item>
+ <item name="android:actionOverflowButtonStyle">@style/TelecomDialerSettingsActionOverflowButtonStyle</item>
+ <item name="android:colorPrimaryDark">@color/dialer_settings_color_dark</item>
+ <item name="android:homeAsUpIndicator">@drawable/ic_back_arrow</item>
+ <item name="android:windowContentOverlay">@null</item>
+ </style>
+
+ <style name="TelecomDialerSettingsActionBarStyle" parent="android:Widget.Material.ActionBar">
+ <item name="android:background">@color/dialer_settings_actionbar_background_color</item>
+ <item name="android:titleTextStyle">@style/TelecomDialerSettingsActionBarTitleText</item>
+ <item name="android:elevation">@dimen/dialer_settings_actionbar_elevation</item>
+ <!-- Empty icon -->
+ <item name="android:icon">@android:color/transparent</item>
+ </style>
+
+ <style name="TelecomDialerSettingsActionBarTitleText"
+ parent="@android:style/TextAppearance.Material.Widget.ActionBar.Title">
+ <item name="android:textColor">@color/dialer_settings_actionbar_text_color</item>
+ </style>
+
+ <style name="TelecomDialerSettingsActionOverflowButtonStyle"
+ parent="@android:style/Widget.Material.Light.ActionButton.Overflow">
+ <item name="android:src">@drawable/ic_more_vert_white_24dp</item>
+ </style>
</resources>