From 1461c3bc62ce91472674af3a7d88077bd4e61493 Mon Sep 17 00:00:00 2001 From: ksyasuda Date: Tue, 15 Feb 2022 02:22:59 -0800 Subject: [PATCH] change -only-match to -no-custom to allow ESC to quit rofi menus --- ani-cli | 6 +++--- aniwrapper | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/ani-cli b/ani-cli index d525898..b2c3a65 100755 --- a/ani-cli +++ b/ani-cli @@ -394,7 +394,7 @@ find_media() { fi get_directory_data "$inp" - selection="$(rofi -dpi "$DPI" -dmenu -only-match -async-pre-read 33 -config "$ROFI_CFG" \ + selection="$(rofi -dpi "$DPI" -dmenu -no-custom -async-pre-read 33 -config "$ROFI_CFG" \ -l 15 -i -sep '|' -mesg "$(generate_span "Current directory: $inp")" -a "$watched" \ -p "Enter selection" -window-title 'aniwrapper' <<< "$inputlist")" lg "SELECTION: $selection" 1> /dev/stderr @@ -496,7 +496,7 @@ anime_selection() { # get the anime from indexed list msg="$(generate_span "Query: $query")" - selection="$(rofi -dpi "$DPI" -dmenu -only-match \ + selection="$(rofi -dpi "$DPI" -dmenu -no-custom \ -async-pre-read 33 -config "$ROFI_CFG" -l 15 -i -sep '|' \ -mesg "$msg" -a "$searched" -p "Enter selection" -window-title 'aniwrapper' <<< "$menu")" choice="${selection%%.*}" # remmove everything from . to end @@ -908,7 +908,7 @@ main() { done <<< "$qualities" choice=$(rofi -dmenu -dpi "$DPI" -config "$ROFI_CFG" \ -theme-str 'listview {columns: 1;} window {width: 25%;}' \ - -i -l 6 -only-match -sep '|' -a "$cur_quality" -mesg "$(generate_span "Current quality: $quality")" \ + -i -l 6 -no-custom -sep '|' -a "$cur_quality" -mesg "$(generate_span "Current quality: $quality")" \ -p "Choose quality:" -window-title 'aniwrapper' -selected-row "$cur_quality" <<< "$qualities") quality=$(awk '{ print $2 }' <<< "$choice") else diff --git a/aniwrapper b/aniwrapper index 9487c1b..371831e 100755 --- a/aniwrapper +++ b/aniwrapper @@ -116,7 +116,7 @@ get_quality() { -l 6 -selected-row 0 -a 0 -window-title 'aniwrapper' \ -theme-str 'listview {columns: 1;} window {width: 25%;}' \ -p "Choose video quality:" \ - -sep '|' -only-match <<< "$QUALITIES") + -sep '|' -no-custom <<< "$QUALITIES") QUALITY=$(awk '{print $2}' <<< "$selection") else qualities="best|1080p|720p|480p|360p|worst" @@ -314,7 +314,7 @@ get_dl_dir() { main() { ((SILENT != 1)) && lg "CONFIG DIR: $CFG_DIR" ((SILENT != 1)) && lg "ROFI CFG: $CFG_FILE" - choice=$(echo "${options[@]}" | rofi -dpi "$DPI" -dmenu -only-match -sep '|' \ + choice=$(echo "${options[@]}" | rofi -dpi "$DPI" -dmenu -no-custom -sep '|' \ -theme-str 'listview {columns: 1;} window {width: 45%;}' \ -config "$CFG_FILE" -l 7 -i -p "Aniwrapper" -window-title 'aniwrapper') @@ -396,7 +396,7 @@ main() { theme_idx="$(get_theme_idx)" choice=$(rofi -dmenu -config "$CFG_FILE" -dpi "$DPI" -window-title 'aniwrapper' \ -theme-str 'listview {columns: 1;} window {width: 45%;}' \ - -only-match -l 4 -i -p "Choose theme: " -sep '|' \ + -no-custom -l 4 -i -p "Choose theme: " -sep '|' \ -theme-str 'listview { columns: 2; }' \ -a "$theme_idx" -selected-row "$theme_idx" <<< "$THEMES") theme=$(awk '{ print $1 }' <<< "$choice")