From 8333624e8cc50ed934bd4f4b2aaeef11f628e5de Mon Sep 17 00:00:00 2001 From: Daniel Napora Date: Wed, 14 Sep 2022 23:17:27 +0200 Subject: [PATCH] mcc upd,skippy-xd-fix --- bin/mcc | 20 +++++++++++------ bin/skippy-xd-fix | 57 +++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 70 insertions(+), 7 deletions(-) create mode 100755 bin/skippy-xd-fix diff --git a/bin/mcc b/bin/mcc index 32f7ac0..893c233 100755 --- a/bin/mcc +++ b/bin/mcc @@ -97,6 +97,7 @@ case $LANG in KERNELS="Jądra" INSTALLED="zainstalowany:" MABOX_DESC="Twój lekki, szybki i funkcjonalny Linuksowy Desktop" + ADVANCED="Zaawansowane" ;; es*) TITLE="Centro de control Mabox" @@ -185,7 +186,9 @@ case $LANG in KERNEL_LBL="kernel" KERNELS="Kernels" INSTALLED="install date: " - MABOX_DESC="Your fast, lightweight and functional Linux Desktop";; + MABOX_DESC="Your fast, lightweight and functional Linux Desktop" + ADVANCED="Advanced" + ;; *) TITLE="Mabox Control Center" MCC="Mabox Control Center\t\nConfigure and customize your Mabox Linux\t" @@ -273,7 +276,9 @@ case $LANG in KERNEL_LBL="kernel" KERNELS="Kernels" INSTALLED="install date: " - MABOX_DESC="Your fast, lightweight and functional Linux Desktop";; + MABOX_DESC="Your fast, lightweight and functional Linux Desktop" + ADVANCED="Advanced" + ;; esac maindialog () { @@ -379,13 +384,13 @@ yad --plug=$KEY --tabnum=4 --borders=20 --uri-handler=xdg-open \ # TINT2 yad --plug=$KEY --tabnum=2 --borders=20 \ ---text="$TINT_DESC" --image=tint2conf \ +--text="$TINT_DESC \n" --image=tint2conf \ --columns=1 --form \ --field="$T_LAUNCHERS:FBTN" "jgtint2launcher" \ --field="$T_CONF:FBTN" "jgtint2-pipe -s" \ ---field="$T_CHOOSE:FBTN" "mb-tint2-manager" \ --field="$T_RESTART:FBTN" "mb-tint2restart" \ ---field=":LBL" "" \ +--field="$ADVANCED:LBL" "" \ +--field="$T_CHOOSE:FBTN" "mb-tint2-manager" \ --field="$TINT_DIR:FBTN" "exo-open $HOME/.config/tint2/" \ > $res5 & @@ -464,11 +469,12 @@ yad --plug=$KEY --tabnum=7 --borders=20 \ # CONKY yad --plug=$KEY --tabnum=8 --borders=20 \ ---text="$CONKY_DESC" --image=conky \ +--text="$CONKY_DESC \n" --image=conky \ --form \ --field=" Colorizer Conky (new)!colorizer!:FBTN" "colorizer-conky -s" \ ---field="$CONKY_CHOOSE:FBTN" "mb-conky-manager" \ --field="$CONKY_RESTART:FBTN" "mb-conky-session" \ +--field="$ADVANCED :LBL" "" \ +--field="$CONKY_CHOOSE:FBTN" "mb-conky-manager" \ --field="$CONKY_EDIT:FBTN" "mb-conkyedit" \ --field="$OPEN_CONKYDIR:FBTN" "exo-open $HOME/.config/conky/" \ > $res10 & diff --git a/bin/skippy-xd-fix b/bin/skippy-xd-fix new file mode 100755 index 0000000..16c578d --- /dev/null +++ b/bin/skippy-xd-fix @@ -0,0 +1,57 @@ +#!/bin/bash + +# +# skippy-wrapper - B. Murphy +# +# a work around for the bug in skippy-xd that prevents minimized +# windows being included in the selection screen. +# +# dependency: xdotool +# + +# +# prelim -- check not already running +# 0. get desktop +# 1. get list of all windows +# 2. get list of visible windows +# 3 generate list of hidden windows +# 4. raise hidden windows +# 5. run skippy-xd +# 6. get active window = SkippySelected +# 7. minimize hidden windows unless selected +# + +#prelim +if [[ "`pidof -x $(basename $0) -o %PPID`" ]]; then exit; fi + +#0. +dtop=`xdotool get_desktop` + +#1. +any=`xdotool search --desktop $dtop "" 2> /dev/null` + +#2. +visible=`xdotool search --desktop $dtop --onlyvisible "" 2> /dev/null` + +#3. +hidden=$any +for item in $visible; do + hidden=`echo ${hidden/$item/''}` +done + +#4. +for item in $hidden; do + xdotool windowmap $item +done + +#5. +skippy-xd &> /dev/null + +#6. +SkippySelected=`xdotool getactivewindow` + +#7. +hidden=`echo ${hidden/$SkippySelected/''}` +for item in $hidden; do + xdotool windowminimize $item +done