diff options
Diffstat (limited to 'chrome/browser/window_sizer.cc')
-rw-r--r-- | chrome/browser/window_sizer.cc | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/chrome/browser/window_sizer.cc b/chrome/browser/window_sizer.cc index 74956d2..59eed33 100644 --- a/chrome/browser/window_sizer.cc +++ b/chrome/browser/window_sizer.cc @@ -151,6 +151,7 @@ bool WindowSizer::GetLastWindowBounds(gfx::Rect* bounds) const { if (!state_provider_ || !state_provider_->GetLastActiveWindowState(bounds)) return false; gfx::Rect last_window_bounds = *bounds; + bounds->Offset(monitor_info_provider_->GetBoundsOffsetMatching(*bounds)); bounds->Offset(kWindowTilePixels, kWindowTilePixels); AdjustBoundsToBeVisibleOnMonitorContaining(last_window_bounds, bounds); return true; @@ -162,9 +163,7 @@ bool WindowSizer::GetSavedWindowBounds(gfx::Rect* bounds, 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; } |