Merge fx-team to m-c a=merge
authorWes Kocher <wkocher@mozilla.com>
Fri, 13 Jun 2014 17:40:39 -0700
changeset 188732 86aa28ce309efd1895531d99a0393f0215afaf44
parent 188730 cf723305a1d28039ce75c1d1aca51013cd26d67e (current diff)
parent 188731 1e1f339edfa8114946e17761e9a58f2ab2805678 (diff)
child 188733 e9f6e6ec3cde68e4c7e99ac360b8fef1ce4568d1
child 188770 1ab266934f476e4143019947b546b8471fd73175
child 188777 161b482a0d55e9c4e32ba75ba2d72f57b0ddf20a
child 188794 355973298aab00a2cfbeb77ab4615570c5c19c39
push id44892
push userkwierso@gmail.com
push dateSat, 14 Jun 2014 00:48:20 +0000
treeherdermozilla-inbound@e9f6e6ec3cde [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmerge
milestone33.0a1
first release with
nightly linux32
86aa28ce309e / 33.0a1 / 20140614030205 / files
nightly linux64
86aa28ce309e / 33.0a1 / 20140614030205 / files
nightly mac
86aa28ce309e / 33.0a1 / 20140614030205 / files
nightly win32
86aa28ce309e / 33.0a1 / 20140614030205 / files
nightly win64
86aa28ce309e / 33.0a1 / 20140614030205 / files
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
releases
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Merge fx-team to m-c a=merge
--- a/mobile/android/base/BrowserApp.java
+++ b/mobile/android/base/BrowserApp.java
@@ -482,17 +482,17 @@ abstract public class BrowserApp extends
         mBrowserToolbar.setProgressBar(mProgressView);
         if (Intent.ACTION_VIEW.equals(intent.getAction())) {
             // Show the target URL immediately in the toolbar.
             mBrowserToolbar.setTitle(intent.getDataString());
 
             Telemetry.sendUIEvent(TelemetryContract.Event.LOAD_URL, TelemetryContract.Method.INTENT);
         }
 
-        ((GeckoApp.MainLayout) mMainLayout).setTouchEventInterceptor(new HideOnTouchListener());
+        ((GeckoApp.MainLayout) mMainLayout).setTouchEventInterceptor(new HideTabsTouchListener());
         ((GeckoApp.MainLayout) mMainLayout).setMotionEventInterceptor(new MotionEventInterceptor() {
             @Override
             public boolean onInterceptMotionEvent(View view, MotionEvent event) {
                 // If we get a gamepad panning MotionEvent while the focus is not on the layerview,
                 // put the focus on the layerview and carry on
                 if (mLayerView != null && !mLayerView.hasFocus() && GamepadUtils.isPanningControl(event)) {
                     if (mHomePager == null) {
                         return false;
@@ -1980,27 +1980,21 @@ abstract public class BrowserApp extends
 
         mBrowserSearchContainer.setVisibility(View.INVISIBLE);
 
         getSupportFragmentManager().beginTransaction()
                 .remove(mBrowserSearch).commitAllowingStateLoss();
         mBrowserSearch.setUserVisibleHint(false);
     }
 
-    /**
-     * Hides certain UI elements (e.g. button toast, tabs tray) when the
-     * user touches the main layout.
-     */
-    private class HideOnTouchListener implements TouchEventInterceptor {
+    private class HideTabsTouchListener implements TouchEventInterceptor {
         private boolean mIsHidingTabs = false;
 
         @Override
         public boolean onInterceptTouchEvent(View view, MotionEvent event) {
-            getButtonToast().hide(false, ButtonToast.ReasonHidden.TOUCH_OUTSIDE);
-
             // We need to account for scroll state for the touched view otherwise
             // tapping on an "empty" part of the view will still be considered a
             // valid touch event.
             if (view.getScrollX() != 0 || view.getScrollY() != 0) {
                 Rect rect = new Rect();
                 view.getHitRect(rect);
                 rect.offset(-view.getScrollX(), -view.getScrollY());
 
--- a/mobile/android/base/widget/ButtonToast.java
+++ b/mobile/android/base/widget/ButtonToast.java
@@ -37,17 +37,16 @@ public class ButtonToast {
     private final View mView;
     private final TextView mMessageView;
     private final Button mButton;
     private final Handler mHideHandler = new Handler();
     private Toast mCurrentToast;
 
     public enum ReasonHidden {
         CLICKED,
-        TOUCH_OUTSIDE,
         TIMEOUT,
         REPLACED,
         STARTUP
     }
 
     // State objects
     private static class Toast {
         public final CharSequence buttonMessage;