Introduce overflow menu button
Available when there's no hard menu key on the device.
Also remove Call Settings menu from favorite screen.
Bug: 5001942
Change-Id: Ib0ff3fb15a26001dbdad4756bfa4e4bfe1652da2
diff --git a/res/layout/dialpad_fragment.xml b/res/layout/dialpad_fragment.xml
index aee2c25..9f8c0cf 100644
--- a/res/layout/dialpad_fragment.xml
+++ b/res/layout/dialpad_fragment.xml
@@ -22,20 +22,35 @@
android:layout_marginLeft="8dip"
android:layout_marginRight="8dip" >
- <!-- Text field above the keypad where the digits are displayed.
- It's type is set to NULL (to disable the IME keyboard) in the
- java code.
-
- Background drawable can be controlled programatically.
- -->
- <EditText android:id="@+id/digits"
+ <!-- Text field and possibly soft menu button above the keypad where
+ the digits are displayed. -->
+ <RelativeLayout
android:layout_width="match_parent"
android:layout_height="@dimen/dialpad_digits_height"
android:layout_marginTop="4dip"
android:gravity="center"
- android:textAppearance="@style/DialtactsDigitsTextAppearance"
- android:background="@drawable/dialpad_background"
- android:textColor="?android:attr/textColorPrimary" />
+ android:background="@drawable/dialpad_background" >
+
+ <!-- Type of this EditText is set to NULL (to disable the IME keyboard)
+ in the java code.
+
+ Background drawable can be controlled programatically. -->
+ <EditText android:id="@+id/digits"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:layout_alignParentLeft="true"
+ android:layout_toLeftOf="@+id/moreoverflow"
+ android:gravity="center"
+ android:textAppearance="@style/DialtactsDigitsTextAppearance"
+ android:textColor="?android:attr/textColorPrimary" />
+
+ <ImageButton android:id="@+id/overflow_menu"
+ android:layout_width="wrap_content"
+ android:layout_height="match_parent"
+ android:layout_alignParentRight="true"
+ android:src="@drawable/ic_menu_overflow" />
+
+ </RelativeLayout>
<!-- Keypad section -->
<include layout="@layout/dialpad" />
diff --git a/res/menu/call_log_options.xml b/res/menu/call_log_options.xml
index 57d637e..1f8de57 100644
--- a/res/menu/call_log_options.xml
+++ b/res/menu/call_log_options.xml
@@ -19,4 +19,9 @@
android:icon="@android:drawable/ic_menu_close_clear_cancel"
android:title="@string/recentCalls_deleteAll"
android:showAsAction="withText" />
+
+ <item
+ android:id="@+id/menu_call_settings_call_log"
+ android:title="@string/call_settings"
+ android:showAsAction="withText" />
</menu>
diff --git a/res/menu/dialpad_options.xml b/res/menu/dialpad_options.xml
index 77da9cb..c736e34 100644
--- a/res/menu/dialpad_options.xml
+++ b/res/menu/dialpad_options.xml
@@ -30,4 +30,9 @@
android:icon="@drawable/ic_menu_wait"
android:title="@string/add_wait"
android:showAsAction="withText" />
+
+ <item
+ android:id="@+id/menu_call_settings_dialpad"
+ android:title="@string/call_settings"
+ android:showAsAction="withText" />
</menu>
diff --git a/res/menu/dialtacts_options.xml b/res/menu/dialtacts_options.xml
index a5ed153..aa3af3f 100644
--- a/res/menu/dialtacts_options.xml
+++ b/res/menu/dialtacts_options.xml
@@ -15,11 +15,6 @@
-->
<menu xmlns:android="http://schemas.android.com/apk/res/android">
<item
- android:id="@+id/menu_call_settings"
- android:title="@string/call_settings"
- android:showAsAction="withText" />
-
- <item
android:id="@+id/search_on_action_bar"
android:icon="@android:drawable/ic_menu_search"
android:showAsAction="always" />