From 362171c5a47096429496acd512c335812e97256b Mon Sep 17 00:00:00 2001 From: Simon Rettberg Date: Tue, 18 Oct 2016 15:10:52 +0200 Subject: Improve manager switching scripts --- sample_configuration/switchBack.sh | 9 ++++++++- sample_configuration/switchToManager.sh | 12 ++++++++++-- 2 files changed, 18 insertions(+), 3 deletions(-) (limited to 'sample_configuration') diff --git a/sample_configuration/switchBack.sh b/sample_configuration/switchBack.sh index cc2bae9..0fc3039 100755 --- a/sample_configuration/switchBack.sh +++ b/sample_configuration/switchBack.sh @@ -1,3 +1,10 @@ #!/bin/bash + +# Force vmplayer to desktop 0 +WINDOWS=$(xdotool search --class vmplayer) +for window in $WINDOWS; do + wmctrl -i -r $window -t 0 +done + # switch back to desktop 0 -wmctrl -s 0 +wmctrl -s 0 diff --git a/sample_configuration/switchToManager.sh b/sample_configuration/switchToManager.sh index 86c6704..84f3c37 100755 --- a/sample_configuration/switchToManager.sh +++ b/sample_configuration/switchToManager.sh @@ -1,6 +1,14 @@ #!/bin/bash + +# make sure vmplayer is really on workspace 0 +WINDOWS=$(xdotool search --class vmplayer) +for window in $WINDOWS; do + wmctrl -i -r $window -t 0 +done + # move PVS-Manager to workspace 1 and focus it wt="PVS2-Manager" +wmctrl -r "$wt" -t 1 +wmctrl -s 1 +wmctrl -a "$wt" -wmctrl -r $wt -t 1 -wmctrl -a $wt -- cgit v1.2.3-55-g7522