Introduced a toggle_record_movie() method

This commit is contained in:
Nathan Woods 2014-02-02 13:13:59 +00:00
parent 0d0ae43b09
commit 8d5dea174a
3 changed files with 21 additions and 12 deletions

View File

@ -1590,18 +1590,7 @@ UINT32 ui_manager::handler_ingame(running_machine &machine, render_container *co
// toggle movie recording
if (ui_input_pressed(machine, IPT_UI_RECORD_MOVIE))
{
if (!machine.video().is_recording())
{
machine.video().begin_recording(NULL, video_manager::MF_MNG);
popmessage("REC START");
}
else
{
machine.video().end_recording();
popmessage("REC STOP");
}
}
machine.video().toggle_record_movie();
// toggle profiler display
if (ui_input_pressed(machine, IPT_UI_SHOW_PROFILER))

View File

@ -1285,3 +1285,22 @@ void video_manager::toggle_throttle()
{
set_throttle_rate(throttled() ? 0.0f : 1.0f);
}
//-------------------------------------------------
// toggle_record_movie
//-------------------------------------------------
void video_manager::toggle_record_movie()
{
if (!is_recording())
{
begin_recording(NULL, video_manager::MF_MNG);
popmessage("REC START");
}
else
{
end_recording();
popmessage("REC STOP");
}
}

View File

@ -74,6 +74,7 @@ public:
// misc
void toggle_throttle();
void toggle_record_movie();
// render a frame
void frame_update(bool debug = false);