summaryrefslogtreecommitdiffstats
path: root/core/modules/vmware-common
diff options
context:
space:
mode:
Diffstat (limited to 'core/modules/vmware-common')
-rwxr-xr-xcore/modules/vmware-common/data/opt/openslx/xscreensaver/ungrab.d/vmware16
1 files changed, 8 insertions, 8 deletions
diff --git a/core/modules/vmware-common/data/opt/openslx/xscreensaver/ungrab.d/vmware b/core/modules/vmware-common/data/opt/openslx/xscreensaver/ungrab.d/vmware
index c411bfec..66e5eed4 100755
--- a/core/modules/vmware-common/data/opt/openslx/xscreensaver/ungrab.d/vmware
+++ b/core/modules/vmware-common/data/opt/openslx/xscreensaver/ungrab.d/vmware
@@ -4,28 +4,28 @@ wfile="/run/user/$(id -u)/vmwins"
if [ "$1" = "pre" ]; then
# Find all vmware windows currently visible
- WINDOWS=$(xdotool search --onlyvisible --class vmplayer)
+ WINDOWS="$( xdotool search --onlyvisible --class vmplayer )"
[ -z "$WINDOWS" ] && exit 0
for window in $WINDOWS; do
- xdotool windowminimize $window
+ xdotool windowminimize "$window"
echo "$window" >> "$wfile" # Remember for later
done
# move mouse pointer around to avoid some problems with ghost clicks
- # also this resets the idle time durr hurr
- xdotool mousemove 0 0
+ xdotool mousemove --sync 0 0
usleep 10000
- xdotool mousemove --polar 0 0
+ xdotool click 1
usleep 10000
- xdotool key "ctrl+alt+shift+super"
+ xdotool mousemove --polar 0 0
usleep 10000
fi
if [ "$1" = "post" ]; then
# let's restore vmware
- WINDOWS=$(sort -u "$wfile")
+ WINDOWS="$( sort -u "$wfile" )"
for window in $WINDOWS; do
- xdotool windowmap $window
+ xdotool windowmap "$window"
done
+ rm -f -- "$wfile"
fi
exit 0