diff --git a/bin/about-mabox b/bin/about-mabox index e754446..db29ef9 100755 --- a/bin/about-mabox +++ b/bin/about-mabox @@ -17,7 +17,7 @@ yad --title="About Mabox" --window-icon=mbcc \ --pversion="$(lsb_release -rs) ${OSCODE}" \ --image=mbcc \ --comments="${COMMENT}" \ - --copyright="Copyright 2016-2023, Daniel Napora " \ + --copyright="Copyright 2016-2024, Daniel Napora " \ --license=GPL3 \ --website="https://maboxlinux.org" \ --website-label=maboxlinux.org \ diff --git a/bin/mbwallpaper b/bin/mbwallpaper index 3d2e0d0..39fadd0 100755 --- a/bin/mbwallpaper +++ b/bin/mbwallpaper @@ -41,7 +41,7 @@ checkwplist() { # If list does not exist or is empty if [[ ! -f $WALLPAPERS_LIST || $(wc -l <$WALLPAPERS_LIST) -lt 1 ]]; then # Prepare list with wallpapers (only PNG and JPG) - ls -1 "$wallpaper_dir"/*{.jpg,.png} > "$WALLPAPERS_LIST" + ls -1 "$wallpaper_dir"/*{.jpg,.png,.avif} > "$WALLPAPERS_LIST" fi } @@ -59,11 +59,11 @@ choose() { case $LANG in pl*) TITLE="Wybierz tapetę" - TEXT="\nUżyj strzałek lub kółka myszy by nawigować.\nEnter by ustawić tapetę.\nEsc by wyjść." + TEXT="\nStrzałki / kółko myszy poprzednia/następna.\nEnter by ustawić tapetę.\nEsc by wyjść." ;; *) TITLE="Select Wallpaper" - TEXT="\nUse Arrows or mousewheel to navigate.\nEnter to set wallpaper.\nEsc to quit." + TEXT="\nArrows / mousewheel prev/next.\nEnter to set wallpaper.\nEsc to quit." ;; esac @@ -71,12 +71,12 @@ esac SCREENSIZE=$(wmctrl -d |grep "*" | awk -F' ' '{print $4}') W="${SCREENSIZE%x*}" H="${SCREENSIZE#*x}" - FW=$((W/4)) - FH=$((H/4)) + FW=$((W/2)) + FH=$((H/2)) X="40" Y=$((H-FH-40)) - notify-send.sh -u normal -i emblem-photos "$TITLE" "$TEXT" - feh -B "#4D4D4D" -N -x --scale-down -E ${FH} -y ${FW} -^ "Enter=select, Arrows=next,prev" -g ${FW}x${FH}+${X}+${Y} ${wallpaper_dir} -A "${command} '%f'" + notify-send.sh -t 12000 -i ~/.config/mabox/wpicon.png "$TITLE" "$TEXT" + feh -B "#4D4D4D" -N -x --scale-down -E ${FH} -y ${FW} -^ "Enter=select, Arrows=next/prev Esc=quit" -g ${FW}x${FH}+${X}+${Y} ${wallpaper_dir} -A "${command} '%f'" } slideshow() { @@ -96,6 +96,11 @@ do done done } +changedir(){ + wdir=${1/$HOME/\~} + #notify-send.sh "dirrrrrrr" "$wdir" + sd "wallpaper_dir=.*$" "wallpaper_dir=${wdir}" ${CONFIG_FILE} +} usage() { grep "^#:" $0 | while read DOC; do printf '%s\n' "${DOC###:}"; done @@ -106,7 +111,8 @@ case "$1" in -o|one) one;; -c|choose) choose;; -h|--help) usage;; - *) slideshow;; + -s) slideshow;; + -d|changedir) changedir "$2";; esac exit 0 diff --git a/bin/run_wallpaperslideshow b/bin/run_wallpaperslideshow index e9a0570..449f96a 100755 --- a/bin/run_wallpaperslideshow +++ b/bin/run_wallpaperslideshow @@ -14,9 +14,9 @@ case $LANG in ;; esac -mbwallpaper & +mbwallpaper -s & mbwallpaper_pid=$! notify-send.sh -i emblem-photos "$TITLE" "$TEXT" yad --notification --image emblem-photos --text "$CLICK" -kill $mbwallpaper_pid -wait $mbwallpaper_pid +kill -9 $mbwallpaper_pid +#wait $mbwallpaper_pid diff --git a/local/bin/lxappearance b/local/bin/lxappearance index fd02b3f..c1b5d18 100755 --- a/local/bin/lxappearance +++ b/local/bin/lxappearance @@ -35,4 +35,5 @@ else xrdb "$HOME/.Xresources" fi +reload-gtk