OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 CHROME_BROWSER_UI_VIEWS_FRAME_IMMERSIVE_MODE_CONTROLLER_ASH_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_FRAME_IMMERSIVE_MODE_CONTROLLER_ASH_H_ |
6 #define CHROME_BROWSER_UI_VIEWS_FRAME_IMMERSIVE_MODE_CONTROLLER_ASH_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_FRAME_IMMERSIVE_MODE_CONTROLLER_ASH_H_ |
7 | 7 |
8 #include "chrome/browser/ui/views/frame/immersive_mode_controller.h" | 8 #include "chrome/browser/ui/views/frame/immersive_mode_controller.h" |
9 | 9 |
10 #include "base/timer.h" | 10 #include "base/timer.h" |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
48 // These methods are used to increment and decrement |revealed_lock_count_|. | 48 // These methods are used to increment and decrement |revealed_lock_count_|. |
49 // If immersive mode is enabled, a transition from 1 to 0 in | 49 // If immersive mode is enabled, a transition from 1 to 0 in |
50 // |revealed_lock_count_| closes the top-of-window views and a transition | 50 // |revealed_lock_count_| closes the top-of-window views and a transition |
51 // from 0 to 1 in |revealed_lock_count_| reveals the top-of-window views. | 51 // from 0 to 1 in |revealed_lock_count_| reveals the top-of-window views. |
52 void LockRevealedState(AnimateReveal animate_reveal); | 52 void LockRevealedState(AnimateReveal animate_reveal); |
53 void UnlockRevealedState(); | 53 void UnlockRevealedState(); |
54 | 54 |
55 // Shows the reveal view without any animations if immersive mode is enabled. | 55 // Shows the reveal view without any animations if immersive mode is enabled. |
56 void MaybeRevealWithoutAnimation(); | 56 void MaybeRevealWithoutAnimation(); |
57 | 57 |
| 58 // Call Add/RemovePreTargerHandler since the RootWindow or WindowObservers |
| 59 // enabled state has changed. |
| 60 void SetPreTargetHandler(); |
| 61 |
58 // ImmersiveModeController overrides: | 62 // ImmersiveModeController overrides: |
59 virtual void Init(Delegate* delegate, | 63 virtual void Init(Delegate* delegate, |
60 views::Widget* widget, | 64 views::Widget* widget, |
61 TopContainerView* top_container) OVERRIDE; | 65 TopContainerView* top_container) OVERRIDE; |
62 virtual void SetEnabled(bool enabled) OVERRIDE; | 66 virtual void SetEnabled(bool enabled) OVERRIDE; |
63 virtual bool IsEnabled() const OVERRIDE; | 67 virtual bool IsEnabled() const OVERRIDE; |
64 virtual bool ShouldHideTabIndicators() const OVERRIDE; | 68 virtual bool ShouldHideTabIndicators() const OVERRIDE; |
65 virtual bool ShouldHideTopViews() const OVERRIDE; | 69 virtual bool ShouldHideTopViews() const OVERRIDE; |
66 virtual bool IsRevealed() const OVERRIDE; | 70 virtual bool IsRevealed() const OVERRIDE; |
67 virtual void MaybeStackViewAtTop() OVERRIDE; | 71 virtual void MaybeStackViewAtTop() OVERRIDE; |
(...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
255 base::WeakPtrFactory<ImmersiveModeControllerAsh> weak_ptr_factory_; | 259 base::WeakPtrFactory<ImmersiveModeControllerAsh> weak_ptr_factory_; |
256 | 260 |
257 // Tracks if the controller has seen a ET_GESTURE_SCROLL_BEGIN, without the | 261 // Tracks if the controller has seen a ET_GESTURE_SCROLL_BEGIN, without the |
258 // following events. | 262 // following events. |
259 bool gesture_begun_; | 263 bool gesture_begun_; |
260 | 264 |
261 DISALLOW_COPY_AND_ASSIGN(ImmersiveModeControllerAsh); | 265 DISALLOW_COPY_AND_ASSIGN(ImmersiveModeControllerAsh); |
262 }; | 266 }; |
263 | 267 |
264 #endif // CHROME_BROWSER_UI_VIEWS_FRAME_IMMERSIVE_MODE_CONTROLLER_ASH_H_ | 268 #endif // CHROME_BROWSER_UI_VIEWS_FRAME_IMMERSIVE_MODE_CONTROLLER_ASH_H_ |
OLD | NEW |