From 75f03b4d8afca12129675c1c6f83b80002c0655d Mon Sep 17 00:00:00 2001 From: The Dax Date: Wed, 14 Aug 2013 08:55:31 -0400 Subject: [PATCH] NewUI: Don't init audio if sound is disabled. And remove some stray newlines. --- Core/System.cpp | 2 -- UI/GameSettingsScreen.cpp | 5 +++-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/Core/System.cpp b/Core/System.cpp index e7a4f547bb..34145f74e8 100644 --- a/Core/System.cpp +++ b/Core/System.cpp @@ -93,8 +93,6 @@ bool IsOnSeparateCPUThread() { } } - - bool CPU_NextState(CPUThreadState from, CPUThreadState to) { if (cpuThreadState == from) { cpuThreadState = to; diff --git a/UI/GameSettingsScreen.cpp b/UI/GameSettingsScreen.cpp index 9710d6c7bd..5e9f554112 100644 --- a/UI/GameSettingsScreen.cpp +++ b/UI/GameSettingsScreen.cpp @@ -331,8 +331,9 @@ void GameSettingsScreen::update(InputState &input) { UI::EventReturn GameSettingsScreen::OnBack(UI::EventParams &e) { screenManager()->finishDialog(this, DR_OK); - if(PSP_IsInited() && !IsAudioInitialised()) { - Audio_Init(); + if(g_Config.bEnableSound) { + if(PSP_IsInited() && !IsAudioInitialised()) + Audio_Init(); } return UI::EVENT_DONE;