Merge branch 'fix-focustoggle'
This commit is contained in:
commit
16f9c9aee7
|
@ -484,7 +484,7 @@ focus:
|
|||
int to_focus = $2;
|
||||
if ($2 == TOK_MODE_TOGGLE) {
|
||||
current = TAILQ_FIRST(&(ws->focus_head));
|
||||
if (current->type == CT_FLOATING_CON)
|
||||
if (current != NULL && current->type == CT_FLOATING_CON)
|
||||
to_focus = TOK_TILING;
|
||||
else to_focus = TOK_FLOATING;
|
||||
}
|
||||
|
|
|
@ -0,0 +1,17 @@
|
|||
#!perl
|
||||
# vim:ts=4:sw=4:expandtab
|
||||
#
|
||||
# Regression: Checks if i3 still lives after using 'focus mode_toggle' on an
|
||||
# empty workspace. This regression was fixed in
|
||||
# 0848844f2d41055f6ffc69af1149d7a873460976.
|
||||
#
|
||||
use i3test;
|
||||
use v5.10;
|
||||
|
||||
my $tmp = fresh_workspace;
|
||||
|
||||
cmd 'focus mode_toggle';
|
||||
|
||||
does_i3_live;
|
||||
|
||||
done_testing;
|
Loading…
Reference in New Issue