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

Unified Diff: ash/wm/workspace/workspace_window_resizer.cc

Issue 1890713002: Adds WmWindow and converts WindowState to use it (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: merge again Created 4 years, 8 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: ash/wm/workspace/workspace_window_resizer.cc
diff --git a/ash/wm/workspace/workspace_window_resizer.cc b/ash/wm/workspace/workspace_window_resizer.cc
index 84d4d14d3ec874184745ae29267a83f93c21074d..ed20fb5583eee937d5eb2791c48b3ddf4753f7b0 100644
--- a/ash/wm/workspace/workspace_window_resizer.cc
+++ b/ash/wm/workspace/workspace_window_resizer.cc
@@ -22,6 +22,7 @@
#include "ash/wm/drag_window_resizer.h"
#include "ash/wm/panels/panel_window_resizer.h"
#include "ash/wm/window_state.h"
+#include "ash/wm/window_state_aura.h"
#include "ash/wm/window_util.h"
#include "ash/wm/workspace/phantom_window_controller.h"
#include "ash/wm/workspace/two_step_edge_cycler.h"
@@ -81,8 +82,7 @@ std::unique_ptr<WindowResizer> CreateWindowResizer(
if (bounds_change == WindowResizer::kBoundsChangeDirection_None)
return std::unique_ptr<WindowResizer>();
- window_state->CreateDragDetails(window, point_in_parent, window_component,
- source);
+ window_state->CreateDragDetails(point_in_parent, window_component, source);
if (window->parent() &&
(window->parent()->id() == kShellWindowId_DefaultContainer ||
window->parent()->id() == kShellWindowId_DockedContainer ||
@@ -764,15 +764,14 @@ bool WorkspaceWindowResizer::UpdateMagnetismWindow(const gfx::Rect& bounds,
for (aura::Window::Windows::const_reverse_iterator i = children.rbegin();
i != children.rend() && !matcher.AreEdgesObscured(); ++i) {
wm::WindowState* other_state = wm::GetWindowState(*i);
- if (other_state->window() == GetTarget() ||
+ if (other_state->aura_window() == GetTarget() ||
!other_state->window()->IsVisible() ||
- !other_state->IsNormalOrSnapped() ||
- !other_state->CanResize()) {
+ !other_state->IsNormalOrSnapped() || !other_state->CanResize()) {
continue;
}
if (matcher.ShouldAttach(
other_state->window()->GetBoundsInScreen(), &magnetism_edge_)) {
- magnetism_window_ = other_state->window();
+ magnetism_window_ = other_state->aura_window();
window_tracker_.Add(magnetism_window_);
return true;
}
« no previous file with comments | « ash/wm/workspace/workspace_layout_manager_unittest.cc ('k') | ash/wm/workspace/workspace_window_resizer_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698