summaryrefslogtreecommitdiff
path: root/Source/Core/DebuggerWX/src/BreakPointDlg.cpp
diff options
context:
space:
mode:
authorfires.gc <fires.gc@gmail.com>2008-07-24 08:47:38 +0000
committerfires.gc <fires.gc@gmail.com>2008-07-24 08:47:38 +0000
commitdc717f7283bde539c534295eac0cedf8bb7c049d (patch)
treea473559072e6ae7e6c834cc8023779209858e168 /Source/Core/DebuggerWX/src/BreakPointDlg.cpp
parent185a214329df831bc21dfaddb98c7b3b9aff7427 (diff)
finished dialogs for memory checks and breakpoints
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@76 8ced0084-cf51-0410-be5f-012b33b47a6e
Diffstat (limited to 'Source/Core/DebuggerWX/src/BreakPointDlg.cpp')
-rw-r--r--Source/Core/DebuggerWX/src/BreakPointDlg.cpp24
1 files changed, 23 insertions, 1 deletions
diff --git a/Source/Core/DebuggerWX/src/BreakPointDlg.cpp b/Source/Core/DebuggerWX/src/BreakPointDlg.cpp
index 5c89669b77..c42271fdd1 100644
--- a/Source/Core/DebuggerWX/src/BreakPointDlg.cpp
+++ b/Source/Core/DebuggerWX/src/BreakPointDlg.cpp
@@ -16,10 +16,16 @@
// http://code.google.com/p/dolphin-emu/
#include "BreakPointDlg.h"
+#include "Common.h"
+#include "Debugger.h"
+#include "StringUtil.h"
+#include "Debugger/Debugger_BreakPoints.h"
BEGIN_EVENT_TABLE(BreakPointDlg,wxDialog)
EVT_CLOSE(BreakPointDlg::OnClose)
+ EVT_BUTTON(ID_OK, BreakPointDlg::OnOK)
+ EVT_BUTTON(ID_CANCEL, BreakPointDlg::OnCancel)
END_EVENT_TABLE()
@@ -51,7 +57,7 @@ void BreakPointDlg::CreateGUIControls()
m_pButtonCancel = new wxButton(this, ID_CANCEL, wxT("Cancel"), wxPoint(112,64), wxSize(73,25), 0, wxDefaultValidator, wxT("Cancel"));
m_pButtonCancel->SetFont(wxFont(8, wxSWISS, wxNORMAL,wxNORMAL, false, wxT("Tahoma")));
- m_pEditAddress = new wxTextCtrl(this, ID_ADDRESS, wxT("WxEdit1"), wxPoint(56,24), wxSize(197,20), 0, wxDefaultValidator, wxT("WxEdit1"));
+ m_pEditAddress = new wxTextCtrl(this, ID_ADDRESS, wxT("80000000"), wxPoint(56,24), wxSize(197,20), 0, wxDefaultValidator, wxT("WxEdit1"));
m_pEditAddress->SetFont(wxFont(8, wxSWISS, wxNORMAL,wxNORMAL, false, wxT("Tahoma")));
wxStaticBox* WxStaticBox1 = new wxStaticBox(this, ID_WXSTATICBOX1, wxT("Address"), wxPoint(0,0), wxSize(265,57));
@@ -63,3 +69,19 @@ void BreakPointDlg::OnClose(wxCloseEvent& /*event*/)
{
Destroy();
}
+
+void BreakPointDlg::OnOK(wxCommandEvent& /*event*/)
+{
+ wxString AddressString = m_pEditAddress->GetLineText(0);
+ u32 Address = 0;
+ if (AsciiToHex(AddressString.GetData(), Address))
+ {
+ CBreakPoints::AddBreakPoint(Address);
+ Close();
+ }
+}
+
+void BreakPointDlg::OnCancel(wxCommandEvent& /*event*/)
+{
+ Close();
+} \ No newline at end of file