DolphinWX: Eliminate most usages of event tables in the debugger.

Moves things over to Bind.
This commit is contained in:
Lioncash 2014-11-05 22:19:52 -05:00
parent be386e974b
commit ee22d091a0
24 changed files with 81 additions and 171 deletions

View File

@ -21,14 +21,12 @@
#include "DolphinWX/Debugger/BreakpointDlg.h"
#include "DolphinWX/Debugger/BreakpointWindow.h"
BEGIN_EVENT_TABLE(BreakPointDlg, wxDialog)
EVT_BUTTON(wxID_OK, BreakPointDlg::OnOK)
END_EVENT_TABLE()
BreakPointDlg::BreakPointDlg(CBreakPointWindow *_Parent)
: wxDialog(_Parent, wxID_ANY, _("Add Breakpoint"))
, Parent(_Parent)
{
Bind(wxEVT_BUTTON, &BreakPointDlg::OnOK, this, wxID_OK);
m_pEditAddress = new wxTextCtrl(this, wxID_ANY, "80000000");
wxBoxSizer *sMainSizer = new wxBoxSizer(wxVERTICAL);

View File

@ -20,6 +20,4 @@ private:
wxTextCtrl *m_pEditAddress;
void OnOK(wxCommandEvent& event);
DECLARE_EVENT_TABLE();
};

View File

@ -96,21 +96,19 @@ private:
wxBitmap m_Bitmaps[Num_Bitmaps];
};
BEGIN_EVENT_TABLE(CBreakPointWindow, wxPanel)
EVT_CLOSE(CBreakPointWindow::OnClose)
EVT_LIST_ITEM_SELECTED(wxID_ANY, CBreakPointWindow::OnSelectBP)
END_EVENT_TABLE()
CBreakPointWindow::CBreakPointWindow(CCodeWindow* _pCodeWindow, wxWindow* parent,
wxWindowID id, const wxString& title, const wxPoint& position,
const wxSize& size, long style)
: wxPanel(parent, id, position, size, style, title)
, m_pCodeWindow(_pCodeWindow)
{
Bind(wxEVT_CLOSE_WINDOW, &CBreakPointWindow::OnClose, this);
m_mgr.SetManagedWindow(this);
m_mgr.SetFlags(wxAUI_MGR_DEFAULT | wxAUI_MGR_LIVE_RESIZE);
m_BreakPointListView = new CBreakPointView(this, wxID_ANY);
m_BreakPointListView->Bind(wxEVT_LIST_ITEM_SELECTED, &CBreakPointWindow::OnSelectBP, this);
m_mgr.AddPane(new CBreakPointBar(this, wxID_ANY), wxAuiPaneInfo().ToolbarPane().Top().
LeftDockable(true).RightDockable(true).BottomDockable(false).Floatable(false));

View File

@ -43,8 +43,6 @@ public:
void LoadAll();
private:
DECLARE_EVENT_TABLE();
wxAuiManager m_mgr;
CBreakPointView* m_BreakPointListView;
CCodeWindow* m_pCodeWindow;

View File

@ -58,19 +58,6 @@ enum
IDM_ADDFUNCTION,
};
BEGIN_EVENT_TABLE(CCodeView, wxControl)
EVT_ERASE_BACKGROUND(CCodeView::OnErase)
EVT_PAINT(CCodeView::OnPaint)
EVT_MOUSEWHEEL(CCodeView::OnScrollWheel)
EVT_LEFT_DOWN(CCodeView::OnMouseDown)
EVT_LEFT_UP(CCodeView::OnMouseUpL)
EVT_MOTION(CCodeView::OnMouseMove)
EVT_RIGHT_DOWN(CCodeView::OnMouseDown)
EVT_RIGHT_UP(CCodeView::OnMouseUpR)
EVT_MENU(-1, CCodeView::OnPopupMenu)
EVT_SIZE(CCodeView::OnResize)
END_EVENT_TABLE()
CCodeView::CCodeView(DebugInterface* debuginterface, SymbolDB *symboldb,
wxWindow* parent, wxWindowID Id)
: wxControl(parent, Id),
@ -86,6 +73,16 @@ CCodeView::CCodeView(DebugInterface* debuginterface, SymbolDB *symboldb,
m_lx(-1),
m_ly(-1)
{
Bind(wxEVT_ERASE_BACKGROUND, &CCodeView::OnErase, this);
Bind(wxEVT_PAINT, &CCodeView::OnPaint, this);
Bind(wxEVT_MOUSEWHEEL, &CCodeView::OnScrollWheel, this);
Bind(wxEVT_LEFT_DOWN, &CCodeView::OnMouseDown, this);
Bind(wxEVT_LEFT_UP, &CCodeView::OnMouseUpL, this);
Bind(wxEVT_MOTION, &CCodeView::OnMouseMove, this);
Bind(wxEVT_RIGHT_DOWN, &CCodeView::OnMouseDown, this);
Bind(wxEVT_RIGHT_UP, &CCodeView::OnMouseUpR, this);
Bind(wxEVT_MENU, &CCodeView::OnPopupMenu, this);
Bind(wxEVT_SIZE, &CCodeView::OnResize, this);
}
int CCodeView::YToAddress(int y)

View File

@ -95,6 +95,4 @@ private:
bool m_selecting;
int m_lx, m_ly;
DECLARE_EVENT_TABLE()
};

View File

@ -60,35 +60,6 @@ extern "C" // Bitmaps
#include "DolphinWX/resources/toolbar_add_breakpoint.c" // NOLINT
}
class DebugInterface;
// -------
// Main
BEGIN_EVENT_TABLE(CCodeWindow, wxPanel)
// Menu bar
EVT_MENU_RANGE(IDM_INTERPRETER, IDM_JITSROFF, CCodeWindow::OnCPUMode)
EVT_MENU(IDM_FONTPICKER, CCodeWindow::OnChangeFont)
EVT_MENU_RANGE(IDM_CLEARCODECACHE, IDM_SEARCHINSTRUCTION, CCodeWindow::OnJitMenu)
EVT_MENU_RANGE(IDM_CLEARSYMBOLS, IDM_PATCHHLEFUNCTIONS, CCodeWindow::OnSymbolsMenu)
EVT_MENU_RANGE(IDM_PROFILEBLOCKS, IDM_WRITEPROFILE, CCodeWindow::OnProfilerMenu)
// Toolbar
EVT_MENU_RANGE(IDM_STEP, IDM_GOTOPC, CCodeWindow::OnCodeStep)
EVT_TEXT(IDM_ADDRBOX, CCodeWindow::OnAddrBoxChange)
// Other
EVT_LISTBOX(ID_SYMBOLLIST, CCodeWindow::OnSymbolListChange)
EVT_LISTBOX(ID_CALLSTACKLIST, CCodeWindow::OnCallstackListChange)
EVT_LISTBOX(ID_CALLERSLIST, CCodeWindow::OnCallersListChange)
EVT_LISTBOX(ID_CALLSLIST, CCodeWindow::OnCallsListChange)
EVT_HOST_COMMAND(wxID_ANY, CCodeWindow::OnHostMessage)
END_EVENT_TABLE()
// Class
CCodeWindow::CCodeWindow(const SCoreStartupParameter& _LocalCoreStartupParameter, CFrame *parent,
wxWindowID id, const wxPoint& position, const wxSize& size, long style, const wxString& name)
: wxPanel(parent, id, position, size, style, name)
@ -109,23 +80,40 @@ CCodeWindow::CCodeWindow(const SCoreStartupParameter& _LocalCoreStartupParameter
DebugInterface* di = &PowerPC::debug_interface;
codeview = new CCodeView(di, &g_symbolDB, this, ID_CODEVIEW);
codeview = new CCodeView(di, &g_symbolDB, this, wxID_ANY);
sizerBig->Add(sizerLeft, 2, wxEXPAND);
sizerBig->Add(codeview, 5, wxEXPAND);
sizerLeft->Add(callstack = new wxListBox(this, ID_CALLSTACKLIST,
wxDefaultPosition, wxSize(90, 100)), 0, wxEXPAND);
sizerLeft->Add(symbols = new wxListBox(this, ID_SYMBOLLIST,
wxDefaultPosition, wxSize(90, 100), 0, nullptr, wxLB_SORT), 1, wxEXPAND);
sizerLeft->Add(calls = new wxListBox(this, ID_CALLSLIST, wxDefaultPosition,
wxSize(90, 100), 0, nullptr, wxLB_SORT), 0, wxEXPAND);
sizerLeft->Add(callers = new wxListBox(this, ID_CALLERSLIST, wxDefaultPosition,
wxSize(90, 100), 0, nullptr, wxLB_SORT), 0, wxEXPAND);
sizerLeft->Add(callstack = new wxListBox(this, wxID_ANY, wxDefaultPosition, wxSize(90, 100)), 0, wxEXPAND);
callstack->Bind(wxEVT_LISTBOX, &CCodeWindow::OnCallstackListChange, this);
sizerLeft->Add(symbols = new wxListBox(this, wxID_ANY, wxDefaultPosition, wxSize(90, 100), 0, nullptr, wxLB_SORT), 1, wxEXPAND);
symbols->Bind(wxEVT_LISTBOX, &CCodeWindow::OnSymbolListChange, this);
sizerLeft->Add(calls = new wxListBox(this, wxID_ANY, wxDefaultPosition, wxSize(90, 100), 0, nullptr, wxLB_SORT), 0, wxEXPAND);
calls->Bind(wxEVT_LISTBOX, &CCodeWindow::OnCallsListChange, this);
sizerLeft->Add(callers = new wxListBox(this, wxID_ANY, wxDefaultPosition, wxSize(90, 100), 0, nullptr, wxLB_SORT), 0, wxEXPAND);
callers->Bind(wxEVT_LISTBOX, &CCodeWindow::OnCallersListChange, this);
SetSizer(sizerBig);
sizerLeft->Fit(this);
sizerBig->Fit(this);
// Menu
Bind(wxEVT_MENU, &CCodeWindow::OnCPUMode, this, IDM_INTERPRETER, IDM_JITSROFF);
Bind(wxEVT_MENU, &CCodeWindow::OnChangeFont, this, IDM_FONTPICKER);
Bind(wxEVT_MENU, &CCodeWindow::OnJitMenu, this, IDM_CLEARCODECACHE, IDM_SEARCHINSTRUCTION);
Bind(wxEVT_MENU, &CCodeWindow::OnSymbolsMenu, this, IDM_CLEARSYMBOLS, IDM_PATCHHLEFUNCTIONS);
Bind(wxEVT_MENU, &CCodeWindow::OnProfilerMenu, this, IDM_PROFILEBLOCKS, IDM_WRITEPROFILE);
// Toolbar
Bind(wxEVT_MENU, &CCodeWindow::OnCodeStep, this, IDM_STEP, IDM_GOTOPC);
Bind(wxEVT_TEXT, &CCodeWindow::OnAddrBoxChange, this, IDM_ADDRBOX);
// Other
Bind(wxEVT_HOST_COMMAND, &CCodeWindow::OnHostMessage, this);
}
wxMenuBar *CCodeWindow::GetMenuBar()

View File

@ -108,16 +108,6 @@ public:
int iNbAffiliation[IDM_CODEWINDOW - IDM_LOGWINDOW + 1];
private:
enum
{
// Debugger GUI Objects
ID_CODEVIEW,
ID_CALLSTACKLIST,
ID_CALLERSLIST,
ID_CALLSLIST,
ID_SYMBOLLIST
};
void OnSymbolListChange(wxCommandEvent& event);
void OnSymbolListContextMenu(wxContextMenuEvent& event);
void OnCallstackListChange(wxCommandEvent& event);
@ -143,6 +133,4 @@ private:
wxListBox* callers;
wxListBox* calls;
Common::Event sync_event;
DECLARE_EVENT_TABLE()
};

View File

@ -33,23 +33,16 @@
#include "DolphinWX/Debugger/DSPRegisterView.h"
#include "DolphinWX/Debugger/MemoryView.h"
class wxWindow;
static DSPDebuggerLLE* m_DebuggerFrame = nullptr;
BEGIN_EVENT_TABLE(DSPDebuggerLLE, wxPanel)
EVT_CLOSE(DSPDebuggerLLE::OnClose)
EVT_MENU_RANGE(ID_RUNTOOL, ID_SHOWPCTOOL, DSPDebuggerLLE::OnChangeState)
EVT_TEXT_ENTER(ID_ADDRBOX, DSPDebuggerLLE::OnAddrBoxChange)
EVT_LISTBOX(ID_SYMBOLLIST, DSPDebuggerLLE::OnSymbolListChange)
END_EVENT_TABLE()
DSPDebuggerLLE::DSPDebuggerLLE(wxWindow* parent, wxWindowID id)
: wxPanel(parent, id, wxDefaultPosition, wxDefaultSize,
wxTAB_TRAVERSAL, _("DSP LLE Debugger"))
, m_CachedStepCounter(-1)
{
Bind(wxEVT_CLOSE_WINDOW, &DSPDebuggerLLE::OnClose, this);
Bind(wxEVT_MENU, &DSPDebuggerLLE::OnChangeState, this, ID_RUNTOOL, ID_SHOWPCTOOL);
m_DebuggerFrame = this;
// notify wxAUI which frame to use
@ -65,12 +58,16 @@ DSPDebuggerLLE::DSPDebuggerLLE(wxWindow* parent, wxWindowID id)
m_Toolbar->AddTool(ID_SHOWPCTOOL, _("Show PC"),
wxArtProvider::GetBitmap(wxART_GO_TO_PARENT, wxART_OTHER, wxSize(10,10)));
m_Toolbar->AddSeparator();
m_Toolbar->AddControl(new wxTextCtrl(m_Toolbar, ID_ADDRBOX, wxEmptyString,
wxDefaultPosition, wxDefaultSize, wxTE_PROCESS_ENTER));
m_addr_txtctrl = new wxTextCtrl(m_Toolbar, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxTE_PROCESS_ENTER);
m_addr_txtctrl->Bind(wxEVT_TEXT_ENTER, &DSPDebuggerLLE::OnAddrBoxChange, this);
m_Toolbar->AddControl(m_addr_txtctrl);
m_Toolbar->Realize();
m_SymbolList = new wxListBox(this, ID_SYMBOLLIST, wxDefaultPosition,
m_SymbolList = new wxListBox(this, wxID_ANY, wxDefaultPosition,
wxSize(140, 100), 0, nullptr, wxLB_SORT);
m_SymbolList->Bind(wxEVT_LISTBOX, &DSPDebuggerLLE::OnSymbolListChange, this);
m_MainNotebook = new wxAuiNotebook(this, wxID_ANY,
wxDefaultPosition, wxDefaultSize,
@ -253,8 +250,7 @@ void DSPDebuggerLLE::UpdateRegisterFlags()
void DSPDebuggerLLE::OnAddrBoxChange(wxCommandEvent& event)
{
wxTextCtrl* pAddrCtrl = (wxTextCtrl*)m_Toolbar->FindControl(ID_ADDRBOX);
wxString txt = pAddrCtrl->GetValue();
wxString txt = m_addr_txtctrl->GetValue();
auto text = StripSpaces(WxStrToStr(txt));
if (text.size())
@ -262,9 +258,9 @@ void DSPDebuggerLLE::OnAddrBoxChange(wxCommandEvent& event)
u32 addr;
sscanf(text.c_str(), "%04x", &addr);
if (JumpToAddress(addr))
pAddrCtrl->SetBackgroundColour(*wxWHITE);
m_addr_txtctrl->SetBackgroundColour(*wxWHITE);
else
pAddrCtrl->SetBackgroundColour(*wxRED);
m_addr_txtctrl->SetBackgroundColour(*wxRED);
}
event.Skip();
}

View File

@ -30,16 +30,12 @@ public:
void Update() override;
private:
DECLARE_EVENT_TABLE();
enum
{
ID_TOOLBAR = 1000,
ID_RUNTOOL,
ID_STEPTOOL,
ID_SHOWPCTOOL,
ID_ADDRBOX,
ID_SYMBOLLIST,
ID_DSP_REGS
};
@ -59,6 +55,7 @@ private:
CMemoryView* m_MemView;
DSPRegisterView* m_Regs;
wxListBox* m_SymbolList;
wxTextCtrl* m_addr_txtctrl;
wxAuiNotebook* m_MainNotebook;
void OnClose(wxCloseEvent& event);

View File

@ -170,43 +170,24 @@ std::string HostDisassemblerX86::DisassembleHostBlock(const u8* code_start, cons
return x86_disasm.str();
}
enum
{
IDM_REFRESH_LIST = 23350,
IDM_PPC_BOX,
IDM_X86_BOX,
IDM_NEXT,
IDM_PREV,
IDM_BLOCKLIST,
};
BEGIN_EVENT_TABLE(CJitWindow, wxPanel)
//EVT_TEXT(IDM_ADDRBOX, CJitWindow::OnAddrBoxChange)
//EVT_LISTBOX(IDM_SYMBOLLIST, CJitWindow::OnSymbolListChange)
//EVT_HOST_COMMAND(wxID_ANY, CJitWindow::OnHostMessage)
EVT_BUTTON(IDM_REFRESH_LIST, CJitWindow::OnRefresh)
END_EVENT_TABLE()
CJitWindow::CJitWindow(wxWindow* parent, wxWindowID id, const wxPoint& pos,
const wxSize& size, long style, const wxString& name)
: wxPanel(parent, id, pos, size, style, name)
{
wxBoxSizer* sizerBig = new wxBoxSizer(wxVERTICAL);
wxBoxSizer* sizerSplit = new wxBoxSizer(wxHORIZONTAL);
sizerSplit->Add(ppc_box = new wxTextCtrl(this, IDM_PPC_BOX, "(ppc)",
sizerSplit->Add(ppc_box = new wxTextCtrl(this, wxID_ANY, "(ppc)",
wxDefaultPosition, wxDefaultSize, wxTE_MULTILINE), 1, wxEXPAND);
sizerSplit->Add(x86_box = new wxTextCtrl(this, IDM_X86_BOX, "(x86)",
sizerSplit->Add(x86_box = new wxTextCtrl(this, wxID_ANY, "(x86)",
wxDefaultPosition, wxDefaultSize, wxTE_MULTILINE), 1, wxEXPAND);
sizerBig->Add(block_list = new JitBlockList(this, IDM_BLOCKLIST,
sizerBig->Add(block_list = new JitBlockList(this, wxID_ANY,
wxDefaultPosition, wxSize(100, 140),
wxLC_REPORT | wxSUNKEN_BORDER | wxLC_ALIGN_LEFT | wxLC_SINGLE_SEL | wxLC_SORT_ASCENDING),
0, wxEXPAND);
sizerBig->Add(sizerSplit, 2, wxEXPAND);
// sizerBig->Add(memview, 5, wxEXPAND);
// sizerBig->Add(sizerRight, 0, wxEXPAND | wxALL, 3);
sizerBig->Add(button_refresh = new wxButton(this, IDM_REFRESH_LIST, _("&Refresh")));
// sizerRight->Add(addrbox = new wxTextCtrl(this, IDM_ADDRBOX, ""));
// sizerRight->Add(new wxButton(this, IDM_SETPC, _("S&et PC")));
sizerBig->Add(button_refresh = new wxButton(this, wxID_ANY, _("&Refresh")));
button_refresh->Bind(wxEVT_BUTTON, &CJitWindow::OnRefresh, this);
SetSizer(sizerBig);

View File

@ -77,8 +77,6 @@ private:
wxTextCtrl* x86_box;
wxListBox* top_instructions;
DECLARE_EVENT_TABLE()
void OnSymbolListChange(wxCommandEvent& event);
void OnCallstackListChange(wxCommandEvent& event);
void OnAddrBoxChange(wxCommandEvent& event);

View File

@ -25,14 +25,12 @@
#define TEXT_BOX(text) new wxStaticText(this, wxID_ANY, _(text))
BEGIN_EVENT_TABLE(MemoryCheckDlg, wxDialog)
EVT_BUTTON(wxID_OK, MemoryCheckDlg::OnOK)
END_EVENT_TABLE()
MemoryCheckDlg::MemoryCheckDlg(CBreakPointWindow *parent)
: wxDialog(parent, wxID_ANY, _("Memory Check"))
, m_parent(parent)
{
Bind(wxEVT_BUTTON, &MemoryCheckDlg::OnOK, this);
m_pEditStartAddress = new wxTextCtrl(this, wxID_ANY, "");
m_pEditEndAddress = new wxTextCtrl(this, wxID_ANY, "");
m_pWriteFlag = new wxCheckBox(this, wxID_ANY, _("Write"));

View File

@ -26,6 +26,4 @@ private:
wxTextCtrl* m_pEditStartAddress;
void OnOK(wxCommandEvent& event);
DECLARE_EVENT_TABLE();
};

View File

@ -48,17 +48,6 @@ enum
IDM_VIEWASHEX,
};
BEGIN_EVENT_TABLE(CMemoryView, wxControl)
EVT_PAINT(CMemoryView::OnPaint)
EVT_LEFT_DOWN(CMemoryView::OnMouseDownL)
EVT_LEFT_UP(CMemoryView::OnMouseUpL)
EVT_MOTION(CMemoryView::OnMouseMove)
EVT_RIGHT_DOWN(CMemoryView::OnMouseDownR)
EVT_MOUSEWHEEL(CMemoryView::OnScrollWheel)
EVT_MENU(-1, CMemoryView::OnPopupMenu)
EVT_SIZE(CMemoryView::OnResize)
END_EVENT_TABLE()
CMemoryView::CMemoryView(DebugInterface* debuginterface, wxWindow* parent)
: wxControl(parent, wxID_ANY)
, curAddress(debuginterface->GetPC())
@ -71,6 +60,14 @@ CMemoryView::CMemoryView(DebugInterface* debuginterface, wxWindow* parent)
, memory(0)
, viewAsType(VIEWAS_FP)
{
Bind(wxEVT_PAINT, &CMemoryView::OnPaint, this);
Bind(wxEVT_LEFT_DOWN, &CMemoryView::OnMouseDownL, this);
Bind(wxEVT_LEFT_UP, &CMemoryView::OnMouseUpL, this);
Bind(wxEVT_MOTION, &CMemoryView::OnMouseMove, this);
Bind(wxEVT_RIGHT_DOWN, &CMemoryView::OnMouseDownR, this);
Bind(wxEVT_MOUSEWHEEL, &CMemoryView::OnScrollWheel, this);
Bind(wxEVT_MENU, &CMemoryView::OnPopupMenu, this);
Bind(wxEVT_SIZE, &CMemoryView::OnResize, this);
}
int CMemoryView::YToAddress(int y)

View File

@ -58,6 +58,4 @@ private:
};
EViewAsType viewAsType;
DECLARE_EVENT_TABLE()
};

View File

@ -255,6 +255,9 @@ CRegisterView::CRegisterView(wxWindow *parent, wxWindowID id)
SetColLabelSize(0);
DisableDragRowSize();
Bind(wxEVT_GRID_CELL_RIGHT_CLICK, &CRegisterView::OnMouseDownR, this);
Bind(wxEVT_MENU, &CRegisterView::OnPopupMenu, this);
AutoSizeColumns();
}

View File

@ -15,14 +15,6 @@
#include "DolphinWX/Debugger/RegisterView.h"
#include "DolphinWX/Debugger/RegisterWindow.h"
class wxWindow;
BEGIN_EVENT_TABLE(CRegisterWindow, wxPanel)
EVT_GRID_CELL_RIGHT_CLICK(CRegisterView::OnMouseDownR)
EVT_MENU(-1, CRegisterView::OnPopupMenu)
END_EVENT_TABLE()
CRegisterWindow::CRegisterWindow(wxWindow* parent, wxWindowID id,
const wxPoint& position, const wxSize& size,
long style, const wxString& name)

View File

@ -15,8 +15,7 @@
class CRegisterView;
class wxWindow;
class CRegisterWindow
: public wxPanel
class CRegisterWindow : public wxPanel
{
public:
CRegisterWindow(wxWindow* parent,
@ -28,10 +27,7 @@ public:
void NotifyUpdate();
private:
DECLARE_EVENT_TABLE();
enum
{
ID_GPR = 1002

View File

@ -221,6 +221,9 @@ CWatchView::CWatchView(wxWindow* parent, wxWindowID id)
SetRowLabelSize(0);
SetColLabelSize(0);
DisableDragRowSize();
Bind(wxEVT_GRID_CELL_RIGHT_CLICK, &CWatchView::OnMouseDownR, this);
Bind(wxEVT_MENU, &CWatchView::OnPopupMenu, this);
}
void CWatchView::Update()

View File

@ -26,13 +26,6 @@ extern "C" {
#include "DolphinWX/resources/toolbar_debugger_delete.c"
}
class wxWindow;
BEGIN_EVENT_TABLE(CWatchWindow, wxPanel)
EVT_GRID_CELL_RIGHT_CLICK(CWatchView::OnMouseDownR)
EVT_MENU(-1, CWatchView::OnPopupMenu)
END_EVENT_TABLE()
class CWatchToolbar : public wxAuiToolBar
{
public:

View File

@ -16,8 +16,7 @@
class CWatchView;
class wxWindow;
class CWatchWindow
: public wxPanel
class CWatchWindow : public wxPanel
{
public:
CWatchWindow(wxWindow* parent,
@ -35,8 +34,6 @@ public:
void LoadAll();
private:
DECLARE_EVENT_TABLE();
wxAuiManager m_mgr;
enum

View File

@ -229,7 +229,7 @@ bool CRenderFrame::ShowFullScreen(bool show, long style)
// Notice that wxID_HELP will be processed for the 'About' menu and the toolbar
// help button.
const wxEventType wxEVT_HOST_COMMAND = wxNewEventType();
wxDEFINE_EVENT(wxEVT_HOST_COMMAND, wxCommandEvent);
BEGIN_EVENT_TABLE(CFrame, CRenderFrame)

View File

@ -292,4 +292,4 @@ enum
(wxObject*) nullptr \
),
extern const wxEventType wxEVT_HOST_COMMAND;
wxDECLARE_EVENT(wxEVT_HOST_COMMAND, wxCommandEvent);