Revision: 19097
http://vice-emu.svn.sourceforge.net/vice-emu/?rev=19097&view=rev
Author: pottendo
Date: 2008-08-02 15:59:30 +0000 (Sat, 02 Aug 2008)
Log Message:
-----------
UI_CALLBACK(set_c64dtv_rom_name):
Make use of `ui_select_file(...)' for dtvrom selection.
Modified Paths:
--------------
branches/viceplus/v2.0-x64dtv/vice/src/arch/unix/gui/uic64dtv.c
Modified: branches/viceplus/v2.0-x64dtv/vice/src/arch/unix/gui/uic64dtv.c
===================================================================
--- branches/viceplus/v2.0-x64dtv/vice/src/arch/unix/gui/uic64dtv.c 2008-08-02 04:32:39 UTC (rev 19096)
+++ branches/viceplus/v2.0-x64dtv/vice/src/arch/unix/gui/uic64dtv.c 2008-08-02 15:59:30 UTC (rev 19097)
@@ -40,8 +40,29 @@
UI_CALLBACK(set_c64dtv_rom_name)
{
- uilib_select_string((char *)UI_MENU_CB_PARAM, _("C64DTV ROM image name"),
- _("Name:"));
+ char *filename;
+ ui_button_t button;
+ static char *last_dir;
+
+ filename = ui_select_file(_("C64DTV ROM image name"),
+ NULL, 0, 0, last_dir,
+ "*.[bB][iI][nN]",
+ &button, 0, NULL);
+
+ switch (button) {
+ case UI_BUTTON_OK:
+ resources_set_string("c64dtvromfilename", filename);
+ if (last_dir)
+ lib_free(last_dir);
+ util_fname_split(filename, &last_dir, NULL);
+ break;
+ default:
+ /* Do nothing special. */
+ break;
+ }
+ if (filename != NULL)
+ lib_free(filename);
+
}
static ui_menu_entry_t c64dtv_revision_submenu[] = {
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|