Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(8089)

Unified Diff: chrome/browser/views/location_bar_view.h

Issue 160180: Merge 21312 - This CL fixes issue 2780 RTL: Omnibar message "Press Tab to s... (Closed) Base URL: svn://chrome-svn/chrome/branches/195/src/
Patch Set: Created 11 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/browser/views/location_bar_view.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/views/location_bar_view.h
===================================================================
--- chrome/browser/views/location_bar_view.h (revision 21666)
+++ chrome/browser/views/location_bar_view.h (working copy)
@@ -383,30 +383,32 @@
// Returns the height in pixels of the margin at the top of the bar.
int TopMargin() const;
- // Returns the width in pixels of the contents of the edit.
- int TextDisplayWidth();
+ // Returns the amount of horizontal space (in pixels) out of
+ // |location_bar_width| that is not taken up by the actual text in
+ // location_entry_.
+ int AvailableWidth(int location_bar_width);
- // Returns true if the preferred size should be used for a view whose width
- // is pref_width, the width of the text in the edit is text_width, and
- // max_width is the maximum width of the edit. If this returns false, the
+ // Returns whether the |available_width| is large enough to contain a view
+ // with preferred width |pref_width| at its preferred size. If this returns
+ // true, the preferred size should be used. If this returns false, the
// minimum size of the view should be used.
- bool UsePref(int pref_width, int text_width, int max_width);
+ bool UsePref(int pref_width, int available_width);
// Returns true if the view needs to be resized. This determines whether the
// min or pref should be used, and returns true if the view is not at that
// size.
- bool NeedsResize(View* view, int text_width, int max_width);
+ bool NeedsResize(View* view, int available_width);
// Adjusts the keyword hint, selected keyword and type to search views
// based on the contents of the edit. Returns true if something changed that
// necessitates a layout.
- bool AdjustHints(int text_width, int max_width);
+ bool AdjustHints(int available_width);
// If View fits in the specified region, it is made visible and the
// bounds are adjusted appropriately. If the View does not fit, it is
// made invisible.
- void LayoutView(bool leading, views::View* view, int text_width,
- int max_width, gfx::Rect* bounds);
+ void LayoutView(bool leading, views::View* view, int available_width,
+ gfx::Rect* bounds);
// Sets the security icon to display. Note that no repaint is done.
void SetSecurityIcon(ToolbarModel::Icon icon);
Property changes on: chrome\browser\views\location_bar_view.h
___________________________________________________________________
Added: svn:mergeinfo
Merged /trunk/src/chrome/browser/views/location_bar_view.h:r21312
Merged /branches/chrome_webkit_merge_branch/chrome/browser/views/location_bar_view.h:r69-2775
« no previous file with comments | « no previous file | chrome/browser/views/location_bar_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698