OLD | NEW |
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_IMMERSIVE_WM_IMMERSIVE_FULLSCREEN_CONTROLLER_DELEGATE_H_ | 5 #ifndef ASH_SHARED_IMMERSIVE_FULLSCREEN_CONTROLLER_DELEGATE_H_ |
6 #define ASH_COMMON_WM_IMMERSIVE_WM_IMMERSIVE_FULLSCREEN_CONTROLLER_DELEGATE_H_ | 6 #define ASH_SHARED_IMMERSIVE_FULLSCREEN_CONTROLLER_DELEGATE_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "ash/ash_export.h" | 10 #include "ash/ash_export.h" |
11 | 11 |
12 namespace gfx { | 12 namespace gfx { |
13 class Rect; | 13 class Rect; |
14 } | 14 } |
15 | 15 |
16 namespace ash { | 16 namespace ash { |
17 | 17 |
18 class ASH_EXPORT WmImmersiveFullscreenControllerDelegate { | 18 class ASH_EXPORT ImmersiveFullscreenControllerDelegate { |
19 public: | 19 public: |
20 // Called when a reveal of the top-of-window views starts. | 20 // Called when a reveal of the top-of-window views starts. |
21 virtual void OnImmersiveRevealStarted() = 0; | 21 virtual void OnImmersiveRevealStarted() = 0; |
22 | 22 |
23 // Called when the top-of-window views have finished closing. This call | 23 // Called when the top-of-window views have finished closing. This call |
24 // implies a visible fraction of 0. SetVisibleFraction(0) may not be called | 24 // implies a visible fraction of 0. SetVisibleFraction(0) may not be called |
25 // prior to OnImmersiveRevealEnded(). | 25 // prior to OnImmersiveRevealEnded(). |
26 virtual void OnImmersiveRevealEnded() = 0; | 26 virtual void OnImmersiveRevealEnded() = 0; |
27 | 27 |
28 // Called as a result of disabling immersive fullscreen via SetEnabled(). | 28 // Called as a result of disabling immersive fullscreen via SetEnabled(). |
29 virtual void OnImmersiveFullscreenExited() = 0; | 29 virtual void OnImmersiveFullscreenExited() = 0; |
30 | 30 |
31 // Called to update the fraction of the top-of-window views height which is | 31 // Called to update the fraction of the top-of-window views height which is |
32 // visible. | 32 // visible. |
33 virtual void SetVisibleFraction(double visible_fraction) = 0; | 33 virtual void SetVisibleFraction(double visible_fraction) = 0; |
34 | 34 |
35 // Returns a list of rects whose union makes up the top-of-window views. | 35 // Returns a list of rects whose union makes up the top-of-window views. |
36 // The returned list is used for hittesting when the top-of-window views | 36 // The returned list is used for hittesting when the top-of-window views |
37 // are revealed. GetVisibleBoundsInScreen() must return a valid value when | 37 // are revealed. GetVisibleBoundsInScreen() must return a valid value when |
38 // not in immersive fullscreen for the sake of SetupForTest(). | 38 // not in immersive fullscreen for the sake of SetupForTest(). |
39 virtual std::vector<gfx::Rect> GetVisibleBoundsInScreen() const = 0; | 39 virtual std::vector<gfx::Rect> GetVisibleBoundsInScreen() const = 0; |
40 | 40 |
41 protected: | 41 protected: |
42 virtual ~WmImmersiveFullscreenControllerDelegate() {} | 42 virtual ~ImmersiveFullscreenControllerDelegate() {} |
43 }; | 43 }; |
44 | 44 |
45 } // namespace ash | 45 } // namespace ash |
46 | 46 |
47 #endif // ASH_COMMON_WM_IMMERSIVE_WM_IMMERSIVE_FULLSCREEN_CONTROLLER_DELEGATE_H
_ | 47 #endif // ASH_SHARED_IMMERSIVE_FULLSCREEN_CONTROLLER_DELEGATE_H_ |
OLD | NEW |