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

Unified Diff: ash/root_window_controller.cc

Issue 1954523002: Refactors StackingController::GetDefaultParent to ash/wm/common (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: update gyp 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/root_window_controller.h ('k') | ash/shell_window_ids.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/root_window_controller.cc
diff --git a/ash/root_window_controller.cc b/ash/root_window_controller.cc
index 3f1c005594f8de635cffff554cf186af721eda60..d4e9d54f46839f0cdd8618e43dbd7a68b361a19d 100644
--- a/ash/root_window_controller.cc
+++ b/ash/root_window_controller.cc
@@ -35,6 +35,7 @@
#include "ash/wm/aura/wm_shelf_aura.h"
#include "ash/wm/aura/wm_window_aura.h"
#include "ash/wm/common/always_on_top_controller.h"
+#include "ash/wm/common/container_finder.h"
#include "ash/wm/common/dock/docked_window_layout_manager.h"
#include "ash/wm/common/fullscreen_window_finder.h"
#include "ash/wm/common/panels/panel_layout_manager.h"
@@ -321,15 +322,6 @@ RootWindowController* RootWindowController::ForTargetRootWindow() {
return GetRootWindowController(Shell::GetTargetRootWindow());
}
-// static
-aura::Window* RootWindowController::GetContainerForWindow(
- aura::Window* window) {
- aura::Window* container = window->parent();
- while (container && container->type() != ui::wm::WINDOW_TYPE_UNKNOWN)
- container = container->parent();
- return container;
-}
-
RootWindowController::~RootWindowController() {
Shutdown();
ash_host_.reset();
@@ -409,7 +401,8 @@ SystemModalContainerLayoutManager*
RootWindowController::GetSystemModalLayoutManager(aura::Window* window) {
aura::Window* modal_container = NULL;
if (window) {
- aura::Window* window_container = GetContainerForWindow(window);
+ aura::Window* window_container = wm::WmWindowAura::GetAuraWindow(
+ wm::GetContainerForWindow(wm::WmWindowAura::Get(window)));
if (window_container &&
window_container->id() >= kShellWindowId_LockScreenContainer) {
modal_container = GetContainer(kShellWindowId_LockSystemModalContainer);
« no previous file with comments | « ash/root_window_controller.h ('k') | ash/shell_window_ids.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698