diff options
Diffstat (limited to 'xorg-xrandr/resolution-changed')
-rwxr-xr-x | xorg-xrandr/resolution-changed | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/xorg-xrandr/resolution-changed b/xorg-xrandr/resolution-changed index e1457ce..4e8856f 100755 --- a/xorg-xrandr/resolution-changed +++ b/xorg-xrandr/resolution-changed @@ -1,15 +1,23 @@ #!/bin/dash reset_wallpaper_twice=0 +hostname="$(hostname | tr 'A-Z' 'a-z')" -if ! test "$(hostname | tr '[A-Z]' '[a-z]')" = zenith; then +if ! test "${hostname}" = zenith; then ## TODO how about the other east,north,hades,hyperion? # Reset rat size in case DPI change modified scaling xsetroot -cursor_name left_ptr || : # Reset rat speed in case DPI changed if test "${DESKTOP_SESSION}" = xmonad && test ! "${NO_MATE}" = y; then - msd=/usr/lib/mate-settings-daemon/mate-settings-daemon - if ! test -x "$msd"; then + if test -x /usr/lib/mate-settings-daemon/mate-settings-daemon; then + msd=/usr/lib/mate-settings-daemon/mate-settings-daemon + elif test -x /usr/bin/mate-settings-daemon; then + msd=/usr/bin/mate-settings-daemon + elif test -x /usr/libexec/mate-settings-daemon; then + msd=/usr/libexec/mate-settings-daemon + elif test -x /usr/libexec/mate-settings-daemon/mate-settings-daemon; then + msd=/usr/libexec/mate-settings-daemon/mate-settings-daemon + else msd=mate-settings-daemon fi (exec $msd --replace &) || : |