| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_IMMERSIVE_FULLSCREEN_CONTROLLER_H_ | 5 #ifndef ASH_WM_IMMERSIVE_FULLSCREEN_CONTROLLER_H_ |
| 6 #define ASH_WM_IMMERSIVE_FULLSCREEN_CONTROLLER_H_ | 6 #define ASH_WM_IMMERSIVE_FULLSCREEN_CONTROLLER_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 183 const gfx::Point& location_in_screen) const; | 183 const gfx::Point& location_in_screen) const; |
| 184 | 184 |
| 185 // True when |location| is "near" to the top container. When the top container | 185 // True when |location| is "near" to the top container. When the top container |
| 186 // is not closed "near" means within the displayed bounds or above it. When | 186 // is not closed "near" means within the displayed bounds or above it. When |
| 187 // the top container is closed "near" means either within the displayed | 187 // the top container is closed "near" means either within the displayed |
| 188 // bounds, above it, or within a few pixels below it. This allow the container | 188 // bounds, above it, or within a few pixels below it. This allow the container |
| 189 // to steal enough pixels to detect a swipe in and handles the case that there | 189 // to steal enough pixels to detect a swipe in and handles the case that there |
| 190 // is a bezel sensor above the top container. | 190 // is a bezel sensor above the top container. |
| 191 bool ShouldHandleGestureEvent(const gfx::Point& location) const; | 191 bool ShouldHandleGestureEvent(const gfx::Point& location) const; |
| 192 | 192 |
| 193 // Returns the display bounds of the screen |widget_| is on. |
| 194 gfx::Rect GetDisplayBoundsInScreen() const; |
| 195 |
| 193 // Not owned. | 196 // Not owned. |
| 194 WmImmersiveFullscreenControllerDelegate* delegate_; | 197 WmImmersiveFullscreenControllerDelegate* delegate_; |
| 195 views::View* top_container_; | 198 views::View* top_container_; |
| 196 views::Widget* widget_; | 199 views::Widget* widget_; |
| 197 // The WmWindow for |widget_|. | 200 // The WmWindow for |widget_|. |
| 198 WmWindow* widget_window_ = nullptr; | 201 WmWindow* widget_window_ = nullptr; |
| 199 | 202 |
| 200 // True if the observers have been enabled. | 203 // True if the observers have been enabled. |
| 201 bool observers_enabled_; | 204 bool observers_enabled_; |
| 202 | 205 |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 235 std::unique_ptr<ImmersiveGestureHandler> immersive_gesture_handler_; | 238 std::unique_ptr<ImmersiveGestureHandler> immersive_gesture_handler_; |
| 236 | 239 |
| 237 base::WeakPtrFactory<ImmersiveFullscreenController> weak_ptr_factory_; | 240 base::WeakPtrFactory<ImmersiveFullscreenController> weak_ptr_factory_; |
| 238 | 241 |
| 239 DISALLOW_COPY_AND_ASSIGN(ImmersiveFullscreenController); | 242 DISALLOW_COPY_AND_ASSIGN(ImmersiveFullscreenController); |
| 240 }; | 243 }; |
| 241 | 244 |
| 242 } // namespace ash | 245 } // namespace ash |
| 243 | 246 |
| 244 #endif // ASH_WM_IMMERSIVE_FULLSCREEN_CONTROLLER_H_ | 247 #endif // ASH_WM_IMMERSIVE_FULLSCREEN_CONTROLLER_H_ |
| OLD | NEW |