summaryrefslogtreecommitdiff
path: root/Source/Core/DolphinWX/Debugger/CodeWindowFunctions.cpp
diff options
context:
space:
mode:
authorAnthony <Helios747@users.noreply.github.com>2016-12-17 11:13:28 -0600
committerGitHub <noreply@github.com>2016-12-17 11:13:28 -0600
commitf431b18675fc2df846a1d142c1d7a793bd1d1175 (patch)
tree77743cc29935d0720b69732606365b5fdded574b /Source/Core/DolphinWX/Debugger/CodeWindowFunctions.cpp
parentd64f56fb013946b8caf84aec5909b4b31801a221 (diff)
parent59abfee11d4a08e10a00f8db6c2bcc2476f5423a (diff)
Merge pull request #4491 from leoetlino/debugger-symbol-filter
DolphinWX: Add ability to filter symbols (by name)
Diffstat (limited to 'Source/Core/DolphinWX/Debugger/CodeWindowFunctions.cpp')
-rw-r--r--Source/Core/DolphinWX/Debugger/CodeWindowFunctions.cpp19
1 files changed, 14 insertions, 5 deletions
diff --git a/Source/Core/DolphinWX/Debugger/CodeWindowFunctions.cpp b/Source/Core/DolphinWX/Debugger/CodeWindowFunctions.cpp
index 3206721851..745d40202f 100644
--- a/Source/Core/DolphinWX/Debugger/CodeWindowFunctions.cpp
+++ b/Source/Core/DolphinWX/Debugger/CodeWindowFunctions.cpp
@@ -14,6 +14,7 @@
#include <wx/listbox.h>
#include <wx/menu.h>
#include <wx/mimetype.h>
+#include <wx/srchctrl.h>
#include <wx/textdlg.h>
#include "Common/CommonPaths.h"
@@ -398,20 +399,28 @@ void CCodeWindow::OnSymbolsMenu(wxCommandEvent& event)
}
}
-void CCodeWindow::NotifyMapLoaded()
+void CCodeWindow::ReloadSymbolListBox()
{
- if (!codeview)
- return;
-
- g_symbolDB.FillInCallers();
symbols->Freeze(); // HyperIris: wx style fast filling
symbols->Clear();
+ const wxString filtering_string = m_symbol_filter_ctrl->GetValue().Trim().Trim(false);
for (const auto& symbol : g_symbolDB.Symbols())
{
+ if (symbol.second.name.find(filtering_string) == std::string::npos)
+ continue;
int idx = symbols->Append(StrToWxStr(symbol.second.name));
symbols->SetClientData(idx, (void*)&symbol.second);
}
symbols->Thaw();
+}
+
+void CCodeWindow::NotifyMapLoaded()
+{
+ if (!codeview)
+ return;
+
+ g_symbolDB.FillInCallers();
+ ReloadSymbolListBox();
Repopulate();
}