From: <man...@us...> - 2012-07-19 20:57:40
|
Revision: 12741 http://openmsx.svn.sourceforge.net/openmsx/?rev=12741&view=rev Author: manuelbi Date: 2012-07-19 20:57:34 +0000 (Thu, 19 Jul 2012) Log Message: ----------- In the OSD menu filter on extensions case insensitively. Modified Paths: -------------- openmsx/trunk/share/scripts/osd_menu.tcl Modified: openmsx/trunk/share/scripts/osd_menu.tcl =================================================================== --- openmsx/trunk/share/scripts/osd_menu.tcl 2012-07-19 18:18:29 UTC (rev 12740) +++ openmsx/trunk/share/scripts/osd_menu.tcl 2012-07-19 20:57:34 UTC (rev 12741) @@ -935,17 +935,18 @@ } proc ls {directory extensions} { - set roms [glob -nocomplain -tails -directory $directory -type f *.{$extensions}] + set files [glob -nocomplain -tails -directory $directory -type f *] + set items [lsearch -regexp -all -inline -nocase $files .*\\.($extensions)] set dirs [glob -nocomplain -tails -directory $directory -type d *] set dirs2 [list] foreach dir $dirs { lappend dirs2 "$dir/" } - return [concat ".." [lsort $dirs2] [lsort $roms]] + return [concat ".." [lsort $dirs2] [lsort $items]] } proc menu_create_ROM_list {path} { - return [prepare_menu_list [concat "--eject--" [ls $path "rom,zip,gz"]] \ + return [prepare_menu_list [concat "--eject--" [ls $path "rom|zip|gz"]] \ 10 \ { execute menu_select_rom font-size 8 @@ -979,7 +980,7 @@ } proc menu_create_disk_list {path} { - return [prepare_menu_list [concat "--eject--" [ls $path "dsk,zip,gz,xsa"]] \ + return [prepare_menu_list [concat "--eject--" [ls $path "dsk|zip|gz|xsa"]] \ 10 \ { execute menu_select_disk font-size 8 @@ -1010,7 +1011,7 @@ } proc menu_create_tape_list {path} { - return [prepare_menu_list [concat "--eject--" "--rewind--" [ls $path "cas,wav,zip,gz"]] \ + return [prepare_menu_list [concat "--eject--" "--rewind--" [ls $path "cas|wav|zip|gz"]] \ 10 \ { execute menu_select_tape font-size 8 This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |