diff --git a/dump-asy.pl b/dump-asy.pl index 315dcc6f..dc2cbeab 100755 --- a/dump-asy.pl +++ b/dump-asy.pl @@ -11,7 +11,7 @@ use v5.10; my $i3 = i3("/tmp/nestedcons"); -my $tree = $i3->get_workspaces->recv; +my $tree = $i3->get_tree->recv; my $tmp = File::Temp->new(UNLINK => 0, SUFFIX => '.asy'); diff --git a/gtk-tree-watch.pl b/gtk-tree-watch.pl index b82d25d2..f15d0c18 100755 --- a/gtk-tree-watch.pl +++ b/gtk-tree-watch.pl @@ -116,7 +116,7 @@ my $layout_container = Gtk2::HBox->new(0, 0); $layout_sw->add_with_viewport($layout_container); sub copy_tree { - my $tree = $i3->get_workspaces->recv; + my $tree = $i3->get_tree->recv; # convert the tree back to json so we only rebuild/redraw when the tree is changed my $json = encode_json($tree); diff --git a/testcases/t/02-fullscreen.t b/testcases/t/02-fullscreen.t index aa6861fb..e13bff63 100644 --- a/testcases/t/02-fullscreen.t +++ b/testcases/t/02-fullscreen.t @@ -16,7 +16,7 @@ sub fullscreen_windows { } # get the output of this workspace -my $tree = $i3->get_workspaces->recv; +my $tree = $i3->get_tree->recv; my @outputs = @{$tree->{nodes}}; my $output = first { defined(first { $_->{name} eq $tmp } @{$_->{nodes}}) } @outputs; diff --git a/testcases/t/16-nestedcons.t b/testcases/t/16-nestedcons.t index 3d392c46..8c66516c 100644 --- a/testcases/t/16-nestedcons.t +++ b/testcases/t/16-nestedcons.t @@ -10,7 +10,7 @@ my $i3 = i3("/tmp/nestedcons"); # Request tree #################### -my $tree = $i3->get_workspaces->recv; +my $tree = $i3->get_tree->recv; my $expected = { fullscreen_mode => 0, diff --git a/testcases/t/26-regress-close.t b/testcases/t/26-regress-close.t index 95bac458..125caf73 100644 --- a/testcases/t/26-regress-close.t +++ b/testcases/t/26-regress-close.t @@ -18,7 +18,7 @@ $i3->command('kill')->recv; $i3->command('kill')->recv; -my $tree = $i3->get_workspaces->recv; +my $tree = $i3->get_tree->recv; my @nodes = @{$tree->{nodes}}; ok(@nodes > 0, 'i3 still lives'); diff --git a/testcases/t/27-regress-floating-parent.t b/testcases/t/27-regress-floating-parent.t index c09858f6..f489eaa6 100644 --- a/testcases/t/27-regress-floating-parent.t +++ b/testcases/t/27-regress-floating-parent.t @@ -32,7 +32,7 @@ is(get_focused($tmp), $floating, 'floating window focused'); sleep 1; $i3->command('mode toggle')->recv; -my $tree = $i3->get_workspaces->recv; +my $tree = $i3->get_tree->recv; my @nodes = @{$tree->{nodes}}; ok(@nodes > 0, 'i3 still lives'); diff --git a/testcases/t/34-invalid-command.t b/testcases/t/34-invalid-command.t index 12380d46..e1cc2c6f 100644 --- a/testcases/t/34-invalid-command.t +++ b/testcases/t/34-invalid-command.t @@ -9,7 +9,7 @@ my $i3 = i3("/tmp/nestedcons"); $i3->command("blargh!")->recv; -my $tree = $i3->get_workspaces->recv; +my $tree = $i3->get_tree->recv; my @nodes = @{$tree->{nodes}}; ok(@nodes > 0, 'i3 still lives'); diff --git a/testcases/t/lib/i3test.pm b/testcases/t/lib/i3test.pm index d241cfae..c0a229dc 100644 --- a/testcases/t/lib/i3test.pm +++ b/testcases/t/lib/i3test.pm @@ -63,7 +63,7 @@ sub open_empty_con { sub get_workspace_names { my $i3 = i3("/tmp/nestedcons"); # TODO: use correct command as soon as AnyEvent::i3 is updated - my $tree = $i3->get_workspaces->recv; + my $tree = $i3->get_tree->recv; my @workspaces = map { @{$_->{nodes}} } @{$tree->{nodes}}; [ map { $_->{name} } @workspaces ] } @@ -78,7 +78,7 @@ sub get_unused_workspace { sub get_ws { my ($name) = @_; my $i3 = i3("/tmp/nestedcons"); - my $tree = $i3->get_workspaces->recv; + my $tree = $i3->get_tree->recv; my @ws = map { @{$_->{nodes}} } @{$tree->{nodes}}; # as there can only be one workspace with this name, we can safely @@ -100,7 +100,7 @@ sub get_ws_content { sub get_focused { my ($ws) = @_; my $i3 = i3("/tmp/nestedcons"); - my $tree = $i3->get_workspaces->recv; + my $tree = $i3->get_tree->recv; my @ws = map { @{$_->{nodes}} } @{$tree->{nodes}}; my @cons = grep { $_->{name} eq $ws } @ws;