Previous 15994 Revisions Next

r14264 Monday 30th January, 2012 at 10:43:49 UTC by Miodrag Milanović
Fixed game info screen (no whatsnew)
[src/emu]ui.c

src/emu/ui.c
r14263r14264
10271027
10281028   /* loop over all CPUs */
10291029   execute_interface_iterator execiter(machine.root_device());
1030   tagmap_t<UINT8> exectags;
10301031   for (device_execute_interface *exec = execiter.first(); exec != NULL; exec = execiter.next())
10311032   {
1033      if (exectags.add(exec->device().tag(), 1, FALSE) == TMERR_DUPLICATE)
1034         continue;
10321035      /* get cpu specific clock that takes internal multiplier/dividers into account */
10331036      int clock = exec->device().clock();
10341037
10351038      /* count how many identical CPUs we have */
10361039      int count = 1;
1037      for (device_execute_interface *scan = execiter.next(); scan != NULL; scan = execiter.next())
1040      execute_interface_iterator execinneriter(machine.root_device());
1041      for (device_execute_interface *scan = execinneriter.first(); scan != NULL; scan = execinneriter.next())
10381042      {
1039         if (exec->device().type() != scan->device().type() || exec->device().clock() != scan->device().clock())
1040            break;
1041         count++;
1042         exec = scan;
1043         if (exec->device().type() == scan->device().type() && exec->device().clock() == scan->device().clock())
1044            if (exectags.add(scan->device().tag(), 1, FALSE) != TMERR_DUPLICATE)
1045               count++;
10431046      }
1044      execiter.set_current(*exec);
10451047
10461048      /* if more than one, prepend a #x in front of the CPU name */
10471049      if (count > 1)
r14263r14264
10571059
10581060   /* loop over all sound chips */
10591061   sound_interface_iterator snditer(machine.root_device());
1062   tagmap_t<UINT8> soundtags;
10601063   for (device_sound_interface *sound = snditer.first(); sound != NULL; sound = snditer.next())
10611064   {
1065      if (soundtags.add(sound->device().tag(), 1, FALSE) == TMERR_DUPLICATE)
1066         continue;
1067
10621068      /* append the Sound: string */
10631069      if (!found_sound)
10641070         string.cat("\nSound:\n");
r14263r14264
10661072
10671073      /* count how many identical sound chips we have */
10681074      int count = 1;
1069      for (device_sound_interface *scan = snditer.next(); scan != NULL; scan = snditer.next())
1075      sound_interface_iterator sndinneriter(machine.root_device());
1076      for (device_sound_interface *scan = sndinneriter.first(); scan != NULL; scan = sndinneriter.next())
10701077      {
1071         if (sound->device().type() != scan->device().type() || sound->device().clock() != scan->device().clock())
1072            break;
1073         count++;
1074         sound = scan;
1078         if (sound->device().type() == scan->device().type() && sound->device().clock() == scan->device().clock())
1079            if (soundtags.add(scan->device().tag(), 1, FALSE) != TMERR_DUPLICATE)
1080               count++;
10751081      }
1076      snditer.set_current(*sound);
1077
10781082      /* if more than one, prepend a #x in front of the CPU name */
10791083      if (count > 1)
10801084         string.catprintf("%d" UTF8_MULTIPLY, count);

Previous 15994 Revisions Next


© 1998-2018 The MESS Team