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

Side by Side Diff: ash/wm/event_client_impl.cc

Issue 2734933004: ash: Use SessionController instead of SessionStateDelegate (Closed)
Patch Set: rebase to get WorkspaceLayoutManagerSoloTest change Created 3 years, 9 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 unified diff | Download patch
« no previous file with comments | « ash/wm/ash_focus_rules_unittest.cc ('k') | ash/wm/lock_state_controller_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ash/wm/event_client_impl.h" 5 #include "ash/wm/event_client_impl.h"
6 6
7 #include "ash/common/session/session_state_delegate.h" 7 #include "ash/common/session/session_controller.h"
8 #include "ash/common/wm_shell.h" 8 #include "ash/common/wm_shell.h"
9 #include "ash/public/cpp/shell_window_ids.h" 9 #include "ash/public/cpp/shell_window_ids.h"
10 #include "ash/shell.h" 10 #include "ash/shell.h"
11 #include "ui/aura/window.h" 11 #include "ui/aura/window.h"
12 #include "ui/keyboard/keyboard_util.h" 12 #include "ui/keyboard/keyboard_util.h"
13 13
14 namespace ash { 14 namespace ash {
15 15
16 EventClientImpl::EventClientImpl() {} 16 EventClientImpl::EventClientImpl() {}
17 17
18 EventClientImpl::~EventClientImpl() {} 18 EventClientImpl::~EventClientImpl() {}
19 19
20 bool EventClientImpl::CanProcessEventsWithinSubtree( 20 bool EventClientImpl::CanProcessEventsWithinSubtree(
21 const aura::Window* window) const { 21 const aura::Window* window) const {
22 // TODO(oshima): Migrate this logic to Shell::CanWindowReceieveEvents and 22 // TODO(oshima): Migrate this logic to Shell::CanWindowReceieveEvents and
23 // remove this. 23 // remove this.
24 const aura::Window* root_window = window ? window->GetRootWindow() : NULL; 24 const aura::Window* root_window = window ? window->GetRootWindow() : NULL;
25 if (!root_window || 25 if (!root_window ||
26 !WmShell::Get()->GetSessionStateDelegate()->IsUserSessionBlocked()) { 26 !WmShell::Get()->session_controller()->IsUserSessionBlocked()) {
27 return true; 27 return true;
28 } 28 }
29 29
30 const aura::Window* lock_screen_containers = Shell::GetContainer( 30 const aura::Window* lock_screen_containers = Shell::GetContainer(
31 root_window, kShellWindowId_LockScreenContainersContainer); 31 root_window, kShellWindowId_LockScreenContainersContainer);
32 const aura::Window* lock_wallpaper_containers = Shell::GetContainer( 32 const aura::Window* lock_wallpaper_containers = Shell::GetContainer(
33 root_window, kShellWindowId_LockScreenWallpaperContainer); 33 root_window, kShellWindowId_LockScreenWallpaperContainer);
34 const aura::Window* lock_screen_related_containers = Shell::GetContainer( 34 const aura::Window* lock_screen_related_containers = Shell::GetContainer(
35 root_window, kShellWindowId_LockScreenRelatedContainersContainer); 35 root_window, kShellWindowId_LockScreenRelatedContainersContainer);
36 bool can_process_events = 36 bool can_process_events =
(...skipping 10 matching lines...) Expand all
47 virtual_keyboard_container->Contains(window)); 47 virtual_keyboard_container->Contains(window));
48 } 48 }
49 return can_process_events; 49 return can_process_events;
50 } 50 }
51 51
52 ui::EventTarget* EventClientImpl::GetToplevelEventTarget() { 52 ui::EventTarget* EventClientImpl::GetToplevelEventTarget() {
53 return Shell::GetInstance(); 53 return Shell::GetInstance();
54 } 54 }
55 55
56 } // namespace ash 56 } // namespace ash
OLDNEW
« no previous file with comments | « ash/wm/ash_focus_rules_unittest.cc ('k') | ash/wm/lock_state_controller_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698