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

Unified Diff: ash/wm/shelf_layout_manager.cc

Issue 9784010: Fixes bug where maximized window wasn't getting resized when toggling (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 9 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 | ash/wm/shelf_layout_manager_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/wm/shelf_layout_manager.cc
diff --git a/ash/wm/shelf_layout_manager.cc b/ash/wm/shelf_layout_manager.cc
index 348c05810fab21dc9c33865bec8cdd6ca61e71f6..6af5daf2ec8ba4d0e2d752c72d50466f8679c938 100644
--- a/ash/wm/shelf_layout_manager.cc
+++ b/ash/wm/shelf_layout_manager.cc
@@ -345,8 +345,13 @@ void ShelfLayoutManager::CalculateTargetBounds(
target_bounds->opacity =
(state.visibility_state == VISIBLE ||
state.visibility_state == AUTO_HIDE) ? 1.0f : 0.0f;
- target_bounds->work_area_insets =
- gfx::Insets(0, 0, shelf_height, 0);
+
+ int work_area_bottom = 0;
+ if (state.visibility_state == VISIBLE)
+ work_area_bottom = shelf_height_;
+ else if (state.visibility_state == AUTO_HIDE)
+ work_area_bottom = kAutoHideHeight;
+ target_bounds->work_area_insets.Set(0, 0, work_area_bottom, 0);
}
void ShelfLayoutManager::UpdateShelfBackground(
« no previous file with comments | « no previous file | ash/wm/shelf_layout_manager_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698