summaryrefslogtreecommitdiffstats
path: root/src/frontend/mame/ui/selgame.cpp
diff options
context:
space:
mode:
author Vas Crabb <vas@vastheman.com>2016-07-05 11:16:05 +1000
committer Vas Crabb <vas@vastheman.com>2016-07-05 11:16:05 +1000
commit2c9dfd77ba8de267a204849fc258356c9172cdbc (patch)
treecb45bc747ec5c1bbb0db927a3113d336623926ed /src/frontend/mame/ui/selgame.cpp
parent09b6b311ff10e0c463420340da82172662c3e988 (diff)
Revert "C++ comments for some parts."
This reverts commit 19c4764090d1c5131945d11737de8a3bb421b9aa.
Diffstat (limited to 'src/frontend/mame/ui/selgame.cpp')
-rw-r--r--src/frontend/mame/ui/selgame.cpp42
1 files changed, 21 insertions, 21 deletions
diff --git a/src/frontend/mame/ui/selgame.cpp b/src/frontend/mame/ui/selgame.cpp
index 312beb85dbf..979902732a6 100644
--- a/src/frontend/mame/ui/selgame.cpp
+++ b/src/frontend/mame/ui/selgame.cpp
@@ -180,6 +180,9 @@ void menu_select_game::handle()
if (m_prev_selected == nullptr)
m_prev_selected = item[0].ref;
+ bool check_filter = false;
+ bool enabled_dats = ui().options().enabled_dats();
+
// if i have to load datfile, performe an hard reset
if (ui_globals::reset)
{
@@ -197,14 +200,11 @@ void menu_select_game::handle()
return;
}
- auto check_filter = false;
- auto enabled_dats = ui().options().enabled_dats();
-
// ignore pause keys by swallowing them before we process the menu
machine().ui_input().pressed(IPT_UI_PAUSE);
// process the menu
- auto menu_event = process(PROCESS_LR_REPEAT);
+ const event *menu_event = process(PROCESS_LR_REPEAT);
if (menu_event && menu_event->itemref)
{
if (ui_error)
@@ -257,7 +257,7 @@ void menu_select_game::handle()
// Infos
if (!isfavorite())
{
- auto drv = (const game_driver *)menu_event->itemref;
+ const game_driver *drv = (const game_driver *)menu_event->itemref;
if ((FPTR)drv > skip_main_items && ui_globals::curdats_view > UI_FIRST_LOAD)
{
ui_globals::curdats_view--;
@@ -266,7 +266,7 @@ void menu_select_game::handle()
}
else
{
- auto drv = (ui_software_info *)menu_event->itemref;
+ ui_software_info *drv = (ui_software_info *)menu_event->itemref;
if (drv->startempty == 1 && ui_globals::curdats_view > UI_FIRST_LOAD)
{
ui_globals::curdats_view--;
@@ -295,7 +295,7 @@ void menu_select_game::handle()
// Infos
if (!isfavorite())
{
- auto drv = (const game_driver *)menu_event->itemref;
+ const game_driver *drv = (const game_driver *)menu_event->itemref;
if ((FPTR)drv > skip_main_items && ui_globals::curdats_view < UI_LAST_LOAD)
{
ui_globals::curdats_view++;
@@ -304,7 +304,7 @@ void menu_select_game::handle()
}
else
{
- auto drv = (ui_software_info *)menu_event->itemref;
+ ui_software_info *drv = (ui_software_info *)menu_event->itemref;
if (drv->startempty == 1 && ui_globals::curdats_view < UI_LAST_LOAD)
{
ui_globals::curdats_view++;
@@ -349,14 +349,14 @@ void menu_select_game::handle()
// handle UI_DATS
if (!isfavorite())
{
- auto driver = (const game_driver *)menu_event->itemref;
+ const game_driver *driver = (const game_driver *)menu_event->itemref;
if ((FPTR)driver > skip_main_items && mame_machine_manager::instance()->datfile().has_data(driver))
menu::stack_push<menu_dats_view>(ui(), container, driver);
}
else
{
- auto ui_swinfo = (ui_software_info *)menu_event->itemref;
- auto mdat = mame_machine_manager::instance()->datfile();
+ ui_software_info *ui_swinfo = (ui_software_info *)menu_event->itemref;
+ datfile_manager &mdat = mame_machine_manager::instance()->datfile();
if ((FPTR)ui_swinfo > skip_main_items)
{
@@ -372,10 +372,10 @@ void menu_select_game::handle()
// handle UI_FAVORITES
if (!isfavorite())
{
- auto driver = (const game_driver *)menu_event->itemref;
+ const game_driver *driver = (const game_driver *)menu_event->itemref;
if ((FPTR)driver > skip_main_items)
{
- auto mfav = mame_machine_manager::instance()->favorite();
+ favorite_manager &mfav = mame_machine_manager::instance()->favorite();
if (!mfav.isgame_favorite(driver))
{
mfav.add_favorite_game(driver);
@@ -391,7 +391,7 @@ void menu_select_game::handle()
}
else
{
- auto swinfo = (ui_software_info *)menu_event->itemref;
+ ui_software_info *swinfo = (ui_software_info *)menu_event->itemref;
if ((FPTR)swinfo > skip_main_items)
{
machine().popmessage(_("%s\n removed from favorites list."), swinfo->longname.c_str());
@@ -632,7 +632,7 @@ void menu_select_game::populate()
void menu_select_game::build_available_list()
{
- auto m_total = driver_list::total();
+ int m_total = driver_list::total();
std::vector<bool> m_included(m_total, false);
// open a path to the ROMs and find them in the array
@@ -651,7 +651,7 @@ void menu_select_game::build_available_list()
*dst++ = tolower((UINT8) * src);
*dst = 0;
- auto drivnum = driver_list::find(drivername);
+ int drivnum = driver_list::find(drivername);
if (drivnum != -1 && !m_included[drivnum])
{
m_availsortedlist.push_back(&driver_list::driver(drivnum));
@@ -667,8 +667,8 @@ void menu_select_game::build_available_list()
auto driver = &driver_list::driver(x);
if (!m_included[x] && driver != &GAME_NAME(___empty))
{
- auto rom = driver->rom;
- auto noroms = true;
+ const rom_entry *rom = driver->rom;
+ bool noroms = true;
// check NO-DUMP
for (; !ROMENTRY_ISEND(rom) && noroms == true; ++rom)
@@ -754,9 +754,9 @@ void menu_select_game::custom_render(void *selectedref, float top, float bottom,
float width, maxwidth = origx2 - origx1;
std::string tempbuf[5];
rgb_t color = UI_BACKGROUND_COLOR;
- auto isstar = false;
- auto inifile = mame_machine_manager::instance()->inifile();
- auto tbarspace = ui().get_line_height();
+ bool isstar = false;
+ inifile_manager &inifile = mame_machine_manager::instance()->inifile();
+ float tbarspace = ui().get_line_height();
float text_size = 1.0f;
tempbuf[0] = string_format(_("%1$s %2$s ( %3$d / %4$d machines (%5$d BIOS) )"),