Made i3exit.bash multiscreen-aware.
This commit is contained in:
@@ -16,13 +16,13 @@ log()
|
|||||||
|
|
||||||
lock()
|
lock()
|
||||||
{
|
{
|
||||||
resolution=$(xrandr | grep '*' | awk '{ print $1 }')
|
resolution=$(xrandr | grep '*' | awk '{ print $1 }' | head -n1)
|
||||||
log "[I] Resolution found: \"$resolution\""
|
log "[I] Resolution found: \"$resolution\""
|
||||||
lockscreen="$HOME/.i3/data/lockscreen_$resolution.png"
|
lockscreen="$HOME/.i3/data/lockscreen_$resolution.png"
|
||||||
log "[I] Looking for lockscreen at \"$lockscreen\""
|
log "[I] Looking for lockscreen at \"$lockscreen\""
|
||||||
if [[ -f "$lockscreen" ]] ; then
|
if [[ -f "$lockscreen" ]] ; then
|
||||||
log "[I] Lockscreen found, will be used as background image."
|
log "[I] Lockscreen found, will be used as background image."
|
||||||
background_options="--image $lockscreen"
|
background_options="--image $lockscreen -t"
|
||||||
else
|
else
|
||||||
log "[W] Lockscreen not found, using color #$FALLBACK_COLOR as background."
|
log "[W] Lockscreen not found, using color #$FALLBACK_COLOR as background."
|
||||||
background_options="--color $FALLBACK_COLOR"
|
background_options="--color $FALLBACK_COLOR"
|
||||||
|
|||||||
Reference in New Issue
Block a user