Bug 831402: Dividers in tabs UI should be with action-bar. [r=mfinkle]
authorSriram Ramasubramanian <sriram@mozilla.com>
Wed, 16 Jan 2013 14:04:53 -0800
changeset 119162 6b7cf7305ae611569bd12752f117e12826f39ef4
parent 119161 7b6b22881aaaa91da89e9a9f4642d24e911a5b0b
child 119163 ae0673777ec827eb1ea89331dab707ef9efa589c
push id21503
push usersramasubramanian@mozilla.com
push dateThu, 17 Jan 2013 19:29:48 +0000
treeherdermozilla-inbound@384f08852a55 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmfinkle
bugs831402
milestone21.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 831402: Dividers in tabs UI should be with action-bar. [r=mfinkle]
mobile/android/base/TabsPanel.java
mobile/android/base/resources/drawable-hdpi/menu_popup_arrow_top.png
mobile/android/base/resources/drawable-xhdpi/menu_popup_arrow_top.png
mobile/android/base/resources/drawable/menu_popup_arrow_top.png
mobile/android/base/resources/layout-xlarge-v11/tabs_panel.xml.in
mobile/android/base/resources/layout-xlarge-v11/tabs_panel_header.xml
mobile/android/base/resources/layout/tabs_panel.xml.in
mobile/android/base/resources/layout/tabs_panel_header.xml
--- a/mobile/android/base/TabsPanel.java
+++ b/mobile/android/base/TabsPanel.java
@@ -47,17 +47,17 @@ public class TabsPanel extends TabHost
 
     public static interface TabsLayoutChangeListener {
         public void onTabsLayoutChange(int width, int height);
     }
 
     private Context mContext;
     private GeckoApp mActivity;
     private PanelView mPanel;
-    private TabsPanelToolbar mFooter;
+    private LinearLayout mFooter;
     private TabsLayoutChangeListener mLayoutChangeListener;
 
     private static ImageButton mMenuButton;
     private static ImageButton mAddTab;
     private TabWidget mTabWidget;
     private Spinner mTabsSpinner;
 
     private Panel mCurrentPanel;
@@ -139,17 +139,17 @@ public class TabsPanel extends TabHost
                     panel = Panel.REMOTE_TABS;
 
                 TabsPanel.this.show(panel);
             }
         });
     }
 
     void initToolbar() {
-        mFooter = (TabsPanelToolbar) findViewById(R.id.tabs_panel_footer);
+        mFooter = (LinearLayout) findViewById(R.id.tabs_panel_footer);
 
         mTabWidget = (TabWidget) findViewById(android.R.id.tabs);
 
         mAddTab = (ImageButton) findViewById(R.id.add_tab);
         mAddTab.setOnClickListener(new Button.OnClickListener() {
             public void onClick(View v) {
                 TabsPanel.this.addTab();
             }
--- a/mobile/android/base/resources/layout-xlarge-v11/tabs_panel.xml.in
+++ b/mobile/android/base/resources/layout-xlarge-v11/tabs_panel.xml.in
@@ -6,28 +6,35 @@
 
 <merge xmlns:android="http://schemas.android.com/apk/res/android"
        xmlns:gecko="http://schemas.android.com/apk/res/@ANDROID_PACKAGE_NAME@">
 
     <LinearLayout android:layout_width="fill_parent"
                   android:layout_height="fill_parent"
                   android:orientation="vertical">
 
-        <view class="org.mozilla.gecko.TabsPanel$TabsPanelToolbar"
-              android:id="@+id/tabs_panel_header"
-              android:layout_width="fill_parent"
-              android:layout_height="@dimen/browser_toolbar_height">
+        <LinearLayout android:id="@+id/tabs_panel_header"
+                      android:layout_width="fill_parent"
+                      android:layout_height="@dimen/browser_toolbar_height"
+                      android:orientation="vertical">
+
+            <view class="org.mozilla.gecko.TabsPanel$TabsPanelToolbar"
+                  android:layout_width="fill_parent"
+                  android:layout_height="0dip"
+                  android:layout_weight="1.0">
 
-            <include layout="@layout/tabs_panel_header"/>
+                <include layout="@layout/tabs_panel_header"/>
 
-        </view>
+            </view>
 
-        <View android:layout_width="fill_parent"
-              android:layout_height="2dp"
-              android:background="#FF313131"/>
+            <View android:layout_width="fill_parent"
+                  android:layout_height="2dp"
+                  android:background="#FF313131"/>
+
+        </LinearLayout>
 
         <view class="org.mozilla.gecko.TabsPanel$TabsListContainer"
               android:id="@android:id/tabcontent"
               android:layout_width="fill_parent"
               android:layout_height="0dip"
               android:layout_weight="1.0">
 
             <org.mozilla.gecko.TabsTray android:id="@+id/normal_tabs"
@@ -47,24 +54,31 @@
                                           android:layout_width="fill_parent"
                                           android:layout_height="fill_parent"
                                           android:paddingLeft="@dimen/tabs_panel_list_padding"
                                           android:paddingRight="@dimen/tabs_panel_list_padding"
                                           android:scrollbarStyle="outsideOverlay"/>
 
         </view>
 
-        <View android:layout_width="fill_parent"
-              android:layout_height="2dp"
-              android:background="#FF313131"/>
+        <LinearLayout android:id="@+id/tabs_panel_footer"
+                      android:layout_width="fill_parent"
+                      android:layout_height="@dimen/browser_toolbar_height"
+                      android:orientation="vertical">
+
+            <View android:layout_width="fill_parent"
+                  android:layout_height="2dp"
+                  android:background="#FF313131"/>
 
-        <view class="org.mozilla.gecko.TabsPanel$TabsPanelToolbar"
-              android:id="@+id/tabs_panel_footer"
-              android:layout_width="fill_parent"
-              android:layout_height="@dimen/browser_toolbar_height">
+            <view class="org.mozilla.gecko.TabsPanel$TabsPanelToolbar"
+                  android:layout_width="fill_parent"
+                  android:layout_height="0dip"
+                  android:layout_weight="1.0">
 
-            <include layout="@layout/tabs_panel_footer"/>
+                <include layout="@layout/tabs_panel_footer"/>
 
-        </view>
+            </view>
+
+        </LinearLayout>
 
    </LinearLayout>
 
 </merge>
--- a/mobile/android/base/resources/layout/tabs_panel.xml.in
+++ b/mobile/android/base/resources/layout/tabs_panel.xml.in
@@ -6,28 +6,35 @@
 
 <merge xmlns:android="http://schemas.android.com/apk/res/android"
        xmlns:gecko="http://schemas.android.com/apk/res/@ANDROID_PACKAGE_NAME@">
 
     <LinearLayout android:layout_width="fill_parent"
                   android:layout_height="wrap_content"
                   android:orientation="vertical">
 
-        <view class="org.mozilla.gecko.TabsPanel$TabsPanelToolbar"
-              android:id="@+id/tabs_panel_header"
-              android:layout_width="fill_parent"
-              android:layout_height="@dimen/browser_toolbar_height">
+        <LinearLayout android:id="@+id/tabs_panel_header"
+                      android:layout_width="fill_parent"
+                      android:layout_height="@dimen/browser_toolbar_height"
+                      android:orientation="vertical">
+
+            <view class="org.mozilla.gecko.TabsPanel$TabsPanelToolbar"
+                  android:layout_width="fill_parent"
+                  android:layout_height="0dip"
+                  android:layout_weight="1.0">
 
-            <include layout="@layout/tabs_panel_header"/>
+                <include layout="@layout/tabs_panel_header"/>
 
-        </view>
+            </view>
 
-        <View android:layout_width="fill_parent"
-              android:layout_height="2dp"
-              android:background="#FF313131"/>
+            <View android:layout_width="fill_parent"
+                  android:layout_height="2dp"
+                  android:background="#FF313131"/>
+
+        </LinearLayout>
 
         <view class="org.mozilla.gecko.TabsPanel$TabsListContainer"
               android:id="@android:id/tabcontent"
               android:layout_width="fill_parent"
               android:layout_height="wrap_content">
 
             <org.mozilla.gecko.TabsTray android:id="@+id/normal_tabs"
                                         style="@style/TabsList"