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

Unified Diff: ash/wm/drag_details.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
« no previous file with comments | « ash/wm/drag_details.h ('k') | ash/wm/gestures/shelf_gesture_handler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/wm/drag_details.cc
diff --git a/ash/wm/drag_details.cc b/ash/wm/drag_details.cc
index 67bbedc123fb1aa41b546728bd0821df115eca8d..9c293bb4decbf1337a4fd54900b265437a7e16cf 100644
--- a/ash/wm/drag_details.cc
+++ b/ash/wm/drag_details.cc
@@ -4,6 +4,7 @@
#include "ash/wm/drag_details.h"
+#include "ash/wm/common/wm_window.h"
#include "ash/wm/window_resizer.h"
#include "ui/aura/window.h"
#include "ui/base/hit_test.h"
@@ -41,14 +42,14 @@ int GetSizeChangeDirectionForWindowComponent(int window_component) {
} // namespace
-DragDetails::DragDetails(aura::Window* window,
+DragDetails::DragDetails(wm::WmWindow* window,
const gfx::Point& location,
int window_component,
aura::client::WindowMoveSource source)
- : initial_state_type(wm::GetWindowState(window)->GetStateType()),
- initial_bounds_in_parent(window->bounds()),
+ : initial_state_type(window->GetWindowState()->GetStateType()),
+ initial_bounds_in_parent(window->GetBounds()),
initial_location_in_parent(location),
- initial_opacity(window->layer()->opacity()),
+ initial_opacity(window->GetLayer()->opacity()),
window_component(window_component),
bounds_change(
WindowResizer::GetBoundsChangeForWindowComponent(window_component)),
@@ -59,9 +60,9 @@ DragDetails::DragDetails(aura::Window* window,
GetSizeChangeDirectionForWindowComponent(window_component)),
is_resizable(bounds_change != WindowResizer::kBoundsChangeDirection_None),
source(source),
- should_attach_to_shelf(window->type() == ui::wm::WINDOW_TYPE_PANEL &&
- wm::GetWindowState(window)->panel_attached()) {
- wm::WindowState* window_state = wm::GetWindowState(window);
+ should_attach_to_shelf(window->GetType() == ui::wm::WINDOW_TYPE_PANEL &&
+ window->GetWindowState()->panel_attached()) {
+ wm::WindowState* window_state = window->GetWindowState();
if ((window_state->IsNormalOrSnapped() || window_state->IsDocked()) &&
window_state->HasRestoreBounds() &&
window_component == HTCAPTION) {
« no previous file with comments | « ash/wm/drag_details.h ('k') | ash/wm/gestures/shelf_gesture_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698