Bug 1197428 - Remove UrlBar.ImageButton.Icon style and change inheritors. r=mcomella
authorChristian Schmitz <tynn.dev@gmail.com>
Wed, 02 Sep 2015 03:14:00 +0200
changeset 261587 94a35ea51e6adebb93599ab0e6f9b9b7326bb7ef
parent 261586 3aa50a207837fbe3892b556829d4d84e2fd603db
child 261588 6e64ea28389d117fcfd62e2902bbfa0770670e7f
push id64771
push userkwierso@gmail.com
push dateWed, 09 Sep 2015 20:49:01 +0000
treeherdermozilla-inbound@dd2a1d737a64 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmcomella
bugs1197428
milestone43.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 1197428 - Remove UrlBar.ImageButton.Icon style and change inheritors. r=mcomella
mobile/android/base/resources/layout-large-v11/browser_toolbar.xml
mobile/android/base/resources/values/styles.xml
mobile/android/base/toolbar/PageActionLayout.java
--- a/mobile/android/base/resources/layout-large-v11/browser_toolbar.xml
+++ b/mobile/android/base/resources/layout-large-v11/browser_toolbar.xml
@@ -129,15 +129,18 @@
                 android:layout_gravity="center"/>
 
     </org.mozilla.gecko.widget.themed.ThemedFrameLayout>
 
     <!-- We draw after the menu items so when they are hidden, the cancel button,
          which is thus drawn on top, may be pressed. -->
     <org.mozilla.gecko.widget.themed.ThemedImageView
             android:id="@+id/edit_cancel"
-            style="@style/UrlBar.ImageButton.Icon"
+            style="@style/UrlBar.ImageButton"
+            android:layout_width="@dimen/browser_toolbar_icon_width"
+            android:layout_height="@dimen/browser_toolbar_height"
+            android:layout_weight="0.0"
             android:layout_alignParentRight="true"
             android:src="@drawable/close_edit_mode_selector"
             android:contentDescription="@string/edit_mode_cancel"
             android:visibility="gone"/>
 
 </merge>
--- a/mobile/android/base/resources/values/styles.xml
+++ b/mobile/android/base/resources/values/styles.xml
@@ -491,23 +491,16 @@
         <item name="android:layout_gravity">center_vertical</item>
         <item name="android:background">@android:color/transparent</item>
     </style>
 
     <style name="UrlBar.ImageButton" parent="UrlBar.ImageButtonBase">
         <item name="android:layout_width">@dimen/browser_toolbar_height</item>
     </style>
 
-    <!-- URL bar - Image Button - Icon -->
-    <style name="UrlBar.ImageButton.Icon">
-         <item name="android:layout_width">@dimen/browser_toolbar_icon_width</item>
-         <item name="android:layout_height">@dimen/browser_toolbar_height</item>
-         <item name="android:layout_weight">0.0</item>
-    </style>
-
     <!-- TabsLayout -->
     <style name="TabsLayoutBase">
          <item name="android:background">@android:color/transparent</item>
          <item name="android:listSelector">@android:color/transparent</item>
     </style>
 
     <style name="TabsLayout" parent="TabsLayoutBase">
          <item name="android:orientation">vertical</item>
--- a/mobile/android/base/toolbar/PageActionLayout.java
+++ b/mobile/android/base/toolbar/PageActionLayout.java
@@ -157,17 +157,17 @@ public class PageActionLayout extends Li
             }
         }
     }
 
     private ImageButton createImageButton() {
         ThreadUtils.assertOnUiThread();
 
         final int width = mContext.getResources().getDimensionPixelSize(R.dimen.page_action_button_width);
-        ImageButton imageButton = new ImageButton(mContext, null, R.style.UrlBar_ImageButton_Icon);
+        ImageButton imageButton = new ImageButton(mContext, null, R.style.UrlBar_ImageButton);
         imageButton.setLayoutParams(new LayoutParams(width, LayoutParams.MATCH_PARENT));
         imageButton.setScaleType(ImageView.ScaleType.CENTER_INSIDE);
         imageButton.setOnClickListener(this);
         imageButton.setOnLongClickListener(this);
         return imageButton;
     }
 
     @Override