Previous 199869 Revisions Next

r20697 Sunday 3rd February, 2013 at 13:28:54 UTC by Fabio Priuli
uimain.c: fixed handling of slot options which have only internal options available (and hence
are not configurable by the end-user) [Fabio Priuli]
[src/emu]dislot.c dislot.h uimain.c

trunk/src/emu/uimain.c
r20696r20697
465465      // do no display fixed slots
466466      if (slot->fixed()) title = slot->get_default_card();
467467      if (title==NULL) title = "";
468      item_append(slot->device().tag()+1, strcmp(title,"")==0 ? "------" : title, slot->fixed() ? 0 : (MENU_FLAG_LEFT_ARROW | MENU_FLAG_RIGHT_ARROW), (void *)slot);
468      item_append(slot->device().tag()+1, strcmp(title,"")==0 ? "------" : title, (slot->fixed() || slot->all_internal()) ? 0 : (MENU_FLAG_LEFT_ARROW | MENU_FLAG_RIGHT_ARROW), (void *)slot);
469469   }
470470   item_append(MENU_SEPARATOR_ITEM, NULL, 0, NULL);
471471   item_append("Reset",  NULL, 0, NULL);
trunk/src/emu/dislot.c
r20696r20697
5353   return dev;
5454}
5555
56const bool device_slot_interface::all_internal()
57{
58   for (int i = 0; m_slot_interfaces && m_slot_interfaces[i].name != NULL; i++)
59      if (!m_slot_interfaces[i].internal)
60         return FALSE;
61   return TRUE;
62}
63
5664device_slot_card_interface::device_slot_card_interface(const machine_config &mconfig, device_t &device)
5765   : device_interface(device)
5866{
trunk/src/emu/dislot.h
r20696r20697
5959   const void *default_config() const { return m_default_config; }
6060   const UINT32 default_clock() const { return m_default_clock; }
6161   const bool fixed() const { return m_fixed; }
62   const bool all_internal();
6263   device_t* get_card_device();
6364protected:
6465   const char *m_default_card;

Previous 199869 Revisions Next


© 1997-2024 The MAME Team