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

Side by Side Diff: ash/common/wm_shell.h

Issue 2271393002: Wires up drags to pointer watcher adapter. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@lkgr
Patch Set: Fixed patch set 2 errors. Created 4 years, 3 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #ifndef ASH_COMMON_WM_SHELL_H_ 5 #ifndef ASH_COMMON_WM_SHELL_H_
6 #define ASH_COMMON_WM_SHELL_H_ 6 #define ASH_COMMON_WM_SHELL_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 11 matching lines...) Expand all
22 class Display; 22 class Display;
23 } 23 }
24 24
25 namespace gfx { 25 namespace gfx {
26 class Insets; 26 class Insets;
27 class Point; 27 class Point;
28 } 28 }
29 29
30 namespace views { 30 namespace views {
31 class PointerWatcher; 31 class PointerWatcher;
32 enum class PointerWatcherEventTypes;
32 } 33 }
33 34
34 namespace ash { 35 namespace ash {
35 36
36 class AcceleratorController; 37 class AcceleratorController;
37 class AccessibilityDelegate; 38 class AccessibilityDelegate;
38 class BrightnessControlDelegate; 39 class BrightnessControlDelegate;
39 class DisplayInfo; 40 class DisplayInfo;
40 class FocusCycler; 41 class FocusCycler;
41 class ImmersiveContextAsh; 42 class ImmersiveContextAsh;
(...skipping 276 matching lines...) Expand 10 before | Expand all | Expand 10 after
318 virtual void AddActivationObserver(WmActivationObserver* observer) = 0; 319 virtual void AddActivationObserver(WmActivationObserver* observer) = 0;
319 virtual void RemoveActivationObserver(WmActivationObserver* observer) = 0; 320 virtual void RemoveActivationObserver(WmActivationObserver* observer) = 0;
320 321
321 virtual void AddDisplayObserver(WmDisplayObserver* observer) = 0; 322 virtual void AddDisplayObserver(WmDisplayObserver* observer) = 0;
322 virtual void RemoveDisplayObserver(WmDisplayObserver* observer) = 0; 323 virtual void RemoveDisplayObserver(WmDisplayObserver* observer) = 0;
323 324
324 void AddShellObserver(ShellObserver* observer); 325 void AddShellObserver(ShellObserver* observer);
325 void RemoveShellObserver(ShellObserver* observer); 326 void RemoveShellObserver(ShellObserver* observer);
326 327
327 // If |wants_moves| is true PointerWatcher::OnPointerEventObserved() is 328 // If |wants_moves| is true PointerWatcher::OnPointerEventObserved() is
328 // called for pointer move events. Enabling pointer moves may incur a 329 // called for pointer move events. If |wants_drags| is true
sky 2016/08/26 19:58:57 Update comment.
sammiequon 2016/08/26 21:48:04 Done.
329 // performance hit and should be avoided if possible. 330 // PointerWatcher::OnPointerEventObserved() is called for pointer drag events.
331 // Enabling pointer moves or drags may incur a performance hit and should be
332 // avoided if possible.
330 virtual void AddPointerWatcher(views::PointerWatcher* watcher, 333 virtual void AddPointerWatcher(views::PointerWatcher* watcher,
331 bool wants_moves) = 0; 334 views::PointerWatcherEventTypes events) = 0;
332 virtual void RemovePointerWatcher(views::PointerWatcher* watcher) = 0; 335 virtual void RemovePointerWatcher(views::PointerWatcher* watcher) = 0;
333 336
334 // TODO: Move these back to LockStateController when that has been moved. 337 // TODO: Move these back to LockStateController when that has been moved.
335 void OnLockStateEvent(LockStateObserver::EventType event); 338 void OnLockStateEvent(LockStateObserver::EventType event);
336 void AddLockStateObserver(LockStateObserver* observer); 339 void AddLockStateObserver(LockStateObserver* observer);
337 void RemoveLockStateObserver(LockStateObserver* observer); 340 void RemoveLockStateObserver(LockStateObserver* observer);
338 341
339 void SetShelfDelegateForTesting(std::unique_ptr<ShelfDelegate> test_delegate); 342 void SetShelfDelegateForTesting(std::unique_ptr<ShelfDelegate> test_delegate);
340 void SetPaletteDelegateForTesting( 343 void SetPaletteDelegateForTesting(
341 std::unique_ptr<PaletteDelegate> palette_delegate); 344 std::unique_ptr<PaletteDelegate> palette_delegate);
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
424 bool simulate_modal_window_open_for_testing_ = false; 427 bool simulate_modal_window_open_for_testing_ = false;
425 428
426 #if defined(OS_CHROMEOS) 429 #if defined(OS_CHROMEOS)
427 std::unique_ptr<LogoutConfirmationController> logout_confirmation_controller_; 430 std::unique_ptr<LogoutConfirmationController> logout_confirmation_controller_;
428 #endif 431 #endif
429 }; 432 };
430 433
431 } // namespace ash 434 } // namespace ash
432 435
433 #endif // ASH_COMMON_WM_SHELL_H_ 436 #endif // ASH_COMMON_WM_SHELL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698