OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 SERVICES_UI_WS_ACCESS_POLICY_H_ | 5 #ifndef SERVICES_UI_WS_ACCESS_POLICY_H_ |
6 #define SERVICES_UI_WS_ACCESS_POLICY_H_ | 6 #define SERVICES_UI_WS_ACCESS_POLICY_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include "services/ui/public/interfaces/mus_constants.mojom.h" | 10 #include "services/ui/public/interfaces/mus_constants.mojom.h" |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
51 virtual bool CanChangeWindowOpacity(const ServerWindow* window) const = 0; | 51 virtual bool CanChangeWindowOpacity(const ServerWindow* window) const = 0; |
52 virtual bool CanSetWindowSurface(const ServerWindow* window, | 52 virtual bool CanSetWindowSurface(const ServerWindow* window, |
53 mojom::SurfaceType surface_type) const = 0; | 53 mojom::SurfaceType surface_type) const = 0; |
54 virtual bool CanSetWindowBounds(const ServerWindow* window) const = 0; | 54 virtual bool CanSetWindowBounds(const ServerWindow* window) const = 0; |
55 virtual bool CanSetWindowProperties(const ServerWindow* window) const = 0; | 55 virtual bool CanSetWindowProperties(const ServerWindow* window) const = 0; |
56 virtual bool CanSetWindowTextInputState(const ServerWindow* window) const = 0; | 56 virtual bool CanSetWindowTextInputState(const ServerWindow* window) const = 0; |
57 virtual bool CanSetCapture(const ServerWindow* window) const = 0; | 57 virtual bool CanSetCapture(const ServerWindow* window) const = 0; |
58 virtual bool CanSetFocus(const ServerWindow* window) const = 0; | 58 virtual bool CanSetFocus(const ServerWindow* window) const = 0; |
59 virtual bool CanSetClientArea(const ServerWindow* window) const = 0; | 59 virtual bool CanSetClientArea(const ServerWindow* window) const = 0; |
60 virtual bool CanSetHitTestMask(const ServerWindow* window) const = 0; | 60 virtual bool CanSetHitTestMask(const ServerWindow* window) const = 0; |
| 61 virtual bool CanSetAcceptDrops(const ServerWindow* window) const = 0; |
61 virtual bool CanSetAcceptEvents(const ServerWindow* window) const = 0; | 62 virtual bool CanSetAcceptEvents(const ServerWindow* window) const = 0; |
62 // Used for all client controllable cursor properties; which cursor should be | 63 // Used for all client controllable cursor properties; which cursor should be |
63 // displayed, visibility, locking, etc. | 64 // displayed, visibility, locking, etc. |
64 virtual bool CanSetCursorProperties(const ServerWindow* window) const = 0; | 65 virtual bool CanSetCursorProperties(const ServerWindow* window) const = 0; |
| 66 virtual bool CanInitiateDragLoop(const ServerWindow* window) const = 0; |
65 virtual bool CanInitiateMoveLoop(const ServerWindow* window) const = 0; | 67 virtual bool CanInitiateMoveLoop(const ServerWindow* window) const = 0; |
66 | 68 |
67 // Returns whether the client should notify on a hierarchy change. | 69 // Returns whether the client should notify on a hierarchy change. |
68 // |new_parent| and |old_parent| are initially set to the new and old parents | 70 // |new_parent| and |old_parent| are initially set to the new and old parents |
69 // but may be altered so that the client only sees a certain set of windows. | 71 // but may be altered so that the client only sees a certain set of windows. |
70 virtual bool ShouldNotifyOnHierarchyChange( | 72 virtual bool ShouldNotifyOnHierarchyChange( |
71 const ServerWindow* window, | 73 const ServerWindow* window, |
72 const ServerWindow** new_parent, | 74 const ServerWindow** new_parent, |
73 const ServerWindow** old_parent) const = 0; | 75 const ServerWindow** old_parent) const = 0; |
74 virtual bool CanSetWindowManager() const = 0; | 76 virtual bool CanSetWindowManager() const = 0; |
75 | 77 |
76 // Returns the window to supply to the client when focus changes to |focused|. | 78 // Returns the window to supply to the client when focus changes to |focused|. |
77 virtual const ServerWindow* GetWindowForFocusChange( | 79 virtual const ServerWindow* GetWindowForFocusChange( |
78 const ServerWindow* focused) = 0; | 80 const ServerWindow* focused) = 0; |
79 | 81 |
80 virtual bool IsValidIdForNewWindow(const ClientWindowId& id) const = 0; | 82 virtual bool IsValidIdForNewWindow(const ClientWindowId& id) const = 0; |
81 }; | 83 }; |
82 | 84 |
83 } // namespace ws | 85 } // namespace ws |
84 } // namespace ui | 86 } // namespace ui |
85 | 87 |
86 #endif // SERVICES_UI_WS_ACCESS_POLICY_H_ | 88 #endif // SERVICES_UI_WS_ACCESS_POLICY_H_ |
OLD | NEW |