GUI: Gray step button in JIT mode
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4192 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
parent
276a2da982
commit
f8ea1824b7
|
@ -581,29 +581,8 @@ void CCodeWindow::OnCPUMode(wxCommandEvent& event)
|
|||
|
||||
// Clear the JIT cache to enable these changes
|
||||
jit.ClearCache();
|
||||
}
|
||||
|
||||
|
||||
// Shortcuts
|
||||
bool CCodeWindow::UseInterpreter()
|
||||
{
|
||||
return GetMenuBar()->IsChecked(IDM_INTERPRETER);
|
||||
}
|
||||
bool CCodeWindow::BootToPause()
|
||||
{
|
||||
return GetMenuBar()->IsChecked(IDM_BOOTTOPAUSE);
|
||||
}
|
||||
bool CCodeWindow::AutomaticStart()
|
||||
{
|
||||
return GetMenuBar()->IsChecked(IDM_AUTOMATICSTART);
|
||||
}
|
||||
bool CCodeWindow::UnlimitedJITCache()
|
||||
{
|
||||
return GetMenuBar()->IsChecked(IDM_JITUNLIMITED);
|
||||
}
|
||||
bool CCodeWindow::JITBlockLinking()
|
||||
{
|
||||
return GetMenuBar()->IsChecked(IDM_JITBLOCKLINKING);
|
||||
// Update
|
||||
UpdateButtonStates();
|
||||
}
|
||||
void CCodeWindow::OnJitMenu(wxCommandEvent& event)
|
||||
{
|
||||
|
@ -630,6 +609,28 @@ void CCodeWindow::OnJitMenu(wxCommandEvent& event)
|
|||
}
|
||||
|
||||
|
||||
// Shortcuts
|
||||
bool CCodeWindow::UseInterpreter()
|
||||
{
|
||||
return GetMenuBar()->IsChecked(IDM_INTERPRETER);
|
||||
}
|
||||
bool CCodeWindow::BootToPause()
|
||||
{
|
||||
return GetMenuBar()->IsChecked(IDM_BOOTTOPAUSE);
|
||||
}
|
||||
bool CCodeWindow::AutomaticStart()
|
||||
{
|
||||
return GetMenuBar()->IsChecked(IDM_AUTOMATICSTART);
|
||||
}
|
||||
bool CCodeWindow::UnlimitedJITCache()
|
||||
{
|
||||
return GetMenuBar()->IsChecked(IDM_JITUNLIMITED);
|
||||
}
|
||||
bool CCodeWindow::JITBlockLinking()
|
||||
{
|
||||
return GetMenuBar()->IsChecked(IDM_JITBLOCKLINKING);
|
||||
}
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
// Toolbar
|
||||
|
@ -704,7 +705,6 @@ void CCodeWindow::UpdateButtonStates()
|
|||
if (!Initialized)
|
||||
{
|
||||
ToolBar->EnableTool(IDM_DEBUG_GO, false);
|
||||
ToolBar->EnableTool(IDM_STEP, false);
|
||||
ToolBar->EnableTool(IDM_STEPOVER, false);
|
||||
ToolBar->EnableTool(IDM_SKIP, false);
|
||||
}
|
||||
|
@ -716,7 +716,6 @@ void CCodeWindow::UpdateButtonStates()
|
|||
ToolBar->SetToolLabel(IDM_DEBUG_GO, _("Pause"));
|
||||
ToolBar->SetToolBitmap(IDM_DEBUG_GO, m_Bitmaps[Toolbar_DebugPause]);
|
||||
ToolBar->EnableTool(IDM_DEBUG_GO, true);
|
||||
ToolBar->EnableTool(IDM_STEP, false);
|
||||
ToolBar->EnableTool(IDM_STEPOVER, false);
|
||||
ToolBar->EnableTool(IDM_SKIP, false);
|
||||
}
|
||||
|
@ -726,11 +725,12 @@ void CCodeWindow::UpdateButtonStates()
|
|||
ToolBar->SetToolLabel(IDM_DEBUG_GO, _("Play"));
|
||||
ToolBar->SetToolBitmap(IDM_DEBUG_GO, m_Bitmaps[Toolbar_DebugGo]);
|
||||
ToolBar->EnableTool(IDM_DEBUG_GO, true);
|
||||
ToolBar->EnableTool(IDM_STEP, true);
|
||||
ToolBar->EnableTool(IDM_STEPOVER, true);
|
||||
ToolBar->EnableTool(IDM_SKIP, true);
|
||||
}
|
||||
}
|
||||
|
||||
ToolBar->EnableTool(IDM_STEP, Initialized && Stepping && UseInterpreter());
|
||||
|
||||
if (ToolBar) ToolBar->Realize();
|
||||
|
||||
|
|
Loading…
Reference in New Issue