| 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 module ui.mojom; | 5 module ui.mojom; |
| 6 | 6 |
| 7 import "cc/ipc/surface_id.mojom"; | 7 import "cc/ipc/surface_id.mojom"; |
| 8 import "cc/ipc/surface_sequence.mojom"; | 8 import "cc/ipc/surface_sequence.mojom"; |
| 9 import "cc/ipc/mojo_compositor_frame_sink.mojom"; | 9 import "cc/ipc/mojo_compositor_frame_sink.mojom"; |
| 10 import "services/ui/public/interfaces/cursor.mojom"; | 10 import "services/ui/public/interfaces/cursor.mojom"; |
| (...skipping 429 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 440 | 440 |
| 441 // Called when the mouse cursor enters a window on this connection for the | 441 // Called when the mouse cursor enters a window on this connection for the |
| 442 // first time, providing a list of available mime types. We want to send this | 442 // first time, providing a list of available mime types. We want to send this |
| 443 // set of data only one time, so this isn't part of OnDragEnter(), which | 443 // set of data only one time, so this isn't part of OnDragEnter(), which |
| 444 // occurs every time the mouse enters a window. | 444 // occurs every time the mouse enters a window. |
| 445 OnDragDropStart(map<string, array<uint8>> drag_data); | 445 OnDragDropStart(map<string, array<uint8>> drag_data); |
| 446 | 446 |
| 447 // Called when the mouse cursor enters a window that has opted into | 447 // Called when the mouse cursor enters a window that has opted into |
| 448 // accepting drags through SetAcceptsDrags(), providing a list | 448 // accepting drags through SetAcceptsDrags(), providing a list |
| 449 // of available mime types. Returns a bitmask of the supported | 449 // of available mime types. Returns a bitmask of the supported |
| 450 // operations. | 450 // operations. |screen_position| is in screen coordinates. |
| 451 OnDragEnter(uint32 window, | 451 OnDragEnter(uint32 window, |
| 452 uint32 key_state, | 452 uint32 key_state, |
| 453 gfx.mojom.Point position, | 453 gfx.mojom.Point screen_position, |
| 454 uint32 effect_bitmask) => (uint32 supported_op_bitmask); | 454 uint32 effect_bitmask) => (uint32 supported_op_bitmask); |
| 455 | 455 |
| 456 // Called when the pointer moves over the window after the initial | 456 // Called when the pointer moves over the window after the initial |
| 457 // DragEnter. Returns a bitmask of the supported operations at this | 457 // DragEnter. Returns a bitmask of the supported operations at this |
| 458 // location. | 458 // location. |screen_position| is in screen coordinates. |
| 459 OnDragOver(uint32 window, | 459 OnDragOver(uint32 window, |
| 460 uint32 key_state, | 460 uint32 key_state, |
| 461 gfx.mojom.Point position, | 461 gfx.mojom.Point screen_position, |
| 462 uint32 effect_bitmask) => (uint32 supported_op_bitmask); | 462 uint32 effect_bitmask) => (uint32 supported_op_bitmask); |
| 463 | 463 |
| 464 // Called when the pointer leaves a window or if the drop is | 464 // Called when the pointer leaves a window or if the drop is |
| 465 // canceled. | 465 // canceled. |
| 466 OnDragLeave(uint32 window); | 466 OnDragLeave(uint32 window); |
| 467 | 467 |
| 468 // Called when the drop occurs on a window. Returns the action | 468 // Called when the drop occurs on a window. Returns the action |
| 469 // taken. | 469 // taken. |screen_position| is in screen coordinates. |
| 470 OnCompleteDrop(uint32 window, | 470 OnCompleteDrop(uint32 window, |
| 471 uint32 key_state, | 471 uint32 key_state, |
| 472 gfx.mojom.Point position, | 472 gfx.mojom.Point screen_position, |
| 473 uint32 effect_bitmask) => (uint32 action_taken); | 473 uint32 effect_bitmask) => (uint32 action_taken); |
| 474 | 474 |
| 475 // Called on the client that requested PerformDragDrop() to return which drag | 475 // Called on the client that requested PerformDragDrop() to return which drag |
| 476 // action was completed. This is called instead of OnChangeCompleted(). | 476 // action was completed. This is called instead of OnChangeCompleted(). |
| 477 OnPerformDragDropCompleted(uint32 window, bool success, uint32 action_taken); | 477 OnPerformDragDropCompleted(uint32 window, bool success, uint32 action_taken); |
| 478 | 478 |
| 479 // Called after OnCompleteDrop completes for every connection which received | 479 // Called after OnCompleteDrop completes for every connection which received |
| 480 // an OnDragDropStart() message. This signals that a client can forget the | 480 // an OnDragDropStart() message. This signals that a client can forget the |
| 481 // |drag_data| passed in via the first message. | 481 // |drag_data| passed in via the first message. |
| 482 OnDragDropDone(); | 482 OnDragDropDone(); |
| 483 | 483 |
| 484 // A change initiated from the client has completed. See description of | 484 // A change initiated from the client has completed. See description of |
| 485 // change ids for details. | 485 // change ids for details. |
| 486 OnChangeCompleted(uint32 change_id, bool success); | 486 OnChangeCompleted(uint32 change_id, bool success); |
| 487 | 487 |
| 488 // The WindowManager is requesting the specified window to close. If the | 488 // The WindowManager is requesting the specified window to close. If the |
| 489 // client allows the change it should delete the window. | 489 // client allows the change it should delete the window. |
| 490 RequestClose(uint32 window_id); | 490 RequestClose(uint32 window_id); |
| 491 | 491 |
| 492 // See description of WindowManager for details. | 492 // See description of WindowManager for details. |
| 493 GetWindowManager(associated WindowManager& internal); | 493 GetWindowManager(associated WindowManager& internal); |
| 494 }; | 494 }; |
| 495 | 495 |
| 496 // Mus provides this interface as a way for clients to connect and obtain a | 496 // Mus provides this interface as a way for clients to connect and obtain a |
| 497 // WindowTree handle with a supplied WindowTreeClient handle. The | 497 // WindowTree handle with a supplied WindowTreeClient handle. The |
| 498 // WindowTreeClient has no roots, use NewTopLevelWindow() to create one. | 498 // WindowTreeClient has no roots, use NewTopLevelWindow() to create one. |
| 499 interface WindowTreeFactory { | 499 interface WindowTreeFactory { |
| 500 CreateWindowTree(WindowTree& tree_request, WindowTreeClient client); | 500 CreateWindowTree(WindowTree& tree_request, WindowTreeClient client); |
| 501 }; | 501 }; |
| OLD | NEW |