From: Toni Wilen Date: Mon, 8 Sep 2014 14:47:38 +0000 (+0300) Subject: CD Quickstart eject button was always disabled. NV led updates. X-Git-Tag: 3000~46 X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=7ac7ef7dd68e85c410fa8f9786075cfbd47701e4;p=francis%2Fwinuae.git CD Quickstart eject button was always disabled. NV led updates. --- diff --git a/main.cpp b/main.cpp index 660d32d1..4f84ea93 100644 --- a/main.cpp +++ b/main.cpp @@ -1157,7 +1157,7 @@ static int real_main2 (int argc, TCHAR **argv) memset (&gui_data, 0, sizeof gui_data); gui_data.cd = -1; gui_data.hd = -1; - gui_data.md = -1; + gui_data.md = (currprefs.cs_cd32nvram || currprefs.cs_cdtvram) ? 0 : -1; logging_init (); /* Yes, we call this twice - the first case handles when the user has loaded a config using the cmd-line. This case handles loads through the GUI. */ diff --git a/od-win32/win32gfx.cpp b/od-win32/win32gfx.cpp index 5c414b03..ce21e17b 100644 --- a/od-win32/win32gfx.cpp +++ b/od-win32/win32gfx.cpp @@ -1745,6 +1745,8 @@ static int open_windows (bool mousecapture) gui_flicker_led (i, -1, -1); gui_led (LED_POWER, gui_data.powerled); gui_fps (0, 0, 0); + if (gui_data.md >= 0) + gui_led (LED_MD, 0); for (i = 0; i < 4; i++) { if (currprefs.floppyslots[i].dfxtype >= 0) gui_led (LED_DF0 + i, 0); diff --git a/od-win32/win32gui.cpp b/od-win32/win32gui.cpp index cc9199e9..23f9c67a 100644 --- a/od-win32/win32gui.cpp +++ b/od-win32/win32gui.cpp @@ -11573,7 +11573,7 @@ static void addfloppytype (HWND hDlg, int n) if (f_text >= 0) ew (hDlg, f_text, state); if (f_eject >= 0) - ew (hDlg, f_eject, workprefs.floppyslots[n].df[0] != 0); + ew (hDlg, f_eject, text[0] != 0); if (f_drive >= 0) ew (hDlg, f_drive, state); if (f_enable >= 0) { @@ -11588,7 +11588,7 @@ static void addfloppytype (HWND hDlg, int n) if (f_wp >= 0) CheckDlgButton (hDlg, f_wp, chk); if (f_info >= 0) - ew (hDlg, f_info, workprefs.floppyslots[n].df[0] != 0); + ew (hDlg, f_info, text[0] != 0); chk = !showcd && state && DISK_validate_filename (&workprefs, text, 0, NULL, NULL, NULL) ? TRUE : FALSE; if (f_wp >= 0) { ew (hDlg, f_wp, chk && !workprefs.floppy_read_only); @@ -17395,7 +17395,8 @@ void gui_flicker_led (int led, int unitnum, int status) if (led < 0) { gui_flicker_led2 (LED_HD, 0, 0); gui_flicker_led2 (LED_CD, 0, 0); - gui_flicker_led2 (LED_MD, 0, 0); + if (gui_data.md >= 0) + gui_flicker_led2 (LED_MD, 0, 0); } else { gui_flicker_led2 (led, unitnum, status); }