gecko-dev/mobile/android/base/TabsPanel.java

239 lines
7.8 KiB
Java
Raw Normal View History

Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
/* -*- Mode: Java; c-basic-offset: 4; tab-width: 20; indent-tabs-mode: nil; -*-
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
* You can obtain one at http://mozilla.org/MPL/2.0/. */
package org.mozilla.gecko;
import org.mozilla.gecko.sync.setup.SyncAccounts;
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
import android.content.Context;
Bug 776309: Support for 7" tablet-ish + phone-ish interface. [r=mbrubeck] --HG-- rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_back_button_bg.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_back_button_bg.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_back_button_pressed_bg.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_back_button_pressed_bg.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_texture_tablet.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_texture_tablet.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_url_default.9.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_url_default.9.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_url_pressed.9.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_url_pressed.9.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_awesomebar_go.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_awesomebar_go.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_awesomebar_search.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_awesomebar_search.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_bookmark_add.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_bookmark_add.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_bookmark_remove.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_bookmark_remove.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_forward.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_forward.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_reload.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_reload.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/reader.png => mobile/android/base/resources/drawable-large-hdpi-v11/reader.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/remote_tabs_off.png => mobile/android/base/resources/drawable-large-hdpi-v11/remote_tabs_off.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/remote_tabs_on.png => mobile/android/base/resources/drawable-large-hdpi-v11/remote_tabs_on.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/site_security_identified.png => mobile/android/base/resources/drawable-large-hdpi-v11/site_security_identified.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/site_security_verified.png => mobile/android/base/resources/drawable-large-hdpi-v11/site_security_verified.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tab_new.png => mobile/android/base/resources/drawable-large-hdpi-v11/tab_new.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/urlbar_stop.png => mobile/android/base/resources/drawable-large-hdpi-v11/urlbar_stop.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_back_button_bg.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_back_button_bg.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_back_button_pressed_bg.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_back_button_pressed_bg.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_bg.xml => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_bg.xml rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_texture_tablet.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_texture_tablet.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_url_default.9.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_url_default.9.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_url_pressed.9.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_url_pressed.9.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_awesomebar_go.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_awesomebar_go.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_awesomebar_search.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_awesomebar_search.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_bookmark_add.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_bookmark_add.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_bookmark_remove.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_bookmark_remove.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_forward.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_forward.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_reload.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_reload.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/reader.png => mobile/android/base/resources/drawable-large-mdpi-v11/reader.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/remote_tabs_off.png => mobile/android/base/resources/drawable-large-mdpi-v11/remote_tabs_off.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/remote_tabs_on.png => mobile/android/base/resources/drawable-large-mdpi-v11/remote_tabs_on.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/site_security_identified.png => mobile/android/base/resources/drawable-large-mdpi-v11/site_security_identified.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/site_security_verified.png => mobile/android/base/resources/drawable-large-mdpi-v11/site_security_verified.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tab_new.png => mobile/android/base/resources/drawable-large-mdpi-v11/tab_new.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/urlbar_stop.png => mobile/android/base/resources/drawable-large-mdpi-v11/urlbar_stop.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_back_button_bg.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_back_button_bg.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_back_button_pressed_bg.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_back_button_pressed_bg.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_texture_tablet.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_texture_tablet.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_url_default.9.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_url_default.9.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_url_pressed.9.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_url_pressed.9.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_awesomebar_go.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_awesomebar_go.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_awesomebar_search.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_awesomebar_search.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_bookmark_add.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_bookmark_add.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_bookmark_remove.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_bookmark_remove.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_forward.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_forward.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_reload.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_reload.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/reader.png => mobile/android/base/resources/drawable-large-xhdpi-v11/reader.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/remote_tabs_off.png => mobile/android/base/resources/drawable-large-xhdpi-v11/remote_tabs_off.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/remote_tabs_on.png => mobile/android/base/resources/drawable-large-xhdpi-v11/remote_tabs_on.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/site_security_identified.png => mobile/android/base/resources/drawable-large-xhdpi-v11/site_security_identified.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/site_security_verified.png => mobile/android/base/resources/drawable-large-xhdpi-v11/site_security_verified.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tab_new.png => mobile/android/base/resources/drawable-large-xhdpi-v11/tab_new.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/urlbar_stop.png => mobile/android/base/resources/drawable-large-xhdpi-v11/urlbar_stop.png rename : mobile/android/base/resources/layout-xlarge/doorhangerpopup.xml => mobile/android/base/resources/layout-large-v11/doorhangerpopup.xml rename : mobile/android/base/resources/layout-xlarge/site_identity_popup.xml => mobile/android/base/resources/layout-large-v11/site_identity_popup.xml rename : mobile/android/base/resources/layout-xlarge/gecko_app.xml => mobile/android/base/resources/layout-xlarge-v11/gecko_app.xml.in rename : mobile/android/base/resources/layout-xlarge/tabs_panel_toolbar_menu.xml => mobile/android/base/resources/layout-xlarge-v11/tabs_panel_toolbar_menu.xml rename : mobile/android/base/resources/layout/gecko_app.xml => mobile/android/base/resources/layout/gecko_app.xml.in rename : mobile/android/base/resources/values-xlarge/styles.xml => mobile/android/base/resources/values-xlarge-v11/styles.xml extra : rebase_source : a36dfaae46a01769dadcf2f70756f35e19f5bbe6
2012-07-23 20:08:48 +00:00
import android.content.res.TypedArray;
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
import android.util.AttributeSet;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.Button;
import android.widget.ImageButton;
import android.widget.LinearLayout;
import android.widget.RelativeLayout;
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
import android.widget.TextView;
public class TabsPanel extends LinearLayout {
private static final String LOGTAG = "GeckoTabsPanel";
public static enum Panel {
LOCAL_TABS,
REMOTE_TABS
}
public static interface PanelView {
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
public ViewGroup getLayout();
public void setTabsPanel(TabsPanel panel);
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
public void show();
public void hide();
}
public static interface TabsLayoutChangeListener {
public void onTabsLayoutChange(int width, int height);
}
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
private Context mContext;
private GeckoApp mActivity;
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
private PanelView mPanel;
private TabsPanelToolbar mToolbar;
private TabsListContainer mListContainer;
private TabsLayoutChangeListener mLayoutChangeListener;
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
private static ImageButton mRemoteTabs;
private TextView mTitle;
private Panel mCurrentPanel;
Bug 776309: Support for 7" tablet-ish + phone-ish interface. [r=mbrubeck] --HG-- rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_back_button_bg.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_back_button_bg.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_back_button_pressed_bg.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_back_button_pressed_bg.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_texture_tablet.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_texture_tablet.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_url_default.9.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_url_default.9.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_url_pressed.9.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_url_pressed.9.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_awesomebar_go.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_awesomebar_go.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_awesomebar_search.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_awesomebar_search.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_bookmark_add.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_bookmark_add.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_bookmark_remove.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_bookmark_remove.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_forward.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_forward.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_reload.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_reload.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/reader.png => mobile/android/base/resources/drawable-large-hdpi-v11/reader.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/remote_tabs_off.png => mobile/android/base/resources/drawable-large-hdpi-v11/remote_tabs_off.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/remote_tabs_on.png => mobile/android/base/resources/drawable-large-hdpi-v11/remote_tabs_on.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/site_security_identified.png => mobile/android/base/resources/drawable-large-hdpi-v11/site_security_identified.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/site_security_verified.png => mobile/android/base/resources/drawable-large-hdpi-v11/site_security_verified.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tab_new.png => mobile/android/base/resources/drawable-large-hdpi-v11/tab_new.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/urlbar_stop.png => mobile/android/base/resources/drawable-large-hdpi-v11/urlbar_stop.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_back_button_bg.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_back_button_bg.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_back_button_pressed_bg.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_back_button_pressed_bg.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_bg.xml => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_bg.xml rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_texture_tablet.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_texture_tablet.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_url_default.9.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_url_default.9.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_url_pressed.9.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_url_pressed.9.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_awesomebar_go.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_awesomebar_go.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_awesomebar_search.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_awesomebar_search.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_bookmark_add.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_bookmark_add.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_bookmark_remove.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_bookmark_remove.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_forward.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_forward.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_reload.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_reload.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/reader.png => mobile/android/base/resources/drawable-large-mdpi-v11/reader.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/remote_tabs_off.png => mobile/android/base/resources/drawable-large-mdpi-v11/remote_tabs_off.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/remote_tabs_on.png => mobile/android/base/resources/drawable-large-mdpi-v11/remote_tabs_on.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/site_security_identified.png => mobile/android/base/resources/drawable-large-mdpi-v11/site_security_identified.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/site_security_verified.png => mobile/android/base/resources/drawable-large-mdpi-v11/site_security_verified.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tab_new.png => mobile/android/base/resources/drawable-large-mdpi-v11/tab_new.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/urlbar_stop.png => mobile/android/base/resources/drawable-large-mdpi-v11/urlbar_stop.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_back_button_bg.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_back_button_bg.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_back_button_pressed_bg.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_back_button_pressed_bg.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_texture_tablet.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_texture_tablet.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_url_default.9.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_url_default.9.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_url_pressed.9.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_url_pressed.9.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_awesomebar_go.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_awesomebar_go.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_awesomebar_search.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_awesomebar_search.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_bookmark_add.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_bookmark_add.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_bookmark_remove.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_bookmark_remove.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_forward.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_forward.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_reload.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_reload.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/reader.png => mobile/android/base/resources/drawable-large-xhdpi-v11/reader.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/remote_tabs_off.png => mobile/android/base/resources/drawable-large-xhdpi-v11/remote_tabs_off.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/remote_tabs_on.png => mobile/android/base/resources/drawable-large-xhdpi-v11/remote_tabs_on.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/site_security_identified.png => mobile/android/base/resources/drawable-large-xhdpi-v11/site_security_identified.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/site_security_verified.png => mobile/android/base/resources/drawable-large-xhdpi-v11/site_security_verified.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tab_new.png => mobile/android/base/resources/drawable-large-xhdpi-v11/tab_new.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/urlbar_stop.png => mobile/android/base/resources/drawable-large-xhdpi-v11/urlbar_stop.png rename : mobile/android/base/resources/layout-xlarge/doorhangerpopup.xml => mobile/android/base/resources/layout-large-v11/doorhangerpopup.xml rename : mobile/android/base/resources/layout-xlarge/site_identity_popup.xml => mobile/android/base/resources/layout-large-v11/site_identity_popup.xml rename : mobile/android/base/resources/layout-xlarge/gecko_app.xml => mobile/android/base/resources/layout-xlarge-v11/gecko_app.xml.in rename : mobile/android/base/resources/layout-xlarge/tabs_panel_toolbar_menu.xml => mobile/android/base/resources/layout-xlarge-v11/tabs_panel_toolbar_menu.xml rename : mobile/android/base/resources/layout/gecko_app.xml => mobile/android/base/resources/layout/gecko_app.xml.in rename : mobile/android/base/resources/values-xlarge/styles.xml => mobile/android/base/resources/values-xlarge-v11/styles.xml extra : rebase_source : a36dfaae46a01769dadcf2f70756f35e19f5bbe6
2012-07-23 20:08:48 +00:00
private boolean mIsSideBar;
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
private boolean mVisible;
private static final int REMOTE_TABS_HIDDEN = 1;
private static final int REMOTE_TABS_SHOWN = 2;
public TabsPanel(Context context, AttributeSet attrs) {
super(context, attrs);
mContext = context;
mActivity = (GeckoApp) context;
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
setOrientation(LinearLayout.VERTICAL);
LayoutInflater.from(context).inflate(R.layout.tabs_panel, this);
mCurrentPanel = Panel.LOCAL_TABS;
mVisible = false;
Bug 776309: Support for 7" tablet-ish + phone-ish interface. [r=mbrubeck] --HG-- rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_back_button_bg.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_back_button_bg.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_back_button_pressed_bg.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_back_button_pressed_bg.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_texture_tablet.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_texture_tablet.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_url_default.9.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_url_default.9.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_url_pressed.9.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_url_pressed.9.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_awesomebar_go.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_awesomebar_go.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_awesomebar_search.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_awesomebar_search.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_bookmark_add.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_bookmark_add.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_bookmark_remove.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_bookmark_remove.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_forward.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_forward.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_reload.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_reload.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/reader.png => mobile/android/base/resources/drawable-large-hdpi-v11/reader.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/remote_tabs_off.png => mobile/android/base/resources/drawable-large-hdpi-v11/remote_tabs_off.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/remote_tabs_on.png => mobile/android/base/resources/drawable-large-hdpi-v11/remote_tabs_on.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/site_security_identified.png => mobile/android/base/resources/drawable-large-hdpi-v11/site_security_identified.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/site_security_verified.png => mobile/android/base/resources/drawable-large-hdpi-v11/site_security_verified.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tab_new.png => mobile/android/base/resources/drawable-large-hdpi-v11/tab_new.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/urlbar_stop.png => mobile/android/base/resources/drawable-large-hdpi-v11/urlbar_stop.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_back_button_bg.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_back_button_bg.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_back_button_pressed_bg.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_back_button_pressed_bg.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_bg.xml => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_bg.xml rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_texture_tablet.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_texture_tablet.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_url_default.9.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_url_default.9.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_url_pressed.9.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_url_pressed.9.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_awesomebar_go.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_awesomebar_go.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_awesomebar_search.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_awesomebar_search.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_bookmark_add.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_bookmark_add.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_bookmark_remove.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_bookmark_remove.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_forward.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_forward.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_reload.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_reload.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/reader.png => mobile/android/base/resources/drawable-large-mdpi-v11/reader.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/remote_tabs_off.png => mobile/android/base/resources/drawable-large-mdpi-v11/remote_tabs_off.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/remote_tabs_on.png => mobile/android/base/resources/drawable-large-mdpi-v11/remote_tabs_on.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/site_security_identified.png => mobile/android/base/resources/drawable-large-mdpi-v11/site_security_identified.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/site_security_verified.png => mobile/android/base/resources/drawable-large-mdpi-v11/site_security_verified.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tab_new.png => mobile/android/base/resources/drawable-large-mdpi-v11/tab_new.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/urlbar_stop.png => mobile/android/base/resources/drawable-large-mdpi-v11/urlbar_stop.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_back_button_bg.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_back_button_bg.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_back_button_pressed_bg.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_back_button_pressed_bg.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_texture_tablet.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_texture_tablet.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_url_default.9.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_url_default.9.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_url_pressed.9.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_url_pressed.9.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_awesomebar_go.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_awesomebar_go.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_awesomebar_search.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_awesomebar_search.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_bookmark_add.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_bookmark_add.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_bookmark_remove.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_bookmark_remove.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_forward.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_forward.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_reload.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_reload.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/reader.png => mobile/android/base/resources/drawable-large-xhdpi-v11/reader.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/remote_tabs_off.png => mobile/android/base/resources/drawable-large-xhdpi-v11/remote_tabs_off.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/remote_tabs_on.png => mobile/android/base/resources/drawable-large-xhdpi-v11/remote_tabs_on.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/site_security_identified.png => mobile/android/base/resources/drawable-large-xhdpi-v11/site_security_identified.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/site_security_verified.png => mobile/android/base/resources/drawable-large-xhdpi-v11/site_security_verified.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tab_new.png => mobile/android/base/resources/drawable-large-xhdpi-v11/tab_new.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/urlbar_stop.png => mobile/android/base/resources/drawable-large-xhdpi-v11/urlbar_stop.png rename : mobile/android/base/resources/layout-xlarge/doorhangerpopup.xml => mobile/android/base/resources/layout-large-v11/doorhangerpopup.xml rename : mobile/android/base/resources/layout-xlarge/site_identity_popup.xml => mobile/android/base/resources/layout-large-v11/site_identity_popup.xml rename : mobile/android/base/resources/layout-xlarge/gecko_app.xml => mobile/android/base/resources/layout-xlarge-v11/gecko_app.xml.in rename : mobile/android/base/resources/layout-xlarge/tabs_panel_toolbar_menu.xml => mobile/android/base/resources/layout-xlarge-v11/tabs_panel_toolbar_menu.xml rename : mobile/android/base/resources/layout/gecko_app.xml => mobile/android/base/resources/layout/gecko_app.xml.in rename : mobile/android/base/resources/values-xlarge/styles.xml => mobile/android/base/resources/values-xlarge-v11/styles.xml extra : rebase_source : a36dfaae46a01769dadcf2f70756f35e19f5bbe6
2012-07-23 20:08:48 +00:00
TypedArray a = context.obtainStyledAttributes(attrs, R.styleable.TabsPanel);
mIsSideBar = a.getBoolean(R.styleable.TabsPanel_sidebar, false);
a.recycle();
mToolbar = (TabsPanelToolbar) findViewById(R.id.toolbar);
mListContainer = (TabsListContainer) findViewById(R.id.list_container);
initToolbar();
}
void initToolbar() {
mTitle = (TextView) mToolbar.findViewById(R.id.title);
ImageButton addTab = (ImageButton) mToolbar.findViewById(R.id.add_tab);
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
addTab.setOnClickListener(new Button.OnClickListener() {
public void onClick(View v) {
mActivity.addTab();
mActivity.autoHideTabs();
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
}
});
mRemoteTabs = (ImageButton) mToolbar.findViewById(R.id.remote_tabs);
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
mRemoteTabs.setOnClickListener(new Button.OnClickListener() {
public void onClick(View v) {
if (mRemoteTabs.getDrawable().getLevel() == REMOTE_TABS_SHOWN)
mActivity.showLocalTabs();
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
else
mActivity.showRemoteTabs();
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
}
});
}
// Tabs List Container holds the ListView
public static class TabsListContainer extends LinearLayout {
private Context mContext;
public TabsListContainer(Context context, AttributeSet attrs) {
super(context, attrs);
mContext = context;
}
@Override
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
Bug 776309: Support for 7" tablet-ish + phone-ish interface. [r=mbrubeck] --HG-- rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_back_button_bg.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_back_button_bg.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_back_button_pressed_bg.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_back_button_pressed_bg.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_texture_tablet.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_texture_tablet.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_url_default.9.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_url_default.9.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_url_pressed.9.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_url_pressed.9.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_awesomebar_go.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_awesomebar_go.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_awesomebar_search.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_awesomebar_search.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_bookmark_add.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_bookmark_add.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_bookmark_remove.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_bookmark_remove.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_forward.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_forward.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_reload.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_reload.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/reader.png => mobile/android/base/resources/drawable-large-hdpi-v11/reader.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/remote_tabs_off.png => mobile/android/base/resources/drawable-large-hdpi-v11/remote_tabs_off.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/remote_tabs_on.png => mobile/android/base/resources/drawable-large-hdpi-v11/remote_tabs_on.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/site_security_identified.png => mobile/android/base/resources/drawable-large-hdpi-v11/site_security_identified.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/site_security_verified.png => mobile/android/base/resources/drawable-large-hdpi-v11/site_security_verified.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tab_new.png => mobile/android/base/resources/drawable-large-hdpi-v11/tab_new.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/urlbar_stop.png => mobile/android/base/resources/drawable-large-hdpi-v11/urlbar_stop.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_back_button_bg.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_back_button_bg.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_back_button_pressed_bg.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_back_button_pressed_bg.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_bg.xml => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_bg.xml rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_texture_tablet.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_texture_tablet.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_url_default.9.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_url_default.9.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_url_pressed.9.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_url_pressed.9.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_awesomebar_go.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_awesomebar_go.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_awesomebar_search.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_awesomebar_search.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_bookmark_add.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_bookmark_add.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_bookmark_remove.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_bookmark_remove.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_forward.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_forward.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_reload.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_reload.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/reader.png => mobile/android/base/resources/drawable-large-mdpi-v11/reader.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/remote_tabs_off.png => mobile/android/base/resources/drawable-large-mdpi-v11/remote_tabs_off.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/remote_tabs_on.png => mobile/android/base/resources/drawable-large-mdpi-v11/remote_tabs_on.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/site_security_identified.png => mobile/android/base/resources/drawable-large-mdpi-v11/site_security_identified.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/site_security_verified.png => mobile/android/base/resources/drawable-large-mdpi-v11/site_security_verified.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tab_new.png => mobile/android/base/resources/drawable-large-mdpi-v11/tab_new.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/urlbar_stop.png => mobile/android/base/resources/drawable-large-mdpi-v11/urlbar_stop.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_back_button_bg.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_back_button_bg.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_back_button_pressed_bg.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_back_button_pressed_bg.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_texture_tablet.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_texture_tablet.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_url_default.9.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_url_default.9.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_url_pressed.9.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_url_pressed.9.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_awesomebar_go.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_awesomebar_go.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_awesomebar_search.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_awesomebar_search.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_bookmark_add.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_bookmark_add.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_bookmark_remove.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_bookmark_remove.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_forward.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_forward.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_reload.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_reload.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/reader.png => mobile/android/base/resources/drawable-large-xhdpi-v11/reader.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/remote_tabs_off.png => mobile/android/base/resources/drawable-large-xhdpi-v11/remote_tabs_off.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/remote_tabs_on.png => mobile/android/base/resources/drawable-large-xhdpi-v11/remote_tabs_on.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/site_security_identified.png => mobile/android/base/resources/drawable-large-xhdpi-v11/site_security_identified.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/site_security_verified.png => mobile/android/base/resources/drawable-large-xhdpi-v11/site_security_verified.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tab_new.png => mobile/android/base/resources/drawable-large-xhdpi-v11/tab_new.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/urlbar_stop.png => mobile/android/base/resources/drawable-large-xhdpi-v11/urlbar_stop.png rename : mobile/android/base/resources/layout-xlarge/doorhangerpopup.xml => mobile/android/base/resources/layout-large-v11/doorhangerpopup.xml rename : mobile/android/base/resources/layout-xlarge/site_identity_popup.xml => mobile/android/base/resources/layout-large-v11/site_identity_popup.xml rename : mobile/android/base/resources/layout-xlarge/gecko_app.xml => mobile/android/base/resources/layout-xlarge-v11/gecko_app.xml.in rename : mobile/android/base/resources/layout-xlarge/tabs_panel_toolbar_menu.xml => mobile/android/base/resources/layout-xlarge-v11/tabs_panel_toolbar_menu.xml rename : mobile/android/base/resources/layout/gecko_app.xml => mobile/android/base/resources/layout/gecko_app.xml.in rename : mobile/android/base/resources/values-xlarge/styles.xml => mobile/android/base/resources/values-xlarge-v11/styles.xml extra : rebase_source : a36dfaae46a01769dadcf2f70756f35e19f5bbe6
2012-07-23 20:08:48 +00:00
if (!GeckoApp.mAppContext.hasTabsSideBar()) {
int heightSpec = MeasureSpec.makeMeasureSpec((int) (0.5 * mContext.getResources().getDisplayMetrics().heightPixels), MeasureSpec.EXACTLY);
super.onMeasure(widthMeasureSpec, heightSpec);
} else {
super.onMeasure(widthMeasureSpec, heightMeasureSpec);
}
}
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
}
// Tabs Panel Toolbar contains the Buttons
public static class TabsPanelToolbar extends RelativeLayout {
public TabsPanelToolbar(Context context, AttributeSet attrs) {
super(context, attrs);
setLayoutParams(new LinearLayout.LayoutParams(LinearLayout.LayoutParams.FILL_PARENT,
(int) context.getResources().getDimension(R.dimen.browser_toolbar_height)));
Bug 772684: Extending support for HDPI + ICS that don't have a tabs tail. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_normal.png => mobile/android/base/resources/drawable-hdpi/tabs_crop_normal.png rename : mobile/android/base/resources/drawable-hdpi/tabs_pressed.png => mobile/android/base/resources/drawable-hdpi/tabs_crop_pressed.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_normal.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_crop_normal.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_pressed.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_crop_pressed.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_normal.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_crop_normal.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_pressed.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_crop_pressed.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_normal.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_full_normal.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_pressed.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_full_pressed.png rename : mobile/android/base/resources/drawable-large-hdpi/tabs_expanded_normal.png => mobile/android/base/resources/drawable-large-hdpi/tabs_crop_expanded_normal.png rename : mobile/android/base/resources/drawable-large-hdpi/tabs_expanded_pressed.png => mobile/android/base/resources/drawable-large-hdpi/tabs_crop_expanded_pressed.png rename : mobile/android/base/resources/drawable-large-hdpi/tabs_normal.png => mobile/android/base/resources/drawable-large-hdpi/tabs_crop_normal.png rename : mobile/android/base/resources/drawable-large-hdpi/tabs_pressed.png => mobile/android/base/resources/drawable-large-hdpi/tabs_crop_pressed.png rename : mobile/android/base/resources/drawable-large-mdpi/tabs_button.xml => mobile/android/base/resources/drawable-large-mdpi/tabs_crop_button.xml rename : mobile/android/base/resources/drawable-large-mdpi/tabs_expanded_normal.png => mobile/android/base/resources/drawable-large-mdpi/tabs_crop_expanded_normal.png rename : mobile/android/base/resources/drawable-large-mdpi/tabs_expanded_pressed.png => mobile/android/base/resources/drawable-large-mdpi/tabs_crop_expanded_pressed.png rename : mobile/android/base/resources/drawable-large-mdpi/tabs_normal.png => mobile/android/base/resources/drawable-large-mdpi/tabs_crop_normal.png rename : mobile/android/base/resources/drawable-large-mdpi/tabs_pressed.png => mobile/android/base/resources/drawable-large-mdpi/tabs_crop_pressed.png rename : mobile/android/base/resources/drawable-large-xhdpi/tabs_expanded_normal.png => mobile/android/base/resources/drawable-large-xhdpi/tabs_crop_expanded_normal.png rename : mobile/android/base/resources/drawable-large-xhdpi/tabs_expanded_pressed.png => mobile/android/base/resources/drawable-large-xhdpi/tabs_crop_expanded_pressed.png rename : mobile/android/base/resources/drawable-large-xhdpi/tabs_normal.png => mobile/android/base/resources/drawable-large-xhdpi/tabs_crop_normal.png rename : mobile/android/base/resources/drawable-large-xhdpi/tabs_pressed.png => mobile/android/base/resources/drawable-large-xhdpi/tabs_crop_pressed.png rename : mobile/android/base/resources/drawable-xhdpi-v14/menu.png => mobile/android/base/resources/drawable-xhdpi-v11/menu.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_normal.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_crop_normal.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_pressed.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_crop_pressed.png rename : mobile/android/base/resources/drawable-xhdpi-v14/tabs_normal.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_full_normal.png rename : mobile/android/base/resources/drawable-xhdpi-v14/tabs_pressed.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_full_pressed.png rename : mobile/android/base/resources/drawable/tabs_button.xml => mobile/android/base/resources/drawable/tabs_crop_button.xml rename : mobile/android/base/resources/drawable/tabs_button_contracted.xml => mobile/android/base/resources/drawable/tabs_crop_button_contracted.xml rename : mobile/android/base/resources/drawable-large-mdpi/tabs_button_expanded.xml => mobile/android/base/resources/drawable/tabs_crop_button_expanded.xml rename : mobile/android/base/resources/drawable/tabs_normal.png => mobile/android/base/resources/drawable/tabs_crop_normal.png rename : mobile/android/base/resources/drawable/tabs_pressed.png => mobile/android/base/resources/drawable/tabs_crop_pressed.png rename : mobile/android/base/resources/layout-land-v14/tabs_panel_toolbar.xml => mobile/android/base/resources/layout-land-v14/tabs_panel_toolbar_menu.xml rename : mobile/android/base/resources/layout-v14/browser_toolbar.xml => mobile/android/base/resources/layout/browser_toolbar_menu.xml rename : mobile/android/base/resources/layout-v14/tabs_panel_toolbar.xml => mobile/android/base/resources/layout/tabs_panel_toolbar_menu.xml
2012-07-12 22:03:09 +00:00
int panelToolbarRes;
Bug 776309: Support for 7" tablet-ish + phone-ish interface. [r=mbrubeck] --HG-- rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_back_button_bg.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_back_button_bg.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_back_button_pressed_bg.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_back_button_pressed_bg.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_texture_tablet.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_texture_tablet.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_url_default.9.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_url_default.9.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_url_pressed.9.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_url_pressed.9.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_awesomebar_go.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_awesomebar_go.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_awesomebar_search.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_awesomebar_search.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_bookmark_add.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_bookmark_add.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_bookmark_remove.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_bookmark_remove.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_forward.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_forward.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_reload.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_reload.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/reader.png => mobile/android/base/resources/drawable-large-hdpi-v11/reader.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/remote_tabs_off.png => mobile/android/base/resources/drawable-large-hdpi-v11/remote_tabs_off.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/remote_tabs_on.png => mobile/android/base/resources/drawable-large-hdpi-v11/remote_tabs_on.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/site_security_identified.png => mobile/android/base/resources/drawable-large-hdpi-v11/site_security_identified.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/site_security_verified.png => mobile/android/base/resources/drawable-large-hdpi-v11/site_security_verified.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tab_new.png => mobile/android/base/resources/drawable-large-hdpi-v11/tab_new.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/urlbar_stop.png => mobile/android/base/resources/drawable-large-hdpi-v11/urlbar_stop.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_back_button_bg.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_back_button_bg.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_back_button_pressed_bg.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_back_button_pressed_bg.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_bg.xml => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_bg.xml rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_texture_tablet.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_texture_tablet.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_url_default.9.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_url_default.9.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_url_pressed.9.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_url_pressed.9.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_awesomebar_go.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_awesomebar_go.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_awesomebar_search.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_awesomebar_search.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_bookmark_add.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_bookmark_add.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_bookmark_remove.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_bookmark_remove.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_forward.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_forward.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_reload.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_reload.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/reader.png => mobile/android/base/resources/drawable-large-mdpi-v11/reader.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/remote_tabs_off.png => mobile/android/base/resources/drawable-large-mdpi-v11/remote_tabs_off.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/remote_tabs_on.png => mobile/android/base/resources/drawable-large-mdpi-v11/remote_tabs_on.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/site_security_identified.png => mobile/android/base/resources/drawable-large-mdpi-v11/site_security_identified.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/site_security_verified.png => mobile/android/base/resources/drawable-large-mdpi-v11/site_security_verified.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tab_new.png => mobile/android/base/resources/drawable-large-mdpi-v11/tab_new.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/urlbar_stop.png => mobile/android/base/resources/drawable-large-mdpi-v11/urlbar_stop.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_back_button_bg.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_back_button_bg.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_back_button_pressed_bg.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_back_button_pressed_bg.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_texture_tablet.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_texture_tablet.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_url_default.9.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_url_default.9.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_url_pressed.9.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_url_pressed.9.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_awesomebar_go.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_awesomebar_go.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_awesomebar_search.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_awesomebar_search.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_bookmark_add.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_bookmark_add.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_bookmark_remove.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_bookmark_remove.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_forward.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_forward.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_reload.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_reload.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/reader.png => mobile/android/base/resources/drawable-large-xhdpi-v11/reader.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/remote_tabs_off.png => mobile/android/base/resources/drawable-large-xhdpi-v11/remote_tabs_off.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/remote_tabs_on.png => mobile/android/base/resources/drawable-large-xhdpi-v11/remote_tabs_on.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/site_security_identified.png => mobile/android/base/resources/drawable-large-xhdpi-v11/site_security_identified.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/site_security_verified.png => mobile/android/base/resources/drawable-large-xhdpi-v11/site_security_verified.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tab_new.png => mobile/android/base/resources/drawable-large-xhdpi-v11/tab_new.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/urlbar_stop.png => mobile/android/base/resources/drawable-large-xhdpi-v11/urlbar_stop.png rename : mobile/android/base/resources/layout-xlarge/doorhangerpopup.xml => mobile/android/base/resources/layout-large-v11/doorhangerpopup.xml rename : mobile/android/base/resources/layout-xlarge/site_identity_popup.xml => mobile/android/base/resources/layout-large-v11/site_identity_popup.xml rename : mobile/android/base/resources/layout-xlarge/gecko_app.xml => mobile/android/base/resources/layout-xlarge-v11/gecko_app.xml.in rename : mobile/android/base/resources/layout-xlarge/tabs_panel_toolbar_menu.xml => mobile/android/base/resources/layout-xlarge-v11/tabs_panel_toolbar_menu.xml rename : mobile/android/base/resources/layout/gecko_app.xml => mobile/android/base/resources/layout/gecko_app.xml.in rename : mobile/android/base/resources/values-xlarge/styles.xml => mobile/android/base/resources/values-xlarge-v11/styles.xml extra : rebase_source : a36dfaae46a01769dadcf2f70756f35e19f5bbe6
2012-07-23 20:08:48 +00:00
if (!GeckoApp.mAppContext.hasPermanentMenuKey())
Bug 772684: Extending support for HDPI + ICS that don't have a tabs tail. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_normal.png => mobile/android/base/resources/drawable-hdpi/tabs_crop_normal.png rename : mobile/android/base/resources/drawable-hdpi/tabs_pressed.png => mobile/android/base/resources/drawable-hdpi/tabs_crop_pressed.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_normal.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_crop_normal.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_pressed.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_crop_pressed.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_normal.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_crop_normal.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_pressed.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_crop_pressed.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_normal.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_full_normal.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_pressed.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_full_pressed.png rename : mobile/android/base/resources/drawable-large-hdpi/tabs_expanded_normal.png => mobile/android/base/resources/drawable-large-hdpi/tabs_crop_expanded_normal.png rename : mobile/android/base/resources/drawable-large-hdpi/tabs_expanded_pressed.png => mobile/android/base/resources/drawable-large-hdpi/tabs_crop_expanded_pressed.png rename : mobile/android/base/resources/drawable-large-hdpi/tabs_normal.png => mobile/android/base/resources/drawable-large-hdpi/tabs_crop_normal.png rename : mobile/android/base/resources/drawable-large-hdpi/tabs_pressed.png => mobile/android/base/resources/drawable-large-hdpi/tabs_crop_pressed.png rename : mobile/android/base/resources/drawable-large-mdpi/tabs_button.xml => mobile/android/base/resources/drawable-large-mdpi/tabs_crop_button.xml rename : mobile/android/base/resources/drawable-large-mdpi/tabs_expanded_normal.png => mobile/android/base/resources/drawable-large-mdpi/tabs_crop_expanded_normal.png rename : mobile/android/base/resources/drawable-large-mdpi/tabs_expanded_pressed.png => mobile/android/base/resources/drawable-large-mdpi/tabs_crop_expanded_pressed.png rename : mobile/android/base/resources/drawable-large-mdpi/tabs_normal.png => mobile/android/base/resources/drawable-large-mdpi/tabs_crop_normal.png rename : mobile/android/base/resources/drawable-large-mdpi/tabs_pressed.png => mobile/android/base/resources/drawable-large-mdpi/tabs_crop_pressed.png rename : mobile/android/base/resources/drawable-large-xhdpi/tabs_expanded_normal.png => mobile/android/base/resources/drawable-large-xhdpi/tabs_crop_expanded_normal.png rename : mobile/android/base/resources/drawable-large-xhdpi/tabs_expanded_pressed.png => mobile/android/base/resources/drawable-large-xhdpi/tabs_crop_expanded_pressed.png rename : mobile/android/base/resources/drawable-large-xhdpi/tabs_normal.png => mobile/android/base/resources/drawable-large-xhdpi/tabs_crop_normal.png rename : mobile/android/base/resources/drawable-large-xhdpi/tabs_pressed.png => mobile/android/base/resources/drawable-large-xhdpi/tabs_crop_pressed.png rename : mobile/android/base/resources/drawable-xhdpi-v14/menu.png => mobile/android/base/resources/drawable-xhdpi-v11/menu.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_normal.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_crop_normal.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_pressed.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_crop_pressed.png rename : mobile/android/base/resources/drawable-xhdpi-v14/tabs_normal.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_full_normal.png rename : mobile/android/base/resources/drawable-xhdpi-v14/tabs_pressed.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_full_pressed.png rename : mobile/android/base/resources/drawable/tabs_button.xml => mobile/android/base/resources/drawable/tabs_crop_button.xml rename : mobile/android/base/resources/drawable/tabs_button_contracted.xml => mobile/android/base/resources/drawable/tabs_crop_button_contracted.xml rename : mobile/android/base/resources/drawable-large-mdpi/tabs_button_expanded.xml => mobile/android/base/resources/drawable/tabs_crop_button_expanded.xml rename : mobile/android/base/resources/drawable/tabs_normal.png => mobile/android/base/resources/drawable/tabs_crop_normal.png rename : mobile/android/base/resources/drawable/tabs_pressed.png => mobile/android/base/resources/drawable/tabs_crop_pressed.png rename : mobile/android/base/resources/layout-land-v14/tabs_panel_toolbar.xml => mobile/android/base/resources/layout-land-v14/tabs_panel_toolbar_menu.xml rename : mobile/android/base/resources/layout-v14/browser_toolbar.xml => mobile/android/base/resources/layout/browser_toolbar_menu.xml rename : mobile/android/base/resources/layout-v14/tabs_panel_toolbar.xml => mobile/android/base/resources/layout/tabs_panel_toolbar_menu.xml
2012-07-12 22:03:09 +00:00
panelToolbarRes = R.layout.tabs_panel_toolbar_menu;
else
panelToolbarRes = R.layout.tabs_panel_toolbar;
LayoutInflater.from(context).inflate(panelToolbarRes, this);
}
}
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
public void show(Panel panel) {
if (mPanel != null) {
// Remove the old panel.
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
mPanel.hide();
mListContainer.removeAllViews();
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
}
mVisible = true;
mCurrentPanel = panel;
if (panel == Panel.LOCAL_TABS) {
mPanel = new TabsTray(mContext, null);
mTitle.setText("");
mRemoteTabs.setImageLevel(REMOTE_TABS_HIDDEN);
} else {
mPanel = new RemoteTabs(mContext, null);
mTitle.setText(R.string.remote_tabs);
mRemoteTabs.setVisibility(View.VISIBLE);
mRemoteTabs.setImageLevel(REMOTE_TABS_SHOWN);
}
mPanel.setTabsPanel(this);
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
mPanel.show();
mListContainer.addView(mPanel.getLayout());
if (isSideBar()) {
dispatchLayoutChange(getWidth(), getHeight());
} else {
int actionBarHeight = (int) (mContext.getResources().getDimension(R.dimen.browser_toolbar_height));
// TabsListContainer takes time to resize on rotation.
// It's better to add 50% of the screen-size and dispatch it as height.
int listHeight = (int) (0.5 * mContext.getResources().getDisplayMetrics().heightPixels);
int height = actionBarHeight + listHeight;
dispatchLayoutChange(getWidth(), height);
}
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
// If Sync is set up, query the database for remote clients.
final Context context = mContext;
new SyncAccounts.AccountsExistTask() {
@Override
protected void onPostExecute(Boolean result) {
if (!result.booleanValue()) {
return;
}
TabsAccessor.areClientsAvailable(context, new TabsAccessor.OnClientsAvailableListener() {
@Override
public void areAvailable(boolean available) {
final int visibility = available ? View.VISIBLE : View.GONE;
mRemoteTabs.setVisibility(visibility);
}
});
}
}.execute(context);
}
public void hide() {
if (mVisible) {
mVisible = false;
dispatchLayoutChange(0, 0);
}
}
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
public void refresh() {
mListContainer.forceLayout();
int index = indexOfChild(mToolbar);
removeViewAt(index);
mToolbar = new TabsPanelToolbar(mContext, null);
addView(mToolbar, index);
initToolbar();
if (mVisible)
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
show(mCurrentPanel);
}
public void autoHidePanel() {
mActivity.autoHideTabs();
}
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
@Override
public boolean isShown() {
return mVisible;
}
Bug 776309: Support for 7" tablet-ish + phone-ish interface. [r=mbrubeck] --HG-- rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_back_button_bg.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_back_button_bg.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_back_button_pressed_bg.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_back_button_pressed_bg.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_texture_tablet.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_texture_tablet.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_url_default.9.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_url_default.9.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/address_bar_url_pressed.9.png => mobile/android/base/resources/drawable-large-hdpi-v11/address_bar_url_pressed.9.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_awesomebar_go.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_awesomebar_go.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_awesomebar_search.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_awesomebar_search.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_bookmark_add.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_bookmark_add.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_bookmark_remove.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_bookmark_remove.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_forward.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_forward.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/ic_menu_reload.png => mobile/android/base/resources/drawable-large-hdpi-v11/ic_menu_reload.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/reader.png => mobile/android/base/resources/drawable-large-hdpi-v11/reader.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/remote_tabs_off.png => mobile/android/base/resources/drawable-large-hdpi-v11/remote_tabs_off.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/remote_tabs_on.png => mobile/android/base/resources/drawable-large-hdpi-v11/remote_tabs_on.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/site_security_identified.png => mobile/android/base/resources/drawable-large-hdpi-v11/site_security_identified.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/site_security_verified.png => mobile/android/base/resources/drawable-large-hdpi-v11/site_security_verified.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tab_new.png => mobile/android/base/resources/drawable-large-hdpi-v11/tab_new.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/urlbar_stop.png => mobile/android/base/resources/drawable-large-hdpi-v11/urlbar_stop.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_back_button_bg.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_back_button_bg.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_back_button_pressed_bg.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_back_button_pressed_bg.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_bg.xml => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_bg.xml rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_texture_tablet.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_texture_tablet.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_url_default.9.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_url_default.9.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/address_bar_url_pressed.9.png => mobile/android/base/resources/drawable-large-mdpi-v11/address_bar_url_pressed.9.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_awesomebar_go.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_awesomebar_go.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_awesomebar_search.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_awesomebar_search.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_bookmark_add.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_bookmark_add.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_bookmark_remove.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_bookmark_remove.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_forward.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_forward.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/ic_menu_reload.png => mobile/android/base/resources/drawable-large-mdpi-v11/ic_menu_reload.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/reader.png => mobile/android/base/resources/drawable-large-mdpi-v11/reader.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/remote_tabs_off.png => mobile/android/base/resources/drawable-large-mdpi-v11/remote_tabs_off.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/remote_tabs_on.png => mobile/android/base/resources/drawable-large-mdpi-v11/remote_tabs_on.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/site_security_identified.png => mobile/android/base/resources/drawable-large-mdpi-v11/site_security_identified.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/site_security_verified.png => mobile/android/base/resources/drawable-large-mdpi-v11/site_security_verified.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tab_new.png => mobile/android/base/resources/drawable-large-mdpi-v11/tab_new.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/urlbar_stop.png => mobile/android/base/resources/drawable-large-mdpi-v11/urlbar_stop.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_back_button_bg.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_back_button_bg.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_back_button_pressed_bg.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_back_button_pressed_bg.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_texture_tablet.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_texture_tablet.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_url_default.9.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_url_default.9.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/address_bar_url_pressed.9.png => mobile/android/base/resources/drawable-large-xhdpi-v11/address_bar_url_pressed.9.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_awesomebar_go.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_awesomebar_go.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_awesomebar_search.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_awesomebar_search.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_bookmark_add.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_bookmark_add.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_bookmark_remove.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_bookmark_remove.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_forward.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_forward.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/ic_menu_reload.png => mobile/android/base/resources/drawable-large-xhdpi-v11/ic_menu_reload.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/reader.png => mobile/android/base/resources/drawable-large-xhdpi-v11/reader.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/remote_tabs_off.png => mobile/android/base/resources/drawable-large-xhdpi-v11/remote_tabs_off.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/remote_tabs_on.png => mobile/android/base/resources/drawable-large-xhdpi-v11/remote_tabs_on.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/site_security_identified.png => mobile/android/base/resources/drawable-large-xhdpi-v11/site_security_identified.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/site_security_verified.png => mobile/android/base/resources/drawable-large-xhdpi-v11/site_security_verified.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tab_new.png => mobile/android/base/resources/drawable-large-xhdpi-v11/tab_new.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/urlbar_stop.png => mobile/android/base/resources/drawable-large-xhdpi-v11/urlbar_stop.png rename : mobile/android/base/resources/layout-xlarge/doorhangerpopup.xml => mobile/android/base/resources/layout-large-v11/doorhangerpopup.xml rename : mobile/android/base/resources/layout-xlarge/site_identity_popup.xml => mobile/android/base/resources/layout-large-v11/site_identity_popup.xml rename : mobile/android/base/resources/layout-xlarge/gecko_app.xml => mobile/android/base/resources/layout-xlarge-v11/gecko_app.xml.in rename : mobile/android/base/resources/layout-xlarge/tabs_panel_toolbar_menu.xml => mobile/android/base/resources/layout-xlarge-v11/tabs_panel_toolbar_menu.xml rename : mobile/android/base/resources/layout/gecko_app.xml => mobile/android/base/resources/layout/gecko_app.xml.in rename : mobile/android/base/resources/values-xlarge/styles.xml => mobile/android/base/resources/values-xlarge-v11/styles.xml extra : rebase_source : a36dfaae46a01769dadcf2f70756f35e19f5bbe6
2012-07-23 20:08:48 +00:00
public boolean isSideBar() {
return mIsSideBar;
}
public void setTabsLayoutChangeListener(TabsLayoutChangeListener listener) {
mLayoutChangeListener = listener;
}
private void dispatchLayoutChange(int width, int height) {
if (mLayoutChangeListener != null)
mLayoutChangeListener.onTabsLayoutChange(width, height);
}
Bug 739407: Make Tabs UI tablet ready. [r=mfinkle] --HG-- rename : mobile/android/base/resources/drawable-hdpi/tabs_more.png => mobile/android/base/resources/drawable-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-land-hdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-hdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-mdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-mdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_more.png => mobile/android/base/resources/drawable-land-xhdpi-v14/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-sw600dp-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xhdpi-v11/tabs_more.png => mobile/android/base/resources/drawable-xhdpi-v11/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-hdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-hdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-mdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-mdpi/tabs_carat.png rename : mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_more.png => mobile/android/base/resources/drawable-xlarge-xhdpi/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_more.png => mobile/android/base/resources/drawable/tabs_carat.png rename : mobile/android/base/resources/drawable/tabs_tray_list_selector.xml => mobile/android/base/resources/drawable/tabs_tray_default_selector.xml
2012-06-08 04:47:22 +00:00
}