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

Side by Side Diff: ash/shell/shell_delegate_impl.cc

Issue 9788001: Remove stops_event_propagation from Window, since it's broken. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 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 | Annotate | Revision Log
Property Changes:
Added: svn:eol-style
+ LF
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #include "ash/shell/shell_delegate_impl.h"
6
7 #include "ash/shell/example_factory.h"
8 #include "ash/shell/launcher_delegate_impl.h"
9 #include "ash/shell_window_ids.h"
10 #include "ash/wm/partial_screenshot_view.h"
11 #include "base/message_loop.h"
12 #include "ui/aura/window.h"
13
14 namespace ash {
15 namespace shell {
16
17 ShellDelegateImpl::ShellDelegateImpl()
18 : watcher_(NULL),
19 launcher_delegate_(NULL),
20 locked_(false) {
21 }
22
23 ShellDelegateImpl::~ShellDelegateImpl() {
24 }
25
26 void ShellDelegateImpl::SetWatcher(WindowWatcher* watcher) {
27 watcher_ = watcher;
28 if (launcher_delegate_)
29 launcher_delegate_->set_watcher(watcher);
30 }
31
32 views::Widget* ShellDelegateImpl::CreateStatusArea() {
33 return NULL;
34 }
35
36 void ShellDelegateImpl::LockScreen() {
37 ash::shell::CreateLockScreen();
38 locked_ = true;
39 }
40
41 void ShellDelegateImpl::UnlockScreen() {
42 locked_ = false;
43 }
44
45 bool ShellDelegateImpl::IsScreenLocked() const {
46 return locked_;
47 }
48
49 void ShellDelegateImpl::Exit() {
50 MessageLoopForUI::current()->Quit();
51 }
52
53 ash::AppListViewDelegate* ShellDelegateImpl::CreateAppListViewDelegate() {
54 return ash::shell::CreateAppListViewDelegate();
55 }
56
57 std::vector<aura::Window*> ShellDelegateImpl::GetCycleWindowList(
58 CycleSource source) const {
59 aura::Window* default_container = ash::Shell::GetInstance()->GetContainer(
60 ash::internal::kShellWindowId_DefaultContainer);
61 std::vector<aura::Window*> windows = default_container->children();
62 // Window cycling expects the topmost window at the front of the list.
63 std::reverse(windows.begin(), windows.end());
64 return windows;
65 }
66
67 void ShellDelegateImpl::StartPartialScreenshot(
68 ash::ScreenshotDelegate* screenshot_delegate) {
69 ash::PartialScreenshotView::StartPartialScreenshot(screenshot_delegate);
70 }
71
72 ash::LauncherDelegate* ShellDelegateImpl::CreateLauncherDelegate(
73 ash::LauncherModel* model) {
74 launcher_delegate_ = new LauncherDelegateImpl(watcher_);
75 return launcher_delegate_;
76 }
77
78 ash::SystemTrayDelegate* ShellDelegateImpl::CreateSystemTrayDelegate(
79 ash::SystemTray* tray) {
80 return NULL;
81 }
82
83 } // namespace shell
84 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698