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

Unified Diff: chrome/browser/ui/views/frame/browser_view_layout.cc

Issue 10933085: Update ConstrainedWindowViews appearance according to mock (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Browser test fixes Created 8 years, 2 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
Index: chrome/browser/ui/views/frame/browser_view_layout.cc
diff --git a/chrome/browser/ui/views/frame/browser_view_layout.cc b/chrome/browser/ui/views/frame/browser_view_layout.cc
index e58e090bb074a97e6389f9653c2ce92fc5a4705b..a8d7919e166c0d10a6c75ff910bdf2088e6340a5 100644
--- a/chrome/browser/ui/views/frame/browser_view_layout.cc
+++ b/chrome/browser/ui/views/frame/browser_view_layout.cc
@@ -35,6 +35,9 @@ const int kToolbarTabStripVerticalOverlap = 3;
const int kSpacerBookmarkBarOverlap = 1;
// The number of pixels the metro switcher is offset from the right edge.
const int kWindowSwitcherOffsetX = 7;
+// The number of pixels the constrained window should overlap the bottom
+// of the omnibox.
+const int kConstrainedWindowOverlap = 3;
// Combines View::ConvertPointToTarget and View::HitTest for a given |point|.
// Converts |point| from |src| to |dst| and hit tests it against |dst|. The
@@ -67,6 +70,10 @@ BrowserViewLayout::BrowserViewLayout()
BrowserViewLayout::~BrowserViewLayout() {
}
+int BrowserViewLayout::GetConstrainedWindowTopY() {
+ return constrained_window_top_y;
+}
+
gfx::Size BrowserViewLayout::GetMinimumSize() {
gfx::Size tabstrip_size(
browser()->SupportsWindowFeature(Browser::FEATURE_TABSTRIP) ?
@@ -368,6 +375,8 @@ int BrowserViewLayout::LayoutToolbar(int top) {
}
int BrowserViewLayout::LayoutBookmarkAndInfoBars(int top) {
+ constrained_window_top_y =
+ top + browser_view_->y() - kConstrainedWindowOverlap;
find_bar_y_ = top + browser_view_->y() - 1;
if (active_bookmark_bar_) {
// If we're showing the Bookmark bar in detached style, then we

Powered by Google App Engine
This is Rietveld 408576698