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

Side by Side Diff: chrome/browser/ui/ash/chrome_shell_delegate.cc

Issue 1921673005: mus: Add PointerWatcher for passively observing mouse and touch events (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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
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 "chrome/browser/ui/ash/chrome_shell_delegate.h" 5 #include "chrome/browser/ui/ash/chrome_shell_delegate.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include "ash/content/gpu_support_impl.h" 9 #include "ash/content/gpu_support_impl.h"
10 #include "ash/pointer_watcher_delegate_aura.h"
10 #include "ash/session/session_state_delegate.h" 11 #include "ash/session/session_state_delegate.h"
11 #include "ash/wm/window_state.h" 12 #include "ash/wm/window_state.h"
12 #include "ash/wm/window_util.h" 13 #include "ash/wm/window_util.h"
13 #include "build/build_config.h" 14 #include "build/build_config.h"
14 #include "chrome/browser/app_mode/app_mode_utils.h" 15 #include "chrome/browser/app_mode/app_mode_utils.h"
15 #include "chrome/browser/lifetime/application_lifetime.h" 16 #include "chrome/browser/lifetime/application_lifetime.h"
16 #include "chrome/browser/profiles/profile_manager.h" 17 #include "chrome/browser/profiles/profile_manager.h"
17 #include "chrome/browser/profiles/profiles_state.h" 18 #include "chrome/browser/profiles/profiles_state.h"
18 #include "chrome/browser/ui/app_list/app_list_view_delegate.h" 19 #include "chrome/browser/ui/app_list/app_list_view_delegate.h"
19 #include "chrome/browser/ui/ash/app_list/app_list_service_ash.h" 20 #include "chrome/browser/ui/ash/app_list/app_list_service_ash.h"
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 148
148 ash::ShelfDelegate* ChromeShellDelegate::CreateShelfDelegate( 149 ash::ShelfDelegate* ChromeShellDelegate::CreateShelfDelegate(
149 ash::ShelfModel* model) { 150 ash::ShelfModel* model) {
150 if (!shelf_delegate_) { 151 if (!shelf_delegate_) {
151 shelf_delegate_ = ChromeLauncherController::CreateInstance(NULL, model); 152 shelf_delegate_ = ChromeLauncherController::CreateInstance(NULL, model);
152 shelf_delegate_->Init(); 153 shelf_delegate_->Init();
153 } 154 }
154 return shelf_delegate_; 155 return shelf_delegate_;
155 } 156 }
156 157
158 ash::PointerWatcherDelegate*
159 ChromeShellDelegate::CreatePointerWatcherDelegate() {
160 return new ash::PointerWatcherDelegateAura();
161 }
162
157 ui::MenuModel* ChromeShellDelegate::CreateContextMenu( 163 ui::MenuModel* ChromeShellDelegate::CreateContextMenu(
158 ash::Shelf* shelf, 164 ash::Shelf* shelf,
159 const ash::ShelfItem* item) { 165 const ash::ShelfItem* item) {
160 DCHECK(shelf_delegate_); 166 DCHECK(shelf_delegate_);
161 // Don't show context menu for exclusive app runtime mode. 167 // Don't show context menu for exclusive app runtime mode.
162 if (chrome::IsRunningInAppMode()) 168 if (chrome::IsRunningInAppMode())
163 return nullptr; 169 return nullptr;
164 170
165 return LauncherContextMenu::Create(shelf_delegate_, item, shelf); 171 return LauncherContextMenu::Create(shelf_delegate_, item, shelf);
166 } 172 }
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
220 226
221 void ChromeShellDelegate::AddVirtualKeyboardStateObserver( 227 void ChromeShellDelegate::AddVirtualKeyboardStateObserver(
222 ash::VirtualKeyboardStateObserver* observer) { 228 ash::VirtualKeyboardStateObserver* observer) {
223 keyboard_state_observer_list_.AddObserver(observer); 229 keyboard_state_observer_list_.AddObserver(observer);
224 } 230 }
225 231
226 void ChromeShellDelegate::RemoveVirtualKeyboardStateObserver( 232 void ChromeShellDelegate::RemoveVirtualKeyboardStateObserver(
227 ash::VirtualKeyboardStateObserver* observer) { 233 ash::VirtualKeyboardStateObserver* observer) {
228 keyboard_state_observer_list_.RemoveObserver(observer); 234 keyboard_state_observer_list_.RemoveObserver(observer);
229 } 235 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698