mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-06-16 12:58:33 +02:00
Revert "Audit uses of IsRunning and GetState"
This reverts commit 72cf2bdb87
.
SYSCONF settings are getting cleared when they shouldn't be. Let's
revert the change until I get proper time to figure out why it's broken.
This commit is contained in:
@ -59,14 +59,11 @@ FIFOPlayerWindow::FIFOPlayerWindow(FifoPlayer& fifo_player, FifoRecorder& fifo_r
|
||||
});
|
||||
|
||||
connect(&Settings::Instance(), &Settings::EmulationStateChanged, this, [this](Core::State state) {
|
||||
if (state != m_emu_state)
|
||||
{
|
||||
if (state == Core::State::Running && m_emu_state != Core::State::Paused)
|
||||
OnEmulationStarted();
|
||||
else if (state == Core::State::Uninitialized)
|
||||
OnEmulationStopped();
|
||||
m_emu_state = state;
|
||||
}
|
||||
if (state == Core::State::Running && m_emu_state != Core::State::Paused)
|
||||
OnEmulationStarted();
|
||||
else if (state == Core::State::Uninitialized)
|
||||
OnEmulationStopped();
|
||||
m_emu_state = state;
|
||||
});
|
||||
|
||||
installEventFilter(this);
|
||||
@ -379,11 +376,9 @@ void FIFOPlayerWindow::UpdateLimits()
|
||||
|
||||
void FIFOPlayerWindow::UpdateControls()
|
||||
{
|
||||
Core::System& system = Core::System::GetInstance();
|
||||
const bool core_is_uninitialized = Core::IsUninitialized(system);
|
||||
const bool core_is_running = Core::IsRunning(system);
|
||||
const bool is_recording = m_fifo_recorder.IsRecording();
|
||||
const bool is_playing = m_fifo_player.IsPlaying();
|
||||
bool running = Core::IsRunning(Core::System::GetInstance());
|
||||
bool is_recording = m_fifo_recorder.IsRecording();
|
||||
bool is_playing = m_fifo_player.IsPlaying();
|
||||
|
||||
m_frame_range_from->setEnabled(is_playing);
|
||||
m_frame_range_from_label->setEnabled(is_playing);
|
||||
@ -399,10 +394,10 @@ void FIFOPlayerWindow::UpdateControls()
|
||||
m_frame_record_count_label->setEnabled(enable_frame_record_count);
|
||||
m_frame_record_count->setEnabled(enable_frame_record_count);
|
||||
|
||||
m_load->setEnabled(core_is_uninitialized);
|
||||
m_record->setEnabled(core_is_running && !is_playing);
|
||||
m_load->setEnabled(!running);
|
||||
m_record->setEnabled(running && !is_playing);
|
||||
|
||||
m_stop->setVisible(core_is_running && is_recording);
|
||||
m_stop->setVisible(running && is_recording);
|
||||
m_record->setVisible(!m_stop->isVisible());
|
||||
|
||||
m_save->setEnabled(m_fifo_recorder.IsRecordingDone());
|
||||
|
Reference in New Issue
Block a user