Bug 1086981 - Part 6: Drop keyboard when clicking the menu button. r=lucasr
authorMichael Comella <michael.l.comella@gmail.com>
Tue, 04 Nov 2014 04:02:13 -0800
changeset 213961 ad0e861aede41612292aacf024c143e084ecf882
parent 213960 17033c6fae5b37991dd2e84fa383c5cccc9f07ef
child 213962 e1b14ecffaab06dafd376dd12aaab486518d08c4
push id27769
push userkwierso@gmail.com
push dateWed, 05 Nov 2014 03:53:35 +0000
treeherdermozilla-central@62990ec7ad78 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerslucasr
bugs1086981
milestone36.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1086981 - Part 6: Drop keyboard when clicking the menu button. r=lucasr
mobile/android/base/toolbar/BrowserToolbar.java
--- a/mobile/android/base/toolbar/BrowserToolbar.java
+++ b/mobile/android/base/toolbar/BrowserToolbar.java
@@ -340,16 +340,18 @@ public abstract class BrowserToolbar ext
 
         if (hasSoftMenuButton) {
             menuButton.setVisibility(View.VISIBLE);
             menuIcon.setVisibility(View.VISIBLE);
 
             menuButton.setOnClickListener(new Button.OnClickListener() {
                 @Override
                 public void onClick(View view) {
+                    // Drop the soft keyboard.
+                    urlEditLayout.clearFocus();
                     activity.openOptionsMenu();
                 }
             });
         }
     }
 
     @Override
     public void onDetachedFromWindow() {