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

Unified Diff: ash/wm/aura/wm_globals_aura.cc

Issue 2012343002: Converts overview to use common ash types (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: feedback Created 4 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
« no previous file with comments | « ash/wm/aura/wm_globals_aura.h ('k') | ash/wm/aura/wm_window_aura.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/wm/aura/wm_globals_aura.cc
diff --git a/ash/wm/aura/wm_globals_aura.cc b/ash/wm/aura/wm_globals_aura.cc
index 17f107bd1910d5043d65b615e115cd6ac4dea6f7..b245f7278dca8b886bcf7ff293a3ff0e5bb54f13 100644
--- a/ash/wm/aura/wm_globals_aura.cc
+++ b/ash/wm/aura/wm_globals_aura.cc
@@ -50,6 +50,10 @@ WmWindow* WmGlobalsAura::GetActiveWindow() {
return WmWindowAura::Get(wm::GetActiveWindow());
}
+WmWindow* WmGlobalsAura::GetPrimaryRootWindow() {
+ return WmWindowAura::Get(Shell::GetPrimaryRootWindow());
+}
+
WmWindow* WmGlobalsAura::GetRootWindowForDisplayId(int64_t display_id) {
return WmWindowAura::Get(Shell::GetInstance()
->window_tree_host_manager()
@@ -60,14 +64,14 @@ WmWindow* WmGlobalsAura::GetRootWindowForNewWindows() {
return WmWindowAura::Get(Shell::GetTargetRootWindow());
}
+std::vector<WmWindow*> WmGlobalsAura::GetMruWindowList() {
+ return WmWindowAura::FromAuraWindows(
+ Shell::GetInstance()->mru_window_tracker()->BuildMruWindowList());
+}
+
std::vector<WmWindow*> WmGlobalsAura::GetMruWindowListIgnoreModals() {
- const std::vector<aura::Window*> windows = ash::Shell::GetInstance()
- ->mru_window_tracker()
- ->BuildWindowListIgnoreModal();
- std::vector<WmWindow*> wm_windows(windows.size());
- for (size_t i = 0; i < windows.size(); ++i)
- wm_windows[i] = WmWindowAura::Get(windows[i]);
- return wm_windows;
+ return WmWindowAura::FromAuraWindows(
+ Shell::GetInstance()->mru_window_tracker()->BuildWindowListIgnoreModal());
}
bool WmGlobalsAura::IsForceMaximizeOnFirstRun() {
@@ -83,11 +87,11 @@ bool WmGlobalsAura::IsScreenLocked() {
}
void WmGlobalsAura::LockCursor() {
- ash::Shell::GetInstance()->cursor_manager()->LockCursor();
+ Shell::GetInstance()->cursor_manager()->LockCursor();
}
void WmGlobalsAura::UnlockCursor() {
- ash::Shell::GetInstance()->cursor_manager()->UnlockCursor();
+ Shell::GetInstance()->cursor_manager()->UnlockCursor();
}
std::vector<WmWindow*> WmGlobalsAura::GetAllRootWindows() {
@@ -166,6 +170,14 @@ void WmGlobalsAura::OnWindowActivated(
WmWindowAura::Get(lost_active)));
}
+void WmGlobalsAura::OnAttemptToReactivateWindow(aura::Window* request_active,
+ aura::Window* actual_active) {
+ FOR_EACH_OBSERVER(
+ WmActivationObserver, activation_observers_,
+ OnAttemptToReactivateWindow(WmWindowAura::Get(request_active),
+ WmWindowAura::Get(actual_active)));
+}
+
void WmGlobalsAura::OnDisplayConfigurationChanging() {
FOR_EACH_OBSERVER(WmDisplayObserver, display_observers_,
OnDisplayConfigurationChanging());
« no previous file with comments | « ash/wm/aura/wm_globals_aura.h ('k') | ash/wm/aura/wm_window_aura.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698