summaryrefslogtreecommitdiffstats
path: root/chrome/browser/gtk/location_bar_view_gtk.h
diff options
context:
space:
mode:
authorerg@chromium.org <erg@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-05-21 17:46:39 +0000
committererg@chromium.org <erg@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-05-21 17:46:39 +0000
commit2c1ac9f0811c272bf8d2b98aa0616e57b758c918 (patch)
tree0dcd7c318e4fd4cb227112b348fdb0329ca05e63 /chrome/browser/gtk/location_bar_view_gtk.h
parentbb89057200c7da78309804a8dc5ab1bd8f109182 (diff)
downloadchromium_src-2c1ac9f0811c272bf8d2b98aa0616e57b758c918.zip
chromium_src-2c1ac9f0811c272bf8d2b98aa0616e57b758c918.tar.gz
chromium_src-2c1ac9f0811c272bf8d2b98aa0616e57b758c918.tar.bz2
GTK: Elide the EV bubble to approximately half of the location bar when really long.
This only counts the non-icon area of the location bar. Unlike the windows implementation, the minimum size of the EV bubble is 10 characters instead of 150px. BUG=42856 TEST=Visit https://www.barbican.org.uk/eticketing/index.asp and make the window smaller. Review URL: http://codereview.chromium.org/2123015 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@47929 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/gtk/location_bar_view_gtk.h')
-rw-r--r--chrome/browser/gtk/location_bar_view_gtk.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/chrome/browser/gtk/location_bar_view_gtk.h b/chrome/browser/gtk/location_bar_view_gtk.h
index 43ccc7d..4cd11f9 100644
--- a/chrome/browser/gtk/location_bar_view_gtk.h
+++ b/chrome/browser/gtk/location_bar_view_gtk.h
@@ -284,6 +284,8 @@ class LocationBarViewGtk : public AutocompleteEditController,
GdkDragContext*);
CHROMEGTK_CALLBACK_1(LocationBarViewGtk, void, OnIconDragEnd,
GdkDragContext*);
+ CHROMEGTK_CALLBACK_1(LocationBarViewGtk, void, OnHboxSizeAllocate,
+ GtkAllocation*);
CHROMEGTK_CALLBACK_1(LocationBarViewGtk, void, OnEntryBoxSizeAllocate,
GtkAllocation*);
CHROMEGTK_CALLBACK_1(LocationBarViewGtk, gboolean, OnStarButtonPress,
@@ -293,6 +295,9 @@ class LocationBarViewGtk : public AutocompleteEditController,
// certificate information.
void UpdateSiteTypeArea();
+ // Updates the maximum size of the EV certificate label.
+ void UpdateEVCertificateLabelSize();
+
// Sets the text that should be displayed in the info label and its associated
// tooltip text. Call with an empty string if the info label should be
// hidden.
@@ -353,6 +358,9 @@ class LocationBarViewGtk : public AutocompleteEditController,
OwnedWidgetGtk page_action_hbox_;
ScopedVector<PageActionViewGtk> page_action_views_;
+ // The widget that contains our tab hints and the location bar.
+ GtkWidget* entry_box_;
+
// Area on the left shown when in tab to search mode.
GtkWidget* tab_to_search_box_;
GtkWidget* tab_to_search_full_label_;
@@ -397,6 +405,9 @@ class LocationBarViewGtk : public AutocompleteEditController,
NotificationRegistrar registrar_;
+ // Width of the main |hbox_|. Used to properly elide the EV certificate.
+ int hbox_width_;
+
// Width of the hbox that holds |tab_to_search_box_|, |location_entry_| and
// |tab_to_search_hint_|.
int entry_box_width_;