| 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_UTIL_H_ | 5 #ifndef ASH_WM_WINDOW_UTIL_H_ |
| 6 #define ASH_WM_WINDOW_UTIL_H_ | 6 #define ASH_WM_WINDOW_UTIL_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include "ash/ash_export.h" | 10 #include "ash/ash_export.h" |
| (...skipping 11 matching lines...) Expand all Loading... |
| 22 namespace ash { | 22 namespace ash { |
| 23 | 23 |
| 24 namespace wm { | 24 namespace wm { |
| 25 | 25 |
| 26 // Utility functions for window activation. | 26 // Utility functions for window activation. |
| 27 ASH_EXPORT void ActivateWindow(aura::Window* window); | 27 ASH_EXPORT void ActivateWindow(aura::Window* window); |
| 28 ASH_EXPORT void DeactivateWindow(aura::Window* window); | 28 ASH_EXPORT void DeactivateWindow(aura::Window* window); |
| 29 ASH_EXPORT bool IsActiveWindow(aura::Window* window); | 29 ASH_EXPORT bool IsActiveWindow(aura::Window* window); |
| 30 ASH_EXPORT aura::Window* GetActiveWindow(); | 30 ASH_EXPORT aura::Window* GetActiveWindow(); |
| 31 ASH_EXPORT bool CanActivateWindow(aura::Window* window); | 31 ASH_EXPORT bool CanActivateWindow(aura::Window* window); |
| 32 ASH_EXPORT aura::Window* GetFocusedWindow(); |
| 32 | 33 |
| 33 // Retrieves the activatable window for |window|. If |window| is activatable, | 34 // Retrieves the activatable window for |window|. If |window| is activatable, |
| 34 // this will just return it, otherwise it will climb the parent/transient parent | 35 // this will just return it, otherwise it will climb the parent/transient parent |
| 35 // chain looking for a window that is activatable, per the ActivationController. | 36 // chain looking for a window that is activatable, per the ActivationController. |
| 36 // If you're looking for a function to get the activatable "top level" window, | 37 // If you're looking for a function to get the activatable "top level" window, |
| 37 // this is probably what you're looking for. | 38 // this is probably what you're looking for. |
| 38 ASH_EXPORT aura::Window* GetActivatableWindow(aura::Window* window); | 39 ASH_EXPORT aura::Window* GetActivatableWindow(aura::Window* window); |
| 39 | 40 |
| 41 // Returns the window with capture, null if no window currently has capture. |
| 42 ASH_EXPORT aura::Window* GetCaptureWindow(); |
| 43 |
| 40 // Returns true if |window|'s location can be controlled by the user. | 44 // Returns true if |window|'s location can be controlled by the user. |
| 41 ASH_EXPORT bool IsWindowUserPositionable(aura::Window* window); | 45 ASH_EXPORT bool IsWindowUserPositionable(aura::Window* window); |
| 42 | 46 |
| 43 // Pins the window on top of other windows. | 47 // Pins the window on top of other windows. |
| 44 ASH_EXPORT void PinWindow(aura::Window* window, bool trusted); | 48 ASH_EXPORT void PinWindow(aura::Window* window, bool trusted); |
| 45 | 49 |
| 46 // Indicates that the window should autohide the shelf when it is the active | 50 // Indicates that the window should autohide the shelf when it is the active |
| 47 // window. | 51 // window. |
| 48 ASH_EXPORT void SetAutoHideShelf(aura::Window* window, bool autohide); | 52 ASH_EXPORT void SetAutoHideShelf(aura::Window* window, bool autohide); |
| 49 | 53 |
| (...skipping 11 matching lines...) Expand all Loading... |
| 61 | 65 |
| 62 // Mark the container window so that InstallSnapLayoutManagerToContainers | 66 // Mark the container window so that InstallSnapLayoutManagerToContainers |
| 63 // installs the SnapToPixelLayoutManager. | 67 // installs the SnapToPixelLayoutManager. |
| 64 ASH_EXPORT void SetSnapsChildrenToPhysicalPixelBoundary( | 68 ASH_EXPORT void SetSnapsChildrenToPhysicalPixelBoundary( |
| 65 aura::Window* container); | 69 aura::Window* container); |
| 66 | 70 |
| 67 } // namespace wm | 71 } // namespace wm |
| 68 } // namespace ash | 72 } // namespace ash |
| 69 | 73 |
| 70 #endif // ASH_WM_WINDOW_UTIL_H_ | 74 #endif // ASH_WM_WINDOW_UTIL_H_ |
| OLD | NEW |