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

Unified Diff: chrome/browser/window_sizer.cc

Issue 125179: Fix: New window appears to the left/up if the taskbar is on left/top.... (Closed) Base URL: svn://chrome-svn.corp.google.com/chrome/trunk/src/
Patch Set: '' Created 11 years, 6 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 | « chrome/browser/window_sizer.h ('k') | chrome/browser/window_sizer_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/window_sizer.cc
===================================================================
--- chrome/browser/window_sizer.cc (revision 18780)
+++ chrome/browser/window_sizer.cc (working copy)
@@ -151,6 +151,7 @@
if (!state_provider_ || !state_provider_->GetLastActiveWindowState(bounds))
return false;
gfx::Rect last_window_bounds = *bounds;
+ bounds->Offset(monitor_info_provider_->GetBoundsOffsetMatching(*bounds));
Peter Kasting 2009/06/19 06:21:14 So wait a minute. I'm thinking about these more a
bounds->Offset(kWindowTilePixels, kWindowTilePixels);
AdjustBoundsToBeVisibleOnMonitorContaining(last_window_bounds, bounds);
return true;
@@ -162,9 +163,7 @@
if (!state_provider_ ||
!state_provider_->GetPersistentState(bounds, maximized))
return false;
- const gfx::Point& taskbar_offset =
- monitor_info_provider_->GetBoundsOffsetMatching(*bounds);
- bounds->Offset(taskbar_offset.x(), taskbar_offset.y());
+ bounds->Offset(monitor_info_provider_->GetBoundsOffsetMatching(*bounds));
AdjustBoundsToBeVisibleOnMonitorContaining(*bounds, bounds);
return true;
}
« no previous file with comments | « chrome/browser/window_sizer.h ('k') | chrome/browser/window_sizer_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698