Previous 199869 Revisions Next

r32760 Wednesday 15th October, 2014 at 07:10:54 UTC by Miodrag Milanović
Better fix for init order on software item load (nw)
[src/emu/ui]imgcntrl.c

trunk/src/emu/ui/imgcntrl.c
r32759r32760
132132void ui_menu_control_device_image::load_software_part()
133133{
134134   astring temp_name(sld->list_name(), ":", swi->shortname(), ":", swp->name());
135   image->set_init_phase();
136135   hook_load(temp_name, true);
137136}
138137
r32759r32760
143142
144143void ui_menu_control_device_image::hook_load(astring name, bool softlist)
145144{
145   if (image->is_reset_on_load()) image->set_init_phase();
146146   image->load(name);
147147   ui_menu::stack_pop(machine());
148148}
r32759r32760
205205   case SELECT_PARTLIST:
206206      swi = sld->find(software_info_name);
207207      if (!swi)
208         state = START_SOFTLIST;   
209      else if(swi->has_multiple_parts(image->image_interface()))
208         state = START_SOFTLIST;
209      else if(swi->has_multiple_parts(image->image_interface()))
210210      {
211211         submenu_result = -1;
212212         swp = 0;
213213         ui_menu::stack_push(auto_alloc_clear(machine(), ui_menu_software_parts(machine(), container, swi, image->image_interface(), &swp, false, &submenu_result)));
214214         state = SELECT_ONE_PART;
215      }
216      else
215      }
216      else
217217      {
218218         swp = swi->first_part();
219219         load_software_part();
r32759r32760
256256         state = START_SOFTLIST;
257257         handle();
258258         break;
259           
259
260260      case -1: // return to system
261261         ui_menu::stack_pop(machine());
262262         break;

Previous 199869 Revisions Next


© 1997-2024 The MAME Team