diff options
Diffstat (limited to 'sway/desktop/transaction.c')
-rw-r--r-- | sway/desktop/transaction.c | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/sway/desktop/transaction.c b/sway/desktop/transaction.c index 0d0e0635..e186bf89 100644 --- a/sway/desktop/transaction.c +++ b/sway/desktop/transaction.c | |||
@@ -510,17 +510,27 @@ void transaction_notify_view_ready_by_serial(struct sway_view *view, | |||
510 | } | 510 | } |
511 | } | 511 | } |
512 | 512 | ||
513 | void transaction_notify_view_ready_by_size(struct sway_view *view, | 513 | void transaction_notify_view_ready_by_geometry(struct sway_view *view, |
514 | int width, int height) { | 514 | double x, double y, int width, int height) { |
515 | struct sway_transaction_instruction *instruction = | 515 | struct sway_transaction_instruction *instruction = |
516 | view->container->node.instruction; | 516 | view->container->node.instruction; |
517 | if (instruction != NULL && | 517 | if (instruction != NULL && |
518 | (int)instruction->container_state.content_x == (int)x && | ||
519 | (int)instruction->container_state.content_y == (int)y && | ||
518 | instruction->container_state.content_width == width && | 520 | instruction->container_state.content_width == width && |
519 | instruction->container_state.content_height == height) { | 521 | instruction->container_state.content_height == height) { |
520 | set_instruction_ready(instruction); | 522 | set_instruction_ready(instruction); |
521 | } | 523 | } |
522 | } | 524 | } |
523 | 525 | ||
526 | void transaction_notify_view_ready_immediately(struct sway_view *view) { | ||
527 | struct sway_transaction_instruction *instruction = | ||
528 | view->container->node.instruction; | ||
529 | if (instruction != NULL) { | ||
530 | set_instruction_ready(instruction); | ||
531 | } | ||
532 | } | ||
533 | |||
524 | void transaction_commit_dirty(void) { | 534 | void transaction_commit_dirty(void) { |
525 | if (!server.dirty_nodes->length) { | 535 | if (!server.dirty_nodes->length) { |
526 | return; | 536 | return; |