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_WINDOW_STATE_H_ | 5 #ifndef ASH_WM_WINDOW_STATE_H_ |
6 #define ASH_WM_WINDOW_STATE_H_ | 6 #define ASH_WM_WINDOW_STATE_H_ |
7 | 7 |
8 #include "ash/ash_export.h" | 8 #include "ash/ash_export.h" |
9 #include "ash/wm/drag_details.h" | 9 #include "ash/wm/drag_details.h" |
10 #include "ash/wm/wm_types.h" | 10 #include "ash/wm/wm_types.h" |
11 #include "base/basictypes.h" | 11 #include "base/basictypes.h" |
12 #include "base/gtest_prod_util.h" | 12 #include "base/gtest_prod_util.h" |
13 #include "base/memory/scoped_ptr.h" | 13 #include "base/memory/scoped_ptr.h" |
14 #include "base/observer_list.h" | 14 #include "base/observer_list.h" |
15 #include "ui/aura/window_observer.h" | 15 #include "ui/aura/window_observer.h" |
16 #include "ui/base/ui_base_types.h" | 16 #include "ui/base/ui_base_types.h" |
17 | 17 |
18 namespace aura { | 18 namespace aura { |
19 class Window; | 19 class Window; |
20 } | 20 } |
21 | 21 |
22 namespace gfx { | 22 namespace gfx { |
23 class Rect; | 23 class Rect; |
24 } | 24 } |
25 | 25 |
26 namespace ash { | 26 namespace ash { |
27 class WorkspaceLayoutManager; | 27 class WorkspaceLayoutManager; |
| 28 class LockWindowState; |
28 class MaximizeModeWindowState; | 29 class MaximizeModeWindowState; |
29 | 30 |
30 namespace wm { | 31 namespace wm { |
31 class WindowStateDelegate; | 32 class WindowStateDelegate; |
32 class WindowStateObserver; | 33 class WindowStateObserver; |
33 class WMEvent; | 34 class WMEvent; |
34 | 35 |
35 // WindowState manages and defines ash specific window state and | 36 // WindowState manages and defines ash specific window state and |
36 // behavior. Ash specific per-window state (such as ones that controls | 37 // behavior. Ash specific per-window state (such as ones that controls |
37 // window manager behavior) and ash specific window behavior (such as | 38 // window manager behavior) and ash specific window behavior (such as |
(...skipping 247 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
285 const DragDetails* drag_details() const { return drag_details_.get(); } | 286 const DragDetails* drag_details() const { return drag_details_.get(); } |
286 DragDetails* drag_details() { return drag_details_.get(); } | 287 DragDetails* drag_details() { return drag_details_.get(); } |
287 | 288 |
288 // aura::WindowObserver overrides: | 289 // aura::WindowObserver overrides: |
289 virtual void OnWindowPropertyChanged(aura::Window* window, | 290 virtual void OnWindowPropertyChanged(aura::Window* window, |
290 const void* key, | 291 const void* key, |
291 intptr_t old) OVERRIDE; | 292 intptr_t old) OVERRIDE; |
292 | 293 |
293 private: | 294 private: |
294 friend class DefaultState; | 295 friend class DefaultState; |
| 296 friend class ash::LockWindowState; |
295 friend class ash::MaximizeModeWindowState; | 297 friend class ash::MaximizeModeWindowState; |
296 FRIEND_TEST_ALL_PREFIXES(WindowAnimationsTest, CrossFadeToBounds); | 298 FRIEND_TEST_ALL_PREFIXES(WindowAnimationsTest, CrossFadeToBounds); |
297 | 299 |
298 WindowStateDelegate* delegate() { return delegate_.get(); } | 300 WindowStateDelegate* delegate() { return delegate_.get(); } |
299 | 301 |
300 // Returns the window's current show state. | 302 // Returns the window's current show state. |
301 ui::WindowShowState GetShowState() const; | 303 ui::WindowShowState GetShowState() const; |
302 | 304 |
303 // Sets the window's bounds in screen coordinates. | 305 // Sets the window's bounds in screen coordinates. |
304 void SetBoundsInScreen(const gfx::Rect& bounds_in_screen); | 306 void SetBoundsInScreen(const gfx::Rect& bounds_in_screen); |
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
371 ASH_EXPORT WindowState* GetWindowState(aura::Window* window); | 373 ASH_EXPORT WindowState* GetWindowState(aura::Window* window); |
372 | 374 |
373 // const version of GetWindowState. | 375 // const version of GetWindowState. |
374 ASH_EXPORT const WindowState* | 376 ASH_EXPORT const WindowState* |
375 GetWindowState(const aura::Window* window); | 377 GetWindowState(const aura::Window* window); |
376 | 378 |
377 } // namespace wm | 379 } // namespace wm |
378 } // namespace ash | 380 } // namespace ash |
379 | 381 |
380 #endif // ASH_WM_WINDOW_STATE_H_ | 382 #endif // ASH_WM_WINDOW_STATE_H_ |
OLD | NEW |