OLD | NEW |
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 #ifndef ASH_WM_WINDOW_MODALITY_CONTROLLER_H_ | 5 #ifndef ASH_WM_WINDOW_MODALITY_CONTROLLER_H_ |
6 #define ASH_WM_WINDOW_MODALITY_CONTROLLER_H_ | 6 #define ASH_WM_WINDOW_MODALITY_CONTROLLER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
11 #include "ash/ash_export.h" | 11 #include "ash/ash_export.h" |
12 #include "base/compiler_specific.h" | 12 #include "base/compiler_specific.h" |
13 #include "ui/aura/env_observer.h" | 13 #include "ui/aura/env_observer.h" |
14 #include "ui/aura/event_filter.h" | 14 #include "ui/aura/event_filter.h" |
15 #include "ui/aura/window_observer.h" | 15 #include "ui/aura/window_observer.h" |
16 | 16 |
| 17 namespace aura { |
| 18 class LocatedEvent; |
| 19 } |
| 20 |
17 namespace ash { | 21 namespace ash { |
18 | 22 |
19 namespace wm { | 23 namespace wm { |
20 // Returns the window-modal transient child of |window|, or NULL if |window| | 24 // Returns the window-modal transient child of |window|, or NULL if |window| |
21 // does not have any window-modal transient children. | 25 // does not have any window-modal transient children. |
22 ASH_EXPORT aura::Window* GetWindowModalTransient(aura::Window* window); | 26 ASH_EXPORT aura::Window* GetWindowModalTransient(aura::Window* window); |
23 } | 27 } |
24 | 28 |
25 namespace internal { | 29 namespace internal { |
26 | 30 |
(...skipping 20 matching lines...) Expand all Loading... |
47 | 51 |
48 // Overridden from aura::EnvObserver: | 52 // Overridden from aura::EnvObserver: |
49 virtual void OnWindowInitialized(aura::Window* window) OVERRIDE; | 53 virtual void OnWindowInitialized(aura::Window* window) OVERRIDE; |
50 | 54 |
51 // Overridden from aura::WindowObserver: | 55 // Overridden from aura::WindowObserver: |
52 virtual void OnWindowVisibilityChanged(aura::Window* window, | 56 virtual void OnWindowVisibilityChanged(aura::Window* window, |
53 bool visible) OVERRIDE; | 57 bool visible) OVERRIDE; |
54 virtual void OnWindowDestroyed(aura::Window* window) OVERRIDE; | 58 virtual void OnWindowDestroyed(aura::Window* window) OVERRIDE; |
55 | 59 |
56 private: | 60 private: |
| 61 // Processes a mouse/touch event, and returns true if the event should be |
| 62 // consumed. |
| 63 bool ProcessLocatedEvent(aura::Window* target, |
| 64 aura::LocatedEvent* event); |
| 65 |
57 std::vector<aura::Window*> windows_; | 66 std::vector<aura::Window*> windows_; |
58 | 67 |
59 DISALLOW_COPY_AND_ASSIGN(WindowModalityController); | 68 DISALLOW_COPY_AND_ASSIGN(WindowModalityController); |
60 }; | 69 }; |
61 | 70 |
62 } // namespace internal | 71 } // namespace internal |
63 } // namespace ash | 72 } // namespace ash |
64 | 73 |
65 #endif // ASH_WM_WINDOW_MODALITY_CONTROLLER_H_ | 74 #endif // ASH_WM_WINDOW_MODALITY_CONTROLLER_H_ |
OLD | NEW |