mirror of
https://github.com/ksyasuda/aniwrapper.git
synced 2024-11-22 03:19:53 -08:00
update quality selection menu
This commit is contained in:
parent
985a19fcf0
commit
24f3c25142
2
ani-cli
2
ani-cli
@ -970,7 +970,7 @@ main() {
|
|||||||
esac
|
esac
|
||||||
choice=$(rofi -dmenu -dpi "$DPI" -config "$ROFI_CFG" \
|
choice=$(rofi -dmenu -dpi "$DPI" -config "$ROFI_CFG" \
|
||||||
-i -l 5 -only-match -sep '|' -a "$cur_quality" -mesg "$(generate_span "Current quality: $quality")" \
|
-i -l 5 -only-match -sep '|' -a "$cur_quality" -mesg "$(generate_span "Current quality: $quality")" \
|
||||||
-p "Choose quality:" <<< "1. best (default)|2. 1080p|3. 720p|4. 360p|5. worst")
|
-p "Choose quality:" <<< "1. best|2. 1080p|3. 720p|4. 360p|5. worst")
|
||||||
quality=$(awk '{ print $2 }' <<< "$choice")
|
quality=$(awk '{ print $2 }' <<< "$choice")
|
||||||
else
|
else
|
||||||
qualities="best|1080p|720p|480p|360p|worst"
|
qualities="best|1080p|720p|480p|360p|worst"
|
||||||
|
@ -11,7 +11,7 @@ CFG_FILE="$CFG_DIR/themes/aniwrapper.rasi"
|
|||||||
DEFAULT_DOWNLOAD="$HOME/Videos/sauce"
|
DEFAULT_DOWNLOAD="$HOME/Videos/sauce"
|
||||||
ROFI_THEME="aniwrapper.rasi"
|
ROFI_THEME="aniwrapper.rasi"
|
||||||
THEMES="aniwrapper (default)|dracula|doomone|fancy|flamingo|material|nord|onedark"
|
THEMES="aniwrapper (default)|dracula|doomone|fancy|flamingo|material|nord|onedark"
|
||||||
QUALITIES="1. best (default)|2. 1080p|3. 720p|4. 360p|5. worst"
|
QUALITIES="1. best|2. 1080p|3. 720p|4. 360p|5. worst"
|
||||||
QUALITY=best
|
QUALITY=best
|
||||||
DPI=96
|
DPI=96
|
||||||
GET_QUALITY=0
|
GET_QUALITY=0
|
||||||
@ -98,7 +98,7 @@ run() {
|
|||||||
get_quality() {
|
get_quality() {
|
||||||
if ((IS_ROFI == 1)); then
|
if ((IS_ROFI == 1)); then
|
||||||
selection=$(rofi -dpi "$DPI" -dmenu -config "$CFG_FILE" \
|
selection=$(rofi -dpi "$DPI" -dmenu -config "$CFG_FILE" \
|
||||||
-l 5 -selected-row 0 \
|
-l 5 -selected-row 0 -a 0 \
|
||||||
-theme-str 'listview {columns: 1;}' -p "Choose video quality:" \
|
-theme-str 'listview {columns: 1;}' -p "Choose video quality:" \
|
||||||
-sep '|' -only-match <<< "$QUALITIES")
|
-sep '|' -only-match <<< "$QUALITIES")
|
||||||
QUALITY=$(awk '{print $2}' <<< "$selection")
|
QUALITY=$(awk '{print $2}' <<< "$selection")
|
||||||
|
Loading…
Reference in New Issue
Block a user