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

Unified Diff: ash/root_window_controller.cc

Issue 114643003: Use a single ToplevelWindowEventHandler for the ash::Shell (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years 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.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 8332a2ab6c6936563794b57c5de7eb4365a051bb..ccc99da7c1c20ffe99fcb734a78384674396b757 100644
--- a/ash/root_window_controller.cc
+++ b/ash/root_window_controller.cc
@@ -41,7 +41,6 @@
#include "ash/wm/status_area_layout_manager.h"
#include "ash/wm/system_background_controller.h"
#include "ash/wm/system_modal_container_layout_manager.h"
-#include "ash/wm/toplevel_window_event_handler.h"
#include "ash/wm/window_properties.h"
#include "ash/wm/window_state.h"
#include "ash/wm/window_util.h"
@@ -733,8 +732,6 @@ void RootWindowController::InitLayoutManagers() {
docked_layout_manager_ =
new internal::DockedWindowLayoutManager(docked_container,
workspace_controller());
- docked_container_handler_.reset(
- new ToplevelWindowEventHandler(docked_container));
docked_container->SetLayoutManager(docked_layout_manager_);
// Create Panel layout manager
@@ -742,9 +739,9 @@ void RootWindowController::InitLayoutManagers() {
internal::kShellWindowId_PanelContainer);
panel_layout_manager_ =
new internal::PanelLayoutManager(panel_container);
- panel_container_handler_.reset(
- new PanelWindowEventHandler(panel_container));
panel_container->SetLayoutManager(panel_layout_manager_);
+ panel_container_handler_.reset(new PanelWindowEventHandler);
+ panel_container->AddPreTargetHandler(panel_container_handler_.get());
}
void RootWindowController::InitTouchHuds() {
@@ -832,8 +829,6 @@ void RootWindowController::CreateContainersInRootWindow(
kShellWindowId_AlwaysOnTopContainer,
"AlwaysOnTopContainer",
non_lock_screen_containers);
- always_on_top_container_handler_.reset(
- new ToplevelWindowEventHandler(always_on_top_container));
views::corewm::SetChildWindowVisibilityChangesAnimated(
always_on_top_container);
SetUsesScreenCoordinates(always_on_top_container);
@@ -875,8 +870,6 @@ void RootWindowController::CreateContainersInRootWindow(
kShellWindowId_SystemModalContainer,
"SystemModalContainer",
non_lock_screen_containers);
- modal_container_handler_.reset(
- new ToplevelWindowEventHandler(modal_container));
modal_container->SetLayoutManager(
new SystemModalContainerLayoutManager(modal_container));
views::corewm::SetChildWindowVisibilityChangesAnimated(modal_container);
@@ -905,8 +898,6 @@ void RootWindowController::CreateContainersInRootWindow(
kShellWindowId_LockSystemModalContainer,
"LockSystemModalContainer",
lock_screen_containers);
- lock_modal_container_handler_.reset(
- new ToplevelWindowEventHandler(lock_modal_container));
lock_modal_container->SetLayoutManager(
new SystemModalContainerLayoutManager(lock_modal_container));
views::corewm::SetChildWindowVisibilityChangesAnimated(lock_modal_container);
« no previous file with comments | « ash/root_window_controller.h ('k') | ash/shell.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698