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

Unified Diff: ash/wm/maximize_mode/maximize_mode_event_handler.cc

Issue 2908333003: [mus+ash] Removes WmWindow from ash (app_list, frame, metrics, session, system, wallpaper) (Closed)
Patch Set: [mus ash] Removes WmWindow from ash (rebase, nits and cleanup of use of ResizeHandleWindowTargeter) Created 3 years, 7 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/maximize_mode/maximize_mode_event_handler.cc
diff --git a/ash/wm/maximize_mode/maximize_mode_event_handler.cc b/ash/wm/maximize_mode/maximize_mode_event_handler.cc
index 0a38ac89c492ec95d7ba65c5d7ccaa22a77bc32f..392d0d204528332d8746a7797e5e776ffcb200eb 100644
--- a/ash/wm/maximize_mode/maximize_mode_event_handler.cc
+++ b/ash/wm/maximize_mode/maximize_mode_event_handler.cc
@@ -9,7 +9,7 @@
#include "ash/wm/window_state.h"
#include "ash/wm/window_util.h"
#include "ash/wm/wm_event.h"
-#include "ash/wm_window.h"
+#include "ui/aura/window.h"
#include "ui/events/event.h"
namespace ash {
@@ -38,18 +38,18 @@ bool MaximizeModeEventHandler::ToggleFullscreen(const ui::TouchEvent& event) {
}
// Find the active window (from the primary screen) to un-fullscreen.
- WmWindow* window = WmWindow::Get(GetActiveWindow());
+ aura::Window* window = GetActiveWindow();
if (!window)
return false;
- WindowState* window_state = window->GetWindowState();
+ WindowState* window_state = GetWindowState(window);
if (!window_state->IsFullscreen() || window_state->in_immersive_fullscreen())
return false;
// Test that the touch happened in the top or bottom lines.
int y = event.y();
if (y >= kLeaveFullScreenAreaHeightInPixel &&
- y < (window->GetBounds().height() - kLeaveFullScreenAreaHeightInPixel)) {
+ y < (window->bounds().height() - kLeaveFullScreenAreaHeightInPixel)) {
return false;
}
@@ -58,7 +58,7 @@ bool MaximizeModeEventHandler::ToggleFullscreen(const ui::TouchEvent& event) {
return false;
WMEvent toggle_fullscreen(WM_EVENT_TOGGLE_FULLSCREEN);
- window->GetWindowState()->OnWMEvent(&toggle_fullscreen);
+ GetWindowState(window)->OnWMEvent(&toggle_fullscreen);
return true;
}
« no previous file with comments | « ash/wm/lock_action_handler_layout_manager.cc ('k') | ash/wm/maximize_mode/maximize_mode_window_manager_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698