Skip to content

Commit

Permalink
Merge pull request #376 from lioncash/wx
Browse files Browse the repository at this point in the history
Wx cleanup
  • Loading branch information
shuffle2 committed May 22, 2014
2 parents 7a7aa8c + 554207a commit c308657
Show file tree
Hide file tree
Showing 44 changed files with 541 additions and 553 deletions.
2 changes: 1 addition & 1 deletion Source/Core/DolphinWX/ARCodeAddEdit.cpp
Expand Up @@ -182,7 +182,7 @@ void CARCodeAddEdit::UpdateTextCtrl(ActionReplay::ARCode arCode)
if (arCode.name != "")
{
for (auto& op : arCode.ops)
EditCheatCode->AppendText(wxString::Format(wxT("%08X %08X\n"), op.cmd_addr, op.value));
EditCheatCode->AppendText(wxString::Format("%08X %08X\n", op.cmd_addr, op.value));
}
else
{
Expand Down
44 changes: 21 additions & 23 deletions Source/Core/DolphinWX/CheatsWindow.cpp
Expand Up @@ -88,8 +88,8 @@ void wxCheatsWindow::Init_ChildControls()
m_Tab_Cheats = new wxPanel(m_Notebook_Main, wxID_ANY);

m_CheckListBox_CheatsList = new wxCheckListBox(m_Tab_Cheats, wxID_ANY, wxDefaultPosition, wxSize(300, 0), m_CheatStringList, wxLB_HSCROLL, wxDefaultValidator);
m_CheckListBox_CheatsList->Bind(wxEVT_COMMAND_LISTBOX_SELECTED, &wxCheatsWindow::OnEvent_CheatsList_ItemSelected, this);
m_CheckListBox_CheatsList->Bind(wxEVT_COMMAND_CHECKLISTBOX_TOGGLED, &wxCheatsWindow::OnEvent_CheatsList_ItemToggled, this);
m_CheckListBox_CheatsList->Bind(wxEVT_LISTBOX, &wxCheatsWindow::OnEvent_CheatsList_ItemSelected, this);
m_CheckListBox_CheatsList->Bind(wxEVT_CHECKLISTBOX, &wxCheatsWindow::OnEvent_CheatsList_ItemToggled, this);

m_Label_Codename = new wxStaticText(m_Tab_Cheats, wxID_ANY, _("Name: "));
m_GroupBox_Info = new wxStaticBox(m_Tab_Cheats, wxID_ANY, _("Code Info"));
Expand All @@ -115,13 +115,13 @@ void wxCheatsWindow::Init_ChildControls()
m_Tab_Log = new wxPanel(m_Notebook_Main, wxID_ANY);

wxButton* const button_updatelog = new wxButton(m_Tab_Log, wxID_ANY, _("Update"));
button_updatelog->Bind(wxEVT_COMMAND_BUTTON_CLICKED, &wxCheatsWindow::OnEvent_ButtonUpdateLog_Press, this);
button_updatelog->Bind(wxEVT_BUTTON, &wxCheatsWindow::OnEvent_ButtonUpdateLog_Press, this);

m_CheckBox_LogAR = new wxCheckBox(m_Tab_Log, wxID_ANY, _("Enable AR Logging"));
m_CheckBox_LogAR->Bind(wxEVT_COMMAND_CHECKBOX_CLICKED, &wxCheatsWindow::OnEvent_CheckBoxEnableLogging_StateChange, this);
m_CheckBox_LogAR->Bind(wxEVT_CHECKBOX, &wxCheatsWindow::OnEvent_CheckBoxEnableLogging_StateChange, this);

m_CheckBox_LogAR->SetValue(ActionReplay::IsSelfLogging());
m_TextCtrl_Log = new wxTextCtrl(m_Tab_Log, wxID_ANY, wxT(""), wxDefaultPosition, wxSize(100, -1), wxTE_MULTILINE | wxTE_READONLY | wxTE_DONTWRAP);
m_TextCtrl_Log = new wxTextCtrl(m_Tab_Log, wxID_ANY, "", wxDefaultPosition, wxSize(100, -1), wxTE_MULTILINE | wxTE_READONLY | wxTE_DONTWRAP);

wxBoxSizer *HStrip1 = new wxBoxSizer(wxHORIZONTAL);
HStrip1->Add(m_CheckBox_LogAR, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5);
Expand All @@ -142,9 +142,9 @@ void wxCheatsWindow::Init_ChildControls()

// Button Strip
button_apply = new wxButton(panel, wxID_APPLY, _("Apply"));
button_apply->Bind(wxEVT_COMMAND_BUTTON_CLICKED, &wxCheatsWindow::OnEvent_ApplyChanges_Press, this);
button_apply->Bind(wxEVT_BUTTON, &wxCheatsWindow::OnEvent_ApplyChanges_Press, this);
wxButton* const button_cancel = new wxButton(panel, wxID_CANCEL, _("Cancel"));
button_cancel->Bind(wxEVT_COMMAND_BUTTON_CLICKED, &wxCheatsWindow::OnEvent_ButtonClose_Press, this);
button_cancel->Bind(wxEVT_BUTTON, &wxCheatsWindow::OnEvent_ButtonClose_Press, this);

Bind(wxEVT_CLOSE_WINDOW, &wxCheatsWindow::OnEvent_Close, this);

Expand All @@ -168,11 +168,11 @@ CheatSearchTab::CheatSearchTab(wxWindow* const parent)
{
// first scan button
btnInitScan = new wxButton(this, -1, _("New Scan"));
btnInitScan->Bind(wxEVT_COMMAND_BUTTON_CLICKED, &CheatSearchTab::StartNewSearch, this);
btnInitScan->Bind(wxEVT_BUTTON, &CheatSearchTab::StartNewSearch, this);

// next scan button
btnNextScan = new wxButton(this, -1, _("Next Scan"));
btnNextScan->Bind(wxEVT_COMMAND_BUTTON_CLICKED, &CheatSearchTab::FilterCheatSearchResults, this);
btnNextScan->Bind(wxEVT_BUTTON, &CheatSearchTab::FilterCheatSearchResults, this);
btnNextScan->Disable();

// data size radio buttons
Expand All @@ -193,7 +193,7 @@ CheatSearchTab::CheatSearchTab(wxWindow* const parent)

// create AR code button
wxButton* const button_cheat_search_copy_address = new wxButton(this, -1, _("Create AR Code"));
button_cheat_search_copy_address->Bind(wxEVT_COMMAND_BUTTON_CLICKED, &CheatSearchTab::CreateARCode, this);
button_cheat_search_copy_address->Bind(wxEVT_BUTTON, &CheatSearchTab::CreateARCode, this);

// results groupbox
wxStaticBoxSizer* const sizer_cheat_search_results = new wxStaticBoxSizer(wxVERTICAL, this, _("Results"));
Expand All @@ -203,11 +203,11 @@ CheatSearchTab::CheatSearchTab(wxWindow* const parent)

// Search value radio buttons
value_x_radiobtn.rad_oldvalue = new wxRadioButton(this, -1, _("Previous Value"), wxDefaultPosition, wxDefaultSize, wxRB_GROUP);
value_x_radiobtn.rad_uservalue = new wxRadioButton(this, -1, wxT(""));
value_x_radiobtn.rad_uservalue = new wxRadioButton(this, -1, "");
value_x_radiobtn.rad_oldvalue->SetValue(true);

// search value textbox
textctrl_value_x = new wxTextCtrl(this, -1, wxT("0x0"), wxDefaultPosition, wxSize(96,-1));
textctrl_value_x = new wxTextCtrl(this, -1, "0x0", wxDefaultPosition, wxSize(96,-1));
textctrl_value_x->Bind(wxEVT_SET_FOCUS, &CheatSearchTab::ApplyFocus, this);

wxBoxSizer* const sizer_cheat_filter_text = new wxBoxSizer(wxHORIZONTAL);
Expand Down Expand Up @@ -539,7 +539,7 @@ void CheatSearchTab::UpdateCheatSearchResultsList()
{
lbox_search_results->Clear();

wxString count_label = _("Count:") + wxString::Format(wxT(" %lu"),
wxString count_label = _("Count:") + wxString::Format(" %lu",
(unsigned long)search_results.size());
if (search_results.size() > MAX_CHEAT_SEARCH_RESULTS_DISPLAY)
{
Expand All @@ -566,12 +566,10 @@ void CheatSearchTab::UpdateCheatSearchResultsList()
// #elseif BIG_ENDIAN
// need to do some stuff in here (for 8 and 16bit) for bigendian
// #endif

static wxChar rowfmt[] = wxT("0x%08x 0x%0|x %u/%i");
rowfmt[14] = (wxChar)(wxT('0') + search_type_size*2);
std::string rowfmt = StringFromFormat("0x%%08x 0x%%0%ux %%u/%%i", search_type_size*2);

lbox_search_results->Append(
wxString::Format(rowfmt, result.address, display_value, display_value, display_value));
wxString::Format(rowfmt.c_str(), result.address, display_value, display_value, display_value));
}
}

Expand All @@ -598,11 +596,11 @@ CreateCodeDialog::CreateCodeDialog(wxWindow* const parent, const u32 address)
textctrl_name = new wxTextCtrl(this, -1, wxEmptyString, wxDefaultPosition, wxSize(256,-1));

wxStaticText* const label_code = new wxStaticText(this, -1, _("Code: "));
textctrl_code = new wxTextCtrl(this, -1, wxString::Format(wxT("0x%08x"), address));
textctrl_code = new wxTextCtrl(this, -1, wxString::Format("0x%08x", address));
textctrl_code->Disable();

wxStaticText* const label_value = new wxStaticText(this, -1, _("Value: "));
textctrl_value = new wxTextCtrl(this, -1, wxT("0"));
textctrl_value = new wxTextCtrl(this, -1, "0");

checkbox_use_hex = new wxCheckBox(this, -1, _("Use Hex"));
checkbox_use_hex->SetValue(true);
Expand All @@ -621,8 +619,8 @@ CreateCodeDialog::CreateCodeDialog(wxWindow* const parent, const u32 address)
sizer_main->Add(textctrl_value, 0, wxALL, 5);
sizer_main->Add(CreateButtonSizer(wxOK | wxCANCEL | wxNO_DEFAULT), 0, wxALL, 5);

Bind(wxEVT_COMMAND_BUTTON_CLICKED, &CreateCodeDialog::PressOK, this, wxID_OK);
Bind(wxEVT_COMMAND_BUTTON_CLICKED, &CreateCodeDialog::PressCancel, this, wxID_CANCEL);
Bind(wxEVT_BUTTON, &CreateCodeDialog::PressOK, this, wxID_OK);
Bind(wxEVT_BUTTON, &CreateCodeDialog::PressCancel, this, wxID_CANCEL);
Bind(wxEVT_CLOSE_WINDOW, &CreateCodeDialog::OnEvent_Close, this);

SetSizerAndFit(sizer_main);
Expand All @@ -647,8 +645,8 @@ void CreateCodeDialog::PressOK(wxCommandEvent& ev)
}

//wxString full_code = textctrl_code->GetValue();
//full_code += wxT(' ');
//full_code += wxString::Format(wxT("0x%08x"), code_value);
//full_code += ' ';
//full_code += wxString::Format("0x%08x", code_value);

// create the new code
ActionReplay::ARCode new_cheat;
Expand Down
57 changes: 28 additions & 29 deletions Source/Core/DolphinWX/ConfigMain.cpp
Expand Up @@ -121,7 +121,6 @@ static const wxLanguage langIds[] =
#define EXIDEV_AM_BB_STR _trans("AM-Baseboard")
#define EXIDEV_GECKO_STR "USBGecko"

#define WXSTR_TRANS(a) wxString(wxGetTranslation(wxT(a)))
#ifdef WIN32
//only used with xgettext to be picked up as translatable string.
//win32 does not have wx on its path, the provided wxALL_FILES
Expand Down Expand Up @@ -268,7 +267,7 @@ void CConfigMain::InitializeGUILists()
arrayStringFor_Framelimit.Add(_("Auto"));
arrayStringFor_Framelimit.Add(_("Audio"));
for (int i = 10; i <= 120; i += 5) // from 10 to 120
arrayStringFor_Framelimit.Add(wxString::Format(wxT("%i"), i));
arrayStringFor_Framelimit.Add(wxString::Format("%i", i));

// Emulator Engine
for (const CPUCore& CPUCores_a : CPUCores)
Expand All @@ -295,8 +294,8 @@ void CConfigMain::InitializeGUILists()
arrayStringFor_WiiSensBarPos.Add(_("Top"));

// Aspect ratio
arrayStringFor_WiiAspectRatio.Add(wxT("4:3"));
arrayStringFor_WiiAspectRatio.Add(wxT("16:9"));
arrayStringFor_WiiAspectRatio.Add("4:3");
arrayStringFor_WiiAspectRatio.Add("16:9");

// Wii Language arrayStrings
arrayStringFor_WiiSystemLang = arrayStringFor_GCSystemLang;
Expand Down Expand Up @@ -375,7 +374,7 @@ void CConfigMain::InitializeGUIValues()
// Audio
VolumeSlider->Enable(SupportsVolumeChanges(SConfig::GetInstance().sBackend));
VolumeSlider->SetValue(SConfig::GetInstance().m_Volume);
VolumeText->SetLabel(wxString::Format(wxT("%d %%"), SConfig::GetInstance().m_Volume));
VolumeText->SetLabel(wxString::Format("%d %%", SConfig::GetInstance().m_Volume));
DSPThread->SetValue(startup_params.bDSPThread);
DumpAudio->SetValue(SConfig::GetInstance().m_DumpAudio ? true : false);
DPL2Decoder->Enable(std::string(SConfig::GetInstance().sBackend) == BACKEND_OPENAL);
Expand Down Expand Up @@ -629,7 +628,7 @@ void CConfigMain::CreateGUIControls()
theme_selection->SetStringSelection(StrToWxStr(SConfig::GetInstance().m_LocalCoreStartupParameter.theme_name));

// std::function = avoid error on msvc
theme_selection->Bind(wxEVT_COMMAND_CHOICE_SELECTED, std::function<void(wxEvent&)>([theme_selection](wxEvent&)
theme_selection->Bind(wxEVT_CHOICE, std::function<void(wxEvent&)>([theme_selection](wxEvent&)
{
SConfig::GetInstance().m_LocalCoreStartupParameter.theme_name = WxStrToStr(theme_selection->GetStringSelection());
main_frame->InitBitmaps();
Expand Down Expand Up @@ -658,11 +657,11 @@ void CConfigMain::CreateGUIControls()
DumpAudio = new wxCheckBox(AudioPage, ID_DUMP_AUDIO, _("Dump Audio"));
DPL2Decoder = new wxCheckBox(AudioPage, ID_DPL2DECODER, _("Dolby Pro Logic II decoder"));
VolumeSlider = new wxSlider(AudioPage, ID_VOLUME, 0, 1, 100, wxDefaultPosition, wxDefaultSize, wxSL_VERTICAL|wxSL_INVERSE);
VolumeText = new wxStaticText(AudioPage, wxID_ANY, wxT(""));
VolumeText = new wxStaticText(AudioPage, wxID_ANY, "");
BackendSelection = new wxChoice(AudioPage, ID_BACKEND, wxDefaultPosition, wxDefaultSize, wxArrayBackends, 0, wxDefaultValidator, wxEmptyString);
Latency = new wxSpinCtrl(AudioPage, ID_LATENCY, "", wxDefaultPosition, wxDefaultSize, wxSP_ARROW_KEYS, 0, 30);

Latency->Bind(wxEVT_COMMAND_SPINCTRL_UPDATED, &CConfigMain::AudioSettingsChanged, this);
Latency->Bind(wxEVT_SPINCTRL, &CConfigMain::AudioSettingsChanged, this);

if (Core::GetState() != Core::CORE_UNINITIALIZED)
{
Expand Down Expand Up @@ -709,13 +708,13 @@ void CConfigMain::CreateGUIControls()
wxStaticText* GCEXIDeviceText[3];
GCEXIDeviceText[0] = TEXT_BOX(GamecubePage, _("Slot A"));
GCEXIDeviceText[1] = TEXT_BOX(GamecubePage, _("Slot B"));
GCEXIDeviceText[2] = TEXT_BOX(GamecubePage, wxT("SP1"));
GCEXIDeviceText[2] = TEXT_BOX(GamecubePage, "SP1");
GCEXIDevice[0] = new wxChoice(GamecubePage, ID_GC_EXIDEVICE_SLOTA);
GCEXIDevice[1] = new wxChoice(GamecubePage, ID_GC_EXIDEVICE_SLOTB);
GCEXIDevice[2] = new wxChoice(GamecubePage, ID_GC_EXIDEVICE_SP1);
GCMemcardPath[0] = new wxButton(GamecubePage, ID_GC_EXIDEVICE_SLOTA_PATH, wxT("..."),
GCMemcardPath[0] = new wxButton(GamecubePage, ID_GC_EXIDEVICE_SLOTA_PATH, "...",
wxDefaultPosition, wxDefaultSize, wxBU_EXACTFIT);
GCMemcardPath[1] = new wxButton(GamecubePage, ID_GC_EXIDEVICE_SLOTB_PATH, wxT("..."),
GCMemcardPath[1] = new wxButton(GamecubePage, ID_GC_EXIDEVICE_SLOTB_PATH, "...",
wxDefaultPosition, wxDefaultSize, wxBU_EXACTFIT);

//SI Devices
Expand Down Expand Up @@ -810,11 +809,11 @@ void CConfigMain::CreateGUIControls()
RemoveISOPath->Enable(false);

DefaultISO = new wxFilePickerCtrl(PathsPage, ID_DEFAULTISO, wxEmptyString, _("Choose a default ISO:"),
_("All GC/Wii images (gcm, iso, wbfs, ciso, gcz)") + wxString::Format(wxT("|*.gcm;*.iso;*.wbfs;*.ciso;*.gcz|%s"), wxGetTranslation(wxALL_FILES)),
_("All GC/Wii images (gcm, iso, wbfs, ciso, gcz)") + wxString::Format("|*.gcm;*.iso;*.wbfs;*.ciso;*.gcz|%s", wxGetTranslation(wxALL_FILES)),
wxDefaultPosition, wxDefaultSize, wxFLP_USE_TEXTCTRL|wxFLP_OPEN);
DVDRoot = new wxDirPickerCtrl(PathsPage, ID_DVDROOT, wxEmptyString, _("Choose a DVD root directory:"), wxDefaultPosition, wxDefaultSize, wxDIRP_USE_TEXTCTRL);
ApploaderPath = new wxFilePickerCtrl(PathsPage, ID_APPLOADERPATH, wxEmptyString, _("Choose file to use as apploader: (applies to discs constructed from directories only)"),
_("apploader (.img)") + wxString::Format(wxT("|*.img|%s"), wxGetTranslation(wxALL_FILES)),
_("apploader (.img)") + wxString::Format("|*.img|%s", wxGetTranslation(wxALL_FILES)),
wxDefaultPosition, wxDefaultSize, wxFLP_USE_TEXTCTRL|wxFLP_OPEN);
NANDRoot = new wxDirPickerCtrl(PathsPage, ID_NANDROOT, wxEmptyString, _("Choose a NAND root directory:"), wxDefaultPosition, wxDefaultSize, wxDIRP_USE_TEXTCTRL);

Expand Down Expand Up @@ -954,7 +953,7 @@ void CConfigMain::AudioSettingsChanged(wxCommandEvent& event)
case ID_VOLUME:
SConfig::GetInstance().m_Volume = VolumeSlider->GetValue();
AudioCommon::UpdateSoundStream();
VolumeText->SetLabel(wxString::Format(wxT("%d %%"), VolumeSlider->GetValue()));
VolumeText->SetLabel(wxString::Format("%d %%", VolumeSlider->GetValue()));
break;

case ID_DSPTHREAD:
Expand Down Expand Up @@ -1056,9 +1055,9 @@ void CConfigMain::ChooseMemcardPath(std::string& strMemcard, bool isSlotA)
std::string filename = WxStrToStr(wxFileSelector(
_("Choose a file to open"),
StrToWxStr(File::GetUserPath(D_GCUSER_IDX)),
isSlotA ? wxT(GC_MEMCARDA) : wxT(GC_MEMCARDB),
isSlotA ? GC_MEMCARDA : GC_MEMCARDB,
wxEmptyString,
_("Gamecube Memory Cards (*.raw,*.gcp)") + wxString(wxT("|*.raw;*.gcp"))));
_("Gamecube Memory Cards (*.raw,*.gcp)") + "|*.raw;*.gcp"));

if (!filename.empty())
{
Expand Down Expand Up @@ -1112,17 +1111,17 @@ void CConfigMain::ChooseMemcardPath(std::string& strMemcard, bool isSlotA)
void CConfigMain::ChooseSIDevice(wxString deviceName, int deviceNum)
{
SIDevices tempType;
if (!deviceName.compare(WXSTR_TRANS(SIDEV_STDCONT_STR)))
if (!deviceName.compare(_(SIDEV_STDCONT_STR)))
tempType = SIDEVICE_GC_CONTROLLER;
else if (!deviceName.compare(WXSTR_TRANS(SIDEV_STEERING_STR)))
else if (!deviceName.compare(_(SIDEV_STEERING_STR)))
tempType = SIDEVICE_GC_STEERING;
else if (!deviceName.compare(WXSTR_TRANS(SIDEV_DANCEMAT_STR)))
else if (!deviceName.compare(_(SIDEV_DANCEMAT_STR)))
tempType = SIDEVICE_DANCEMAT;
else if (!deviceName.compare(WXSTR_TRANS(SIDEV_BONGO_STR)))
else if (!deviceName.compare(_(SIDEV_BONGO_STR)))
tempType = SIDEVICE_GC_TARUKONGA;
else if (!deviceName.compare(wxT(SIDEV_GBA_STR)))
else if (!deviceName.compare(SIDEV_GBA_STR))
tempType = SIDEVICE_GC_GBA;
else if (!deviceName.compare(WXSTR_TRANS(SIDEV_AM_BB_STR)))
else if (!deviceName.compare(_(SIDEV_AM_BB_STR)))
tempType = SIDEVICE_AM_BASEBOARD;
else
tempType = SIDEVICE_NONE;
Expand All @@ -1140,17 +1139,17 @@ void CConfigMain::ChooseEXIDevice(wxString deviceName, int deviceNum)
{
TEXIDevices tempType;

if (!deviceName.compare(WXSTR_TRANS(EXIDEV_MEMCARD_STR)))
if (!deviceName.compare(_(EXIDEV_MEMCARD_STR)))
tempType = EXIDEVICE_MEMORYCARD;
else if (!deviceName.compare(WXSTR_TRANS(EXIDEV_MIC_STR)))
else if (!deviceName.compare(_(EXIDEV_MIC_STR)))
tempType = EXIDEVICE_MIC;
else if (!deviceName.compare(wxT(EXIDEV_BBA_STR)))
else if (!deviceName.compare(EXIDEV_BBA_STR))
tempType = EXIDEVICE_ETH;
else if (!deviceName.compare(WXSTR_TRANS(EXIDEV_AM_BB_STR)))
else if (!deviceName.compare(_(EXIDEV_AM_BB_STR)))
tempType = EXIDEVICE_AM_BASEBOARD;
else if (!deviceName.compare(wxT(EXIDEV_GECKO_STR)))
else if (!deviceName.compare(EXIDEV_GECKO_STR))
tempType = EXIDEVICE_GECKO;
else if (!deviceName.compare(WXSTR_TRANS(DEV_NONE_STR)))
else if (!deviceName.compare(_(DEV_NONE_STR)))
tempType = EXIDEVICE_NONE;
else
tempType = EXIDEVICE_DUMMY;
Expand Down Expand Up @@ -1199,7 +1198,7 @@ void CConfigMain::WiiSettingsChanged(wxCommandEvent& event)
u8 country_code = GetSADRCountryCode(wii_system_lang);
if (!SConfig::GetInstance().m_SYSCONF->SetArrayData("IPL.SADR", &country_code, 1))
{
PanicAlert("Failed to update country code in SYSCONF");
PanicAlertT("Failed to update country code in SYSCONF");
}
break;
}
Expand Down
6 changes: 3 additions & 3 deletions Source/Core/DolphinWX/Debugger/BreakpointDlg.cpp
Expand Up @@ -25,10 +25,10 @@ BEGIN_EVENT_TABLE(BreakPointDlg, wxDialog)
END_EVENT_TABLE()

BreakPointDlg::BreakPointDlg(CBreakPointWindow *_Parent)
: wxDialog(_Parent, wxID_ANY, wxT("BreakPoint"))
: wxDialog(_Parent, wxID_ANY, _("Add Breakpoint"))
, Parent(_Parent)
{
m_pEditAddress = new wxTextCtrl(this, wxID_ANY, wxT("80000000"));
m_pEditAddress = new wxTextCtrl(this, wxID_ANY, "80000000");

wxBoxSizer *sMainSizer = new wxBoxSizer(wxVERTICAL);
sMainSizer->Add(m_pEditAddress, 0, wxEXPAND | wxALL, 5);
Expand All @@ -50,7 +50,7 @@ void BreakPointDlg::OnOK(wxCommandEvent& event)
}
else
{
PanicAlert("The address %s is invalid.", WxStrToStr(AddressString).c_str());
PanicAlertT("The address %s is invalid.", WxStrToStr(AddressString).c_str());
}

event.Skip();
Expand Down
10 changes: 5 additions & 5 deletions Source/Core/DolphinWX/Debugger/BreakpointView.cpp
Expand Up @@ -36,11 +36,11 @@ void CBreakPointView::Update()
{
ClearAll();

InsertColumn(0, wxT("Active"));
InsertColumn(1, wxT("Type"));
InsertColumn(2, wxT("Function"));
InsertColumn(3, wxT("Address"));
InsertColumn(4, wxT("Flags"));
InsertColumn(0, _("Active"));
InsertColumn(1, _("Type"));
InsertColumn(2, _("Function"));
InsertColumn(3, _("Address"));
InsertColumn(4, _("Flags"));

char szBuffer[64];
const BreakPoints::TBreakPoints& rBreakPoints = PowerPC::breakpoints.GetBreakPoints();
Expand Down
24 changes: 12 additions & 12 deletions Source/Core/DolphinWX/Debugger/BreakpointWindow.cpp
Expand Up @@ -49,27 +49,27 @@ class CBreakPointBar : public wxAuiToolBar
m_Bitmaps[Toolbar_Add_BP] = wxBitmap(wxGetBitmapFromMemory(toolbar_add_breakpoint_png).ConvertToImage().Rescale(24, 24));
m_Bitmaps[Toolbar_Add_MC] = wxBitmap(wxGetBitmapFromMemory(toolbar_add_memcheck_png).ConvertToImage().Rescale(24, 24));

AddTool(ID_DELETE, wxT("Delete"), m_Bitmaps[Toolbar_Delete]);
Bind(wxEVT_COMMAND_TOOL_CLICKED, &CBreakPointWindow::OnDelete, parent, ID_DELETE);
AddTool(ID_DELETE, _("Delete"), m_Bitmaps[Toolbar_Delete]);
Bind(wxEVT_TOOL, &CBreakPointWindow::OnDelete, parent, ID_DELETE);

AddTool(ID_CLEAR, wxT("Clear"), m_Bitmaps[Toolbar_Delete]);
Bind(wxEVT_COMMAND_TOOL_CLICKED, &CBreakPointWindow::OnClear, parent, ID_CLEAR);
AddTool(ID_CLEAR, _("Clear"), m_Bitmaps[Toolbar_Delete]);
Bind(wxEVT_TOOL, &CBreakPointWindow::OnClear, parent, ID_CLEAR);

AddTool(ID_ADDBP, wxT("+BP"), m_Bitmaps[Toolbar_Add_BP]);
Bind(wxEVT_COMMAND_TOOL_CLICKED, &CBreakPointWindow::OnAddBreakPoint, parent, ID_ADDBP);
AddTool(ID_ADDBP, "+BP", m_Bitmaps[Toolbar_Add_BP]);
Bind(wxEVT_TOOL, &CBreakPointWindow::OnAddBreakPoint, parent, ID_ADDBP);

// Add memory breakpoints if you can use them
if (Memory::AreMemoryBreakpointsActivated())
{
AddTool(ID_ADDMC, wxT("+MC"), m_Bitmaps[Toolbar_Add_MC]);
Bind(wxEVT_COMMAND_TOOL_CLICKED, &CBreakPointWindow::OnAddMemoryCheck, parent, ID_ADDMC);
AddTool(ID_ADDMC, "+MC", m_Bitmaps[Toolbar_Add_MC]);
Bind(wxEVT_TOOL, &CBreakPointWindow::OnAddMemoryCheck, parent, ID_ADDMC);
}

AddTool(ID_LOAD, wxT("Load"), m_Bitmaps[Toolbar_Delete]);
Bind(wxEVT_COMMAND_TOOL_CLICKED, &CBreakPointWindow::LoadAll, parent, ID_LOAD);
AddTool(ID_LOAD, _("Load"), m_Bitmaps[Toolbar_Delete]);
Bind(wxEVT_TOOL, &CBreakPointWindow::LoadAll, parent, ID_LOAD);

AddTool(ID_SAVE, wxT("Save"), m_Bitmaps[Toolbar_Delete]);
Bind(wxEVT_COMMAND_TOOL_CLICKED, &CBreakPointWindow::Event_SaveAll, parent, ID_SAVE);
AddTool(ID_SAVE, _("Save"), m_Bitmaps[Toolbar_Delete]);
Bind(wxEVT_TOOL, &CBreakPointWindow::Event_SaveAll, parent, ID_SAVE);
}

private:
Expand Down

0 comments on commit c308657

Please sign in to comment.