Skip to content

Commit

Permalink
Implement the command 'move container to mark <mark>' using 'con_move…
Browse files Browse the repository at this point in the history
…_to_mark'.
  • Loading branch information
Airblader committed Apr 19, 2015
1 parent 475671a commit 94bbdc9
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion src/commands.c
Expand Up @@ -1172,7 +1172,19 @@ void cmd_move_con_to_output(I3_CMD, char *name) {
*
*/
void cmd_move_con_to_mark(I3_CMD, char *mark) {
ysuccess(true);
DLOG("moving window to mark \"%s\"\n", mark);

HANDLE_EMPTY_MATCH;

bool result = true;
owindow *current;
TAILQ_FOREACH(current, &owindows, owindows) {
DLOG("moving matched window %p / %s to mark \"%s\"\n", current->con, current->con->name, mark);
result &= con_move_to_mark(current->con, mark);
}

cmd_output->needs_tree_render = true;
ysuccess(result);
}

/*
Expand Down

0 comments on commit 94bbdc9

Please sign in to comment.