diff options
| author | Mat M <mathew1800@gmail.com> | 2016-12-19 15:45:21 -0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2016-12-19 15:45:21 -0500 |
| commit | 4e405010a3601b0cad032da1fec6308732a8c52a (patch) | |
| tree | 1ab36752bd97531088efeb723a78cfdd3dc7debe /Source/Core/DolphinWX/Debugger/CodeWindowFunctions.cpp | |
| parent | b9dc73d9cdaa4f660ab5293ed0322d0849020dc4 (diff) | |
| parent | a6114bad34f85eae346d2c7eec8d2f35c1728cf9 (diff) | |
Merge pull request #4497 from sepalani/totaldb.csv
Import/Export signature files as CSV
Diffstat (limited to 'Source/Core/DolphinWX/Debugger/CodeWindowFunctions.cpp')
| -rw-r--r-- | Source/Core/DolphinWX/Debugger/CodeWindowFunctions.cpp | 39 |
1 files changed, 18 insertions, 21 deletions
diff --git a/Source/Core/DolphinWX/Debugger/CodeWindowFunctions.cpp b/Source/Core/DolphinWX/Debugger/CodeWindowFunctions.cpp index 745d40202f..c71f377b42 100644 --- a/Source/Core/DolphinWX/Debugger/CodeWindowFunctions.cpp +++ b/Source/Core/DolphinWX/Debugger/CodeWindowFunctions.cpp @@ -32,7 +32,7 @@ #include "Core/PowerPC/PPCSymbolDB.h" #include "Core/PowerPC/PowerPC.h" #include "Core/PowerPC/Profiler.h" -#include "Core/PowerPC/SignatureDB.h" +#include "Core/PowerPC/SignatureDB/SignatureDB.h" #include "DolphinWX/Debugger/BreakpointWindow.h" #include "DolphinWX/Debugger/CodeWindow.h" @@ -161,6 +161,9 @@ void CCodeWindow::OnProfilerMenu(wxCommandEvent& event) void CCodeWindow::OnSymbolsMenu(wxCommandEvent& event) { + static const wxString signature_selector = _("Dolphin Signature File (*.dsy)") + "|*.dsy|" + + _("Dolphin Signature CSV File (*.csv)") + "|*.csv|" + + wxGetTranslation(wxALL_FILES); Parent->ClearStatusBar(); if (!Core::IsRunning()) @@ -309,8 +312,7 @@ void CCodeWindow::OnSymbolsMenu(wxCommandEvent& event) std::string prefix(WxStrToStr(input_prefix.GetValue())); wxString path = wxFileSelector(_("Save signature as"), File::GetSysDirectory(), wxEmptyString, - wxEmptyString, _("Dolphin Signature File (*.dsy)") + - "|*.dsy|" + wxGetTranslation(wxALL_FILES), + wxEmptyString, signature_selector, wxFD_SAVE | wxFD_OVERWRITE_PROMPT, this); if (!path.IsEmpty()) { @@ -332,10 +334,9 @@ void CCodeWindow::OnSymbolsMenu(wxCommandEvent& event) { std::string prefix(WxStrToStr(input_prefix.GetValue())); - wxString path = wxFileSelector( - _("Append signature to"), File::GetSysDirectory(), wxEmptyString, wxEmptyString, - _("Dolphin Signature File (*.dsy)") + "|*.dsy|" + wxGetTranslation(wxALL_FILES), - wxFD_SAVE, this); + wxString path = + wxFileSelector(_("Append signature to"), File::GetSysDirectory(), wxEmptyString, + wxEmptyString, signature_selector, wxFD_SAVE, this); if (!path.IsEmpty()) { SignatureDB db; @@ -350,10 +351,9 @@ void CCodeWindow::OnSymbolsMenu(wxCommandEvent& event) break; case IDM_USE_SIGNATURE_FILE: { - wxString path = wxFileSelector( - _("Apply signature file"), File::GetSysDirectory(), wxEmptyString, wxEmptyString, - _("Dolphin Signature File (*.dsy)") + "|*.dsy|" + wxGetTranslation(wxALL_FILES), - wxFD_OPEN | wxFD_FILE_MUST_EXIST, this); + wxString path = + wxFileSelector(_("Apply signature file"), File::GetSysDirectory(), wxEmptyString, + wxEmptyString, signature_selector, wxFD_OPEN | wxFD_FILE_MUST_EXIST, this); if (!path.IsEmpty()) { SignatureDB db; @@ -366,25 +366,22 @@ void CCodeWindow::OnSymbolsMenu(wxCommandEvent& event) break; case IDM_COMBINE_SIGNATURE_FILES: { - wxString path1 = wxFileSelector( - _("Choose priority input file"), File::GetSysDirectory(), wxEmptyString, wxEmptyString, - _("Dolphin Signature File (*.dsy)") + "|*.dsy|" + wxGetTranslation(wxALL_FILES), - wxFD_OPEN | wxFD_FILE_MUST_EXIST, this); + wxString path1 = + wxFileSelector(_("Choose priority input file"), File::GetSysDirectory(), wxEmptyString, + wxEmptyString, signature_selector, wxFD_OPEN | wxFD_FILE_MUST_EXIST, this); if (!path1.IsEmpty()) { SignatureDB db; - wxString path2 = wxFileSelector( - _("Choose secondary input file"), File::GetSysDirectory(), wxEmptyString, wxEmptyString, - _("Dolphin Signature File (*.dsy)") + "|*.dsy|" + wxGetTranslation(wxALL_FILES), - wxFD_OPEN | wxFD_FILE_MUST_EXIST, this); + wxString path2 = + wxFileSelector(_("Choose secondary input file"), File::GetSysDirectory(), wxEmptyString, + wxEmptyString, signature_selector, wxFD_OPEN | wxFD_FILE_MUST_EXIST, this); if (!path2.IsEmpty()) { db.Load(WxStrToStr(path2)); db.Load(WxStrToStr(path1)); path2 = wxFileSelector(_("Save combined output file as"), File::GetSysDirectory(), - wxEmptyString, ".dsy", _("Dolphin Signature File (*.dsy)") + - "|*.dsy|" + wxGetTranslation(wxALL_FILES), + wxEmptyString, ".dsy", signature_selector, wxFD_SAVE | wxFD_OVERWRITE_PROMPT, this); db.Save(WxStrToStr(path2)); db.List(); |
