Be consistent about how we read and update the UI state variable

This commit is contained in:
Henrik Rydgard committed 2014-06-22 09:57:01 +02:00
1 parent b5435260b0
commit 6ec74ef99e
10 files changed
+30 -24

No files matched your search

+2 -2
View File
@@ -816,7 +816,7 @@ void CDisasm::SetDebugMode(bool _bDebug, bool switchPC)
HWND hDlg = m_hDlg;
// Update Dialog Windows
if (_bDebug && globalUIState == UISTATE_INGAME && PSP_IsInited())
if (_bDebug && GetUIState() == UISTATE_INGAME && PSP_IsInited())
{
Core_WaitInactive(TEMP_BREAKPOINT_WAIT_MS);
CBreakPoints::ClearTemporaryBreakPoints();
@@ -849,7 +849,7 @@ void CDisasm::SetDebugMode(bool _bDebug, bool switchPC)
{
updateThreadLabel(true);
if (globalUIState == UISTATE_INGAME && PSP_IsInited())
if (GetUIState() == UISTATE_INGAME && PSP_IsInited())
{
SetDlgItemText(m_hDlg, IDC_STOPGO, L"Stop");
EnableWindow( GetDlgItem(hDlg, IDC_STOPGO), TRUE);