src/mess/osd/winui/messui.c
| r2489 | r2490 | |
| 539 | 539 | |
| 540 | 540 | |
| 541 | 541 | |
| 542 | | static void MessRemoveImage(int drvindex, const device_config *device, LPCSTR pszFilename) |
| 542 | static void MessRemoveImage(int drvindex, const char *pszFilename) |
| 543 | 543 | { |
| 544 | | if (device != NULL) |
| 545 | | MessSpecifyImage(drvindex, device, NULL); |
| 544 | const device_config *device; |
| 545 | const char *s; |
| 546 | |
| 547 | for (device = image_device_first(config->mconfig); device != NULL; device = image_device_next(device)) |
| 548 | { |
| 549 | s = GetSelectedSoftware(drvindex, config->mconfig, device); |
| 550 | if ((s != NULL) && !strcmp(pszFilename, s)) |
| 551 | MessSpecifyImage(drvindex, device, NULL); |
| 552 | } |
| 546 | 553 | } |
| 547 | 554 | |
| 548 | 555 | |
| r2489 | r2490 | |
| 964 | 971 | static void SoftwarePicker_LeavingItem(HWND hwndSoftwarePicker, int nItem) |
| 965 | 972 | { |
| 966 | 973 | int drvindex; |
| 967 | | const device_config *device; |
| 968 | | LPCSTR pszFullName; |
| 974 | const char *pszFullName; |
| 969 | 975 | HWND hwndList; |
| 970 | 976 | |
| 971 | 977 | if (!s_bIgnoreSoftwarePickerNotifies) |
| 972 | 978 | { |
| 973 | 979 | hwndList = GetDlgItem(GetMainWindow(), IDC_LIST); |
| 974 | 980 | drvindex = Picker_GetSelectedItem(hwndList); |
| 975 | | device = SoftwarePicker_LookupDevice(hwndSoftwarePicker, nItem); |
| 976 | 981 | pszFullName = SoftwarePicker_LookupFilename(hwndSoftwarePicker, nItem); |
| 977 | 982 | |
| 978 | | MessRemoveImage(drvindex, device, pszFullName); |
| 983 | MessRemoveImage(drvindex, pszFullName); |
| 979 | 984 | } |
| 980 | 985 | } |
| 981 | 986 | |