Merge pull request #814 from lioncash/jitwindow

Core: Kill off Host_ShowJitResults
This commit is contained in:
Lioncash 2014-08-15 15:26:45 -04:00
commit 4c406cc4a1
11 changed files with 15 additions and 24 deletions

View File

@ -31,7 +31,6 @@ public:
virtual void RunToBreakpoint() {} virtual void RunToBreakpoint() {}
virtual void BreakNow() {} virtual void BreakNow() {}
virtual void InsertBLR(unsigned int /*address*/, unsigned int /*value*/) {} virtual void InsertBLR(unsigned int /*address*/, unsigned int /*value*/) {}
virtual void ShowJitResults(unsigned int /*address*/) {};
virtual int GetColor(unsigned int /*address*/){return 0xFFFFFFFF;} virtual int GetColor(unsigned int /*address*/){return 0xFFFFFFFF;}
virtual std::string GetDescription(unsigned int /*address*/) = 0; virtual std::string GetDescription(unsigned int /*address*/) = 0;
}; };

View File

@ -213,11 +213,6 @@ void PPCDebugInterface::SetPC(unsigned int address)
PowerPC::ppcState.pc = address; PowerPC::ppcState.pc = address;
} }
void PPCDebugInterface::ShowJitResults(unsigned int address)
{
Host_ShowJitResults(address);
}
void PPCDebugInterface::RunToBreakpoint() void PPCDebugInterface::RunToBreakpoint()
{ {

View File

@ -41,5 +41,4 @@ public:
virtual void InsertBLR(unsigned int address, unsigned int value) override; virtual void InsertBLR(unsigned int address, unsigned int value) override;
virtual int GetColor(unsigned int address) override; virtual int GetColor(unsigned int address) override;
virtual std::string GetDescription(unsigned int address) override; virtual std::string GetDescription(unsigned int address) override;
virtual void ShowJitResults(u32 address) override;
}; };

View File

@ -34,7 +34,6 @@ void Host_RequestRenderWindowSize(int width, int height);
void Host_RequestFullscreen(bool enable_fullscreen); void Host_RequestFullscreen(bool enable_fullscreen);
void Host_SetStartupDebuggingParameters(); void Host_SetStartupDebuggingParameters();
void Host_SetWiiMoteConnectionState(int _State); void Host_SetWiiMoteConnectionState(int _State);
void Host_ShowJitResults(unsigned int address);
void Host_SysMessage(const char *fmt, ...); void Host_SysMessage(const char *fmt, ...);
void Host_UpdateDisasmDialog(); void Host_UpdateDisasmDialog();
void Host_UpdateMainFrame(); void Host_UpdateMainFrame();

View File

@ -309,7 +309,12 @@ void CCodeView::OnPopupMenu(wxCommandEvent& event)
break; break;
case IDM_JITRESULTS: case IDM_JITRESULTS:
m_debugger->ShowJitResults(m_selection); {
// Propagate back to the parent window and tell it
// to flip to the JIT tab for the current address.
wxCommandEvent jit_event(wxEVT_HOST_COMMAND, IDM_UPDATEJITPANE);
GetEventHandler()->AddPendingEvent(jit_event);
}
break; break;
case IDM_FOLLOWBRANCH: case IDM_FOLLOWBRANCH:

View File

@ -49,6 +49,7 @@
#include "DolphinWX/Debugger/CodeView.h" #include "DolphinWX/Debugger/CodeView.h"
#include "DolphinWX/Debugger/CodeWindow.h" #include "DolphinWX/Debugger/CodeWindow.h"
#include "DolphinWX/Debugger/DebuggerUIUtil.h" #include "DolphinWX/Debugger/DebuggerUIUtil.h"
#include "DolphinWX/Debugger/JitWindow.h"
#include "DolphinWX/Debugger/RegisterWindow.h" #include "DolphinWX/Debugger/RegisterWindow.h"
extern "C" // Bitmaps extern "C" // Bitmaps
@ -156,6 +157,13 @@ void CCodeWindow::OnHostMessage(wxCommandEvent& event)
Update(); Update();
if (m_BreakpointWindow) m_BreakpointWindow->NotifyUpdate(); if (m_BreakpointWindow) m_BreakpointWindow->NotifyUpdate();
break; break;
case IDM_UPDATEJITPANE:
// Check if the JIT pane is in the AUI notebook. If not, add it and switch to it.
if (!m_JitWindow)
ToggleJitWindow(true);
m_JitWindow->ViewAddr(codeview->GetSelection());
break;
} }
} }

View File

@ -250,6 +250,7 @@ enum
IDM_UPDATESTATUSBAR, IDM_UPDATESTATUSBAR,
IDM_UPDATETITLE, IDM_UPDATETITLE,
IDM_UPDATEBREAKPOINTS, IDM_UPDATEBREAKPOINTS,
IDM_UPDATEJITPANE,
IDM_PANIC, IDM_PANIC,
IDM_KEYSTATE, IDM_KEYSTATE,
IDM_WINDOWSIZEREQUEST, IDM_WINDOWSIZEREQUEST,

View File

@ -553,16 +553,6 @@ void Host_UpdateDisasmDialog()
} }
} }
void Host_ShowJitResults(unsigned int address)
{
if (main_frame->g_pCodeWindow)
{
if (!main_frame->g_pCodeWindow->m_JitWindow)
main_frame->g_pCodeWindow->ToggleJitWindow(true);
main_frame->g_pCodeWindow->m_JitWindow->ViewAddr(address);
}
}
void Host_UpdateMainFrame() void Host_UpdateMainFrame()
{ {
wxCommandEvent event(wxEVT_HOST_COMMAND, IDM_UPDATEGUI); wxCommandEvent event(wxEVT_HOST_COMMAND, IDM_UPDATEGUI);

View File

@ -55,8 +55,6 @@ std::string g_filename;
void Host_NotifyMapLoaded() {} void Host_NotifyMapLoaded() {}
void Host_RefreshDSPDebuggerWindow() {} void Host_RefreshDSPDebuggerWindow() {}
void Host_ShowJitResults(unsigned int address){}
Common::Event updateMainFrameEvent; Common::Event updateMainFrameEvent;
void Host_Message(int Id) void Host_Message(int Id)
{ {

View File

@ -47,8 +47,6 @@ static bool running = true;
void Host_NotifyMapLoaded() {} void Host_NotifyMapLoaded() {}
void Host_RefreshDSPDebuggerWindow() {} void Host_RefreshDSPDebuggerWindow() {}
void Host_ShowJitResults(unsigned int address){}
static Common::Event updateMainFrameEvent; static Common::Event updateMainFrameEvent;
void Host_Message(int Id) void Host_Message(int Id)
{ {

View File

@ -12,7 +12,6 @@
void Host_NotifyMapLoaded() {} void Host_NotifyMapLoaded() {}
void Host_RefreshDSPDebuggerWindow() {} void Host_RefreshDSPDebuggerWindow() {}
void Host_ShowJitResults(unsigned int) {}
void Host_Message(int) {} void Host_Message(int) {}
void* Host_GetRenderHandle() { return nullptr; } void* Host_GetRenderHandle() { return nullptr; }
void Host_UpdateTitle(const std::string&) {} void Host_UpdateTitle(const std::string&) {}