| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 module ui.mojom; | 5 module ui.mojom; |
| 6 | 6 |
| 7 import "services/ui/public/interfaces/cursor.mojom"; | 7 import "services/ui/public/interfaces/cursor.mojom"; |
| 8 import "services/ui/public/interfaces/display/display.mojom"; | 8 import "services/ui/public/interfaces/display/display.mojom"; |
| 9 import "services/ui/public/interfaces/event_matcher.mojom"; | 9 import "services/ui/public/interfaces/event_matcher.mojom"; |
| 10 import "services/ui/public/interfaces/window_manager_constants.mojom"; | 10 import "services/ui/public/interfaces/window_manager_constants.mojom"; |
| 11 import "services/ui/public/interfaces/window_tree_constants.mojom"; | 11 import "services/ui/public/interfaces/window_tree_constants.mojom"; |
| 12 import "ui/events/mojo/event.mojom"; | 12 import "ui/events/mojo/event.mojom"; |
| 13 import "ui/gfx/geometry/mojo/geometry.mojom"; | 13 import "ui/gfx/geometry/mojo/geometry.mojom"; |
| 14 | 14 |
| 15 // WindowManager is used when a WindowTreeClient attempts to modify | 15 // WindowManager is used when a WindowTreeClient attempts to modify |
| 16 // a property of the embed root. When this happens WindowTree calls the | 16 // a property of the embed root. When this happens WindowTree calls the |
| 17 // appropriate function on WindowManager. For example, if a | 17 // appropriate function on WindowManager. For example, if a |
| 18 // WindowTreeClient calls SetWindowBounds() on its embed root, WindowTree | 18 // WindowTreeClient calls SetWindowBounds() on its embed root, WindowTree |
| 19 // calls WmSetBounds(). WindowManager can then decide if it wants to | 19 // calls WmSetBounds(). WindowManager can then decide if it wants to |
| 20 // change the bounds or not. | 20 // change the bounds or not. |
| 21 // | 21 // |
| 22 // This interface is only used as an associated interface and is associated | 22 // This interface is only used as an associated interface and is associated |
| 23 // with WindowTreeClient, further WindowTree requests this interface from | 23 // with WindowTreeClient, further WindowTree requests this interface from |
| 24 // WindowTreeClient supplied at the time the WindowTreeHost is created. | 24 // WindowTreeClient supplied at the time the WindowTreeHost is created. |
| 25 interface WindowManager { | 25 interface WindowManager { |
| 26 // Whether the window is always on top. Type: bool. | 26 // Whether the window is always on top. Type: bool. |
| 27 const string kAlwaysOnTop_Property = "prop:always_on_top"; | 27 const string kAlwaysOnTop_Property = "prop:always_on_top"; |
| 28 // The application icon; typically larger for shelf icons, etc. Type: SkBitmap |
| 29 const string kAppIcon_Property = "prop:app-icon"; |
| 28 // Disables the window manager from handling immersive fullscreen for the | 30 // Disables the window manager from handling immersive fullscreen for the |
| 29 // window. This is typically done if the client wants to handle immersive | 31 // window. This is typically done if the client wants to handle immersive |
| 30 // themselves. Type: bool. | 32 // themselves. Type: bool. |
| 31 const string kDisableImmersive_Property = "prop:disable_immersive"; | 33 const string kDisableImmersive_Property = "prop:disable_immersive"; |
| 32 // Used to explicitly control whether a window appears in the most recently | 34 // Used to explicitly control whether a window appears in the most recently |
| 33 // used list of windows. Type: bool. | 35 // used list of windows. Type: bool. |
| 34 const string kExcludeFromMru_Property = "prop:exclude_from_mru"; | 36 const string kExcludeFromMru_Property = "prop:exclude_from_mru"; |
| 35 // Initial bounds to create the window at. If empty the WindowManager decides | 37 // Initial bounds to create the window at. If empty the WindowManager decides |
| 36 // the initial bounds. | 38 // the initial bounds. |
| 37 const string kInitialBounds_Property = "prop:initial_bounds"; | 39 const string kInitialBounds_Property = "prop:initial_bounds"; |
| (...skipping 22 matching lines...) Expand all Loading... |
| 60 const string kShadowStyle_Property = "prop:shadow-style"; | 62 const string kShadowStyle_Property = "prop:shadow-style"; |
| 61 // The ID of the shelf item corresponding to this window. Type: int | 63 // The ID of the shelf item corresponding to this window. Type: int |
| 62 const string kShelfId_Property = "prop:shelf-id"; | 64 const string kShelfId_Property = "prop:shelf-id"; |
| 63 // The type of item to be shown on the shelf for this window. Type: int | 65 // The type of item to be shown on the shelf for this window. Type: int |
| 64 // A few ash::ShelfItemType values are supported; TYPE_UNKNOWN means no item. | 66 // A few ash::ShelfItemType values are supported; TYPE_UNKNOWN means no item. |
| 65 const string kShelfItemType_Property = "prop:shelf-item-type"; | 67 const string kShelfItemType_Property = "prop:shelf-item-type"; |
| 66 // The window's show state. Type: ShowState. | 68 // The window's show state. Type: ShowState. |
| 67 const string kShowState_Property = "prop:show-state"; | 69 const string kShowState_Property = "prop:show-state"; |
| 68 // The window bounds as set by user input. Type: gfx::Rect. | 70 // The window bounds as set by user input. Type: gfx::Rect. |
| 69 const string kUserSetBounds_Property = "prop:user-set-bounds"; | 71 const string kUserSetBounds_Property = "prop:user-set-bounds"; |
| 70 // The window's app icon. Type: SkBitmap | 72 // The window icon; typically 16x16 for titlebars. Type: SkBitmap |
| 71 const string kWindowAppIcon_Property = "prop:window-app-icon"; | 73 const string kWindowIcon_Property = "prop:window-icon"; |
| 72 // The window type. Type: mojom::WindowType | 74 // The window type. Type: mojom::WindowType |
| 73 const string kWindowType_Property = "prop:window-type"; | 75 const string kWindowType_Property = "prop:window-type"; |
| 74 // The window's title. Type: mojom::String | 76 // The window's title. Type: mojom::String |
| 75 const string kWindowTitle_Property = "prop:window-title"; | 77 const string kWindowTitle_Property = "prop:window-title"; |
| 76 // A flag controlling the window's presence on the mash shelf. Type: bool | 78 // A flag controlling the window's presence on the mash shelf. Type: bool |
| 77 const string kWindowIgnoredByShelf_Property = "prop:window-ignored-by-shelf"; | 79 const string kWindowIgnoredByShelf_Property = "prop:window-ignored-by-shelf"; |
| 78 // The application ID (eg. 'mojo:foo'). Type: mojom::String | 80 // The application ID (eg. 'mojo:foo'). Type: mojom::String |
| 79 const string kAppID_Property = "prop:app-id"; | 81 const string kAppID_Property = "prop:app-id"; |
| 80 // Specifies that the system default caption and icon should not be rendered, | 82 // Specifies that the system default caption and icon should not be rendered, |
| 81 // and the client area should be equivalent to the window area. Type: bool | 83 // and the client area should be equivalent to the window area. Type: bool |
| (...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 180 WmSetNonClientCursor(uint32 window_id, Cursor cursor_id); | 182 WmSetNonClientCursor(uint32 window_id, Cursor cursor_id); |
| 181 | 183 |
| 182 // Response from WmCreateTopLevelWindow() informing the client of the id for | 184 // Response from WmCreateTopLevelWindow() informing the client of the id for |
| 183 // the new window. | 185 // the new window. |
| 184 OnWmCreatedTopLevelWindow(uint32 change_id, uint32 window_id); | 186 OnWmCreatedTopLevelWindow(uint32 change_id, uint32 window_id); |
| 185 | 187 |
| 186 // See description in WindowManager::OnAccelerator(). |ack_id| is the value | 188 // See description in WindowManager::OnAccelerator(). |ack_id| is the value |
| 187 // that was passed to OnAccelerator(). | 189 // that was passed to OnAccelerator(). |
| 188 OnAcceleratorAck(uint32 ack_id, EventResult event_result); | 190 OnAcceleratorAck(uint32 ack_id, EventResult event_result); |
| 189 }; | 191 }; |
| OLD | NEW |