Make compose disappear when search action view is expanded
On certain phones, limited screen width makes the search action view
look confined. Show the compose menu item only when there is no action
view.
Bug: 8747635 Compose button should not show when the user is trying to
do a search (on phone)
Change-Id: I129e6b4474b2c3f93d86abb5eaaa1dd135285912
diff --git a/res/menu/conversation_list_menu.xml b/res/menu/conversation_list_menu.xml
index e2483b5..99b9db2 100644
--- a/res/menu/conversation_list_menu.xml
+++ b/res/menu/conversation_list_menu.xml
@@ -20,16 +20,16 @@
<!-- Always available -->
<item android:id="@+id/compose"
android:title="@string/menu_compose"
- android:showAsAction="always"
+ android:showAsAction="ifRoom"
android:icon="@drawable/ic_menu_compose_normal_holo_light"
android:alphabeticShortcut="@string/trigger_compose_char" />
<!-- Available only for accounts with SERVER_SEARCH and in a folder
that supports FOLDER_SERVER_SEARCH -->
<item android:id="@+id/search" android:title="@string/menu_search"
- android:showAsAction="always|collapseActionView"
- android:icon="@drawable/ic_menu_search_holo_light"
- android:actionLayout="@layout/mail_actionbar_searchview" />
+ android:showAsAction="always|collapseActionView"
+ android:icon="@drawable/ic_menu_search_holo_light"
+ android:actionLayout="@layout/mail_actionbar_searchview" />
<!-- Available only in the trash folder, when the account supports emptying it -->
<item android:id="@+id/empty_trash"