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

Unified Diff: ash/wm/dock/docked_window_layout_manager.cc

Issue 357063002: Snap widgets to pixel boundary on ash (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: adjust tests Created 6 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 | « ash/wm/dock/docked_window_layout_manager.h ('k') | ash/wm/lock_layout_manager.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/wm/dock/docked_window_layout_manager.cc
diff --git a/ash/wm/dock/docked_window_layout_manager.cc b/ash/wm/dock/docked_window_layout_manager.cc
index 7bb93da63c7c6d614e8010082123fd94aaa0b967..14ccaa37329ea6a35b616c08f37d6c41097d51dd 100644
--- a/ash/wm/dock/docked_window_layout_manager.cc
+++ b/ash/wm/dock/docked_window_layout_manager.cc
@@ -402,8 +402,10 @@ class DockedWindowLayoutManager::ShelfWindowObserver : public WindowObserver {
////////////////////////////////////////////////////////////////////////////////
// DockedWindowLayoutManager public implementation:
DockedWindowLayoutManager::DockedWindowLayoutManager(
- aura::Window* dock_container, WorkspaceController* workspace_controller)
- : dock_container_(dock_container),
+ aura::Window* dock_container,
+ WorkspaceController* workspace_controller)
+ : SnapToPixelLayoutManager(dock_container),
+ dock_container_(dock_container),
in_layout_(false),
dragged_window_(NULL),
is_dragged_window_docked_(false),
@@ -411,7 +413,7 @@ DockedWindowLayoutManager::DockedWindowLayoutManager(
shelf_(NULL),
workspace_controller_(workspace_controller),
in_fullscreen_(workspace_controller_->GetWindowState() ==
- WORKSPACE_WINDOW_STATE_FULL_SCREEN),
+ WORKSPACE_WINDOW_STATE_FULL_SCREEN),
docked_width_(0),
alignment_(DOCKED_ALIGNMENT_NONE),
last_active_window_(NULL),
@@ -716,10 +718,10 @@ void DockedWindowLayoutManager::SetChildBounds(
actual_new_bounds.set_height(
std::max(min_size.height(), actual_new_bounds.height()));
}
- // Whenever one of our windows is moved or resized enforce layout.
- SetChildBoundsDirect(child, actual_new_bounds);
+ SnapToPixelLayoutManager::SetChildBounds(child, actual_new_bounds);
if (IsPopupOrTransient(child))
return;
+ // Whenever one of our windows is moved or resized enforce layout.
ShelfLayoutManager* shelf_layout =
ShelfLayoutManager::ForShelf(dock_container_);
if (shelf_layout)
« no previous file with comments | « ash/wm/dock/docked_window_layout_manager.h ('k') | ash/wm/lock_layout_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698