diff options
author | Brian Ashworth <bosrsf04@gmail.com> | 2019-01-22 03:47:32 -0500 |
---|---|---|
committer | emersion <contact@emersion.fr> | 2019-01-22 13:13:34 +0100 |
commit | 8ce57f0a77f50315c83bae305e78091cc40175c2 (patch) | |
tree | 1d279b36e7c3a16defd1e3ec4be2335f0eb0982f /sway/commands/scratchpad.c | |
parent | util.c: remove numlen function (diff) | |
download | sway-8ce57f0a77f50315c83bae305e78091cc40175c2.tar.gz sway-8ce57f0a77f50315c83bae305e78091cc40175c2.tar.zst sway-8ce57f0a77f50315c83bae305e78091cc40175c2.zip |
root_scratchpad_remove_container: do not show
This removes the call to `root_scratchpad_show` from
`root_scratchpad_remove_container` and places it in the
`cmd_move_container`. This also moved the IPC `window::move` event to
`cmd_scratchpad`.
Diffstat (limited to 'sway/commands/scratchpad.c')
-rw-r--r-- | sway/commands/scratchpad.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sway/commands/scratchpad.c b/sway/commands/scratchpad.c index 805dbc0b..714efa2b 100644 --- a/sway/commands/scratchpad.c +++ b/sway/commands/scratchpad.c | |||
@@ -3,6 +3,7 @@ | |||
3 | #include "sway/config.h" | 3 | #include "sway/config.h" |
4 | #include "sway/input/input-manager.h" | 4 | #include "sway/input/input-manager.h" |
5 | #include "sway/input/seat.h" | 5 | #include "sway/input/seat.h" |
6 | #include "sway/ipc-server.h" | ||
6 | #include "sway/tree/container.h" | 7 | #include "sway/tree/container.h" |
7 | #include "sway/tree/root.h" | 8 | #include "sway/tree/root.h" |
8 | #include "sway/tree/workspace.h" | 9 | #include "sway/tree/workspace.h" |
@@ -51,6 +52,7 @@ static void scratchpad_toggle_auto(void) { | |||
51 | "Moving a visible scratchpad window (%s) to this workspace", | 52 | "Moving a visible scratchpad window (%s) to this workspace", |
52 | con->title); | 53 | con->title); |
53 | root_scratchpad_show(con); | 54 | root_scratchpad_show(con); |
55 | ipc_event_window(con, "move"); | ||
54 | return; | 56 | return; |
55 | } | 57 | } |
56 | } | 58 | } |
@@ -62,6 +64,7 @@ static void scratchpad_toggle_auto(void) { | |||
62 | struct sway_container *con = root->scratchpad->items[0]; | 64 | struct sway_container *con = root->scratchpad->items[0]; |
63 | sway_log(SWAY_DEBUG, "Showing %s from list", con->title); | 65 | sway_log(SWAY_DEBUG, "Showing %s from list", con->title); |
64 | root_scratchpad_show(con); | 66 | root_scratchpad_show(con); |
67 | ipc_event_window(con, "move"); | ||
65 | } | 68 | } |
66 | 69 | ||
67 | static void scratchpad_toggle_container(struct sway_container *con) { | 70 | static void scratchpad_toggle_container(struct sway_container *con) { |
@@ -76,6 +79,7 @@ static void scratchpad_toggle_container(struct sway_container *con) { | |||
76 | } | 79 | } |
77 | 80 | ||
78 | root_scratchpad_show(con); | 81 | root_scratchpad_show(con); |
82 | ipc_event_window(con, "move"); | ||
79 | } | 83 | } |
80 | 84 | ||
81 | struct cmd_results *cmd_scratchpad(int argc, char **argv) { | 85 | struct cmd_results *cmd_scratchpad(int argc, char **argv) { |