DBG+BRIDGE+GUI: more performance improvements related to GuiSetDebugState
This commit is contained in:
parent
09c80658ec
commit
aa2a4afb0f
|
@ -1055,7 +1055,12 @@ BRIDGE_IMPEXP void GuiDisasmAt(duint addr, duint cip)
|
|||
|
||||
BRIDGE_IMPEXP void GuiSetDebugState(DBGSTATE state)
|
||||
{
|
||||
_gui_sendmessage(GUI_SET_DEBUG_STATE, (void*)state, 0);
|
||||
_gui_sendmessage(GUI_SET_DEBUG_STATE, (void*)state, (void*)false);
|
||||
}
|
||||
|
||||
BRIDGE_IMPEXP void GuiSetDebugStateFast(DBGSTATE state)
|
||||
{
|
||||
_gui_sendmessage(GUI_SET_DEBUG_STATE, (void*)state, (void*)true);
|
||||
}
|
||||
|
||||
BRIDGE_IMPEXP void GuiAddLogMessage(const char* msg)
|
||||
|
|
|
@ -1064,6 +1064,7 @@ typedef struct _TYPEDESCRIPTOR
|
|||
BRIDGE_IMPEXP const char* GuiTranslateText(const char* Source);
|
||||
BRIDGE_IMPEXP void GuiDisasmAt(duint addr, duint cip);
|
||||
BRIDGE_IMPEXP void GuiSetDebugState(DBGSTATE state);
|
||||
BRIDGE_IMPEXP void GuiSetDebugStateFast(DBGSTATE state);
|
||||
BRIDGE_IMPEXP void GuiAddLogMessage(const char* msg);
|
||||
BRIDGE_IMPEXP void GuiLogClear();
|
||||
BRIDGE_IMPEXP void GuiUpdateAllViews();
|
||||
|
|
|
@ -639,7 +639,8 @@ void DebugUpdateGui(duint disasm_addr, bool stack)
|
|||
|
||||
void GuiSetDebugStateAsync(DBGSTATE state)
|
||||
{
|
||||
static TaskThread_<decltype(&GuiSetDebugState), DBGSTATE> GuiSetDebugStateTask(&GuiSetDebugState);
|
||||
GuiSetDebugStateFast(state);
|
||||
static TaskThread_<decltype(&GuiSetDebugState), DBGSTATE> GuiSetDebugStateTask(&GuiSetDebugState, 300);
|
||||
GuiSetDebugStateTask.WakeUp(state);
|
||||
}
|
||||
|
||||
|
@ -652,7 +653,7 @@ void DebugUpdateGuiAsync(duint disasm_addr, bool stack)
|
|||
void DebugUpdateGuiSetStateAsync(duint disasm_addr, bool stack, DBGSTATE state)
|
||||
{
|
||||
// call paused routine to clean up various tracing states.
|
||||
if(state == DBGSTATE::paused)
|
||||
if(state == paused)
|
||||
cbDebuggerPaused();
|
||||
GuiSetDebugStateAsync(state);
|
||||
DebugUpdateGuiAsync(disasm_addr, stack);
|
||||
|
|
|
@ -104,6 +104,7 @@ void* Bridge::processMessage(GUIMSG type, void* param1, void* param2)
|
|||
|
||||
case GUI_SET_DEBUG_STATE:
|
||||
mIsRunning = DBGSTATE(duint(param1)) == running;
|
||||
if(!param2)
|
||||
emit dbgStateChanged((DBGSTATE)(dsint)param1);
|
||||
break;
|
||||
|
||||
|
|
|
@ -19,12 +19,12 @@ NotesManager::NotesManager(QWidget* parent) : QTabWidget(parent)
|
|||
|
||||
void NotesManager::dbgStateChangedSlot(DBGSTATE state)
|
||||
{
|
||||
if(state == DBGSTATE::initialized)
|
||||
if(state == initialized)
|
||||
{
|
||||
mDebuggee->show();
|
||||
addTab(mDebuggee, tr("Debuggee"));
|
||||
}
|
||||
else if(state == DBGSTATE::stopped)
|
||||
else if(state == stopped)
|
||||
{
|
||||
mDebuggee->hide();
|
||||
removeTab(1);
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
SymbolView::SymbolView(QWidget* parent) : QWidget(parent), ui(new Ui::SymbolView)
|
||||
{
|
||||
ui->setupUi(this);
|
||||
setAutoFillBackground(false);
|
||||
|
||||
// Set main layout
|
||||
mMainLayout = new QVBoxLayout;
|
||||
|
|
Loading…
Reference in New Issue