Use wx-prefixed macros throughout the repository.
Change {DECLARE,IMPLEMENT}_*CLASS and {DECLARE,BEGIN,END}_EVENT_TABLE occurrences to use the wx-prefixed version of the macros.
This commit is contained in:
@@ -32,7 +32,7 @@
|
||||
# include "bombs.xpm"
|
||||
#endif
|
||||
|
||||
IMPLEMENT_APP(BombsApp)
|
||||
wxIMPLEMENT_APP(BombsApp);
|
||||
|
||||
#ifdef __WXWINCE__
|
||||
STDAPI_(__int64) CeGetRandomSeed();
|
||||
@@ -54,7 +54,7 @@ bool BombsApp::OnInit()
|
||||
return true;
|
||||
}
|
||||
|
||||
BEGIN_EVENT_TABLE(BombsFrame, wxFrame)
|
||||
wxBEGIN_EVENT_TABLE(BombsFrame, wxFrame)
|
||||
EVT_MENU(wxID_NEW, BombsFrame::OnNewGame)
|
||||
EVT_MENU(bombsID_EASY, BombsFrame::OnEasyGame)
|
||||
EVT_MENU(bombsID_MEDIUM, BombsFrame::OnMediumGame)
|
||||
@@ -62,7 +62,7 @@ BEGIN_EVENT_TABLE(BombsFrame, wxFrame)
|
||||
EVT_MENU(bombsID_EASYCORNER, BombsFrame::OnEasyCorner)
|
||||
EVT_MENU(wxID_EXIT, BombsFrame::OnExit)
|
||||
EVT_MENU(wxID_ABOUT, BombsFrame::OnAbout)
|
||||
END_EVENT_TABLE()
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
BombsFrame::BombsFrame(BombsGame *game)
|
||||
: wxFrame(NULL, wxID_ANY, wxT("wxBombs"), wxDefaultPosition,
|
||||
@@ -216,11 +216,11 @@ void BombsFrame::OnEasyCorner(wxCommandEvent& WXUNUSED(event))
|
||||
NewGame(m_lastLevel, true);
|
||||
}
|
||||
|
||||
BEGIN_EVENT_TABLE(BombsCanvas, wxPanel)
|
||||
wxBEGIN_EVENT_TABLE(BombsCanvas, wxPanel)
|
||||
EVT_PAINT(BombsCanvas::OnPaint)
|
||||
EVT_MOUSE_EVENTS(BombsCanvas::OnMouseEvent)
|
||||
EVT_CHAR(BombsCanvas::OnChar)
|
||||
END_EVENT_TABLE()
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
BombsCanvas::BombsCanvas(wxFrame *parent, BombsGame *game)
|
||||
: wxPanel(parent, wxID_ANY)
|
||||
|
@@ -30,7 +30,7 @@ private :
|
||||
|
||||
};
|
||||
|
||||
DECLARE_APP(BombsApp)
|
||||
wxDECLARE_APP(BombsApp);
|
||||
|
||||
class BombsCanvas;
|
||||
|
||||
@@ -62,7 +62,7 @@ private:
|
||||
// Subwindows for reference within the program.
|
||||
BombsCanvas *m_canvas;
|
||||
|
||||
DECLARE_EVENT_TABLE()
|
||||
wxDECLARE_EVENT_TABLE();
|
||||
};
|
||||
|
||||
// App specific menu identifiers
|
||||
@@ -106,7 +106,7 @@ private:
|
||||
int m_cellWidth;
|
||||
int m_cellHeight;
|
||||
|
||||
DECLARE_EVENT_TABLE()
|
||||
wxDECLARE_EVENT_TABLE();
|
||||
};
|
||||
|
||||
/* The following sizes should probably be redefined */
|
||||
|
@@ -28,9 +28,9 @@
|
||||
#include "playerdg.h"
|
||||
#include "canvas.h"
|
||||
|
||||
BEGIN_EVENT_TABLE(FortyCanvas, wxScrolledWindow)
|
||||
wxBEGIN_EVENT_TABLE(FortyCanvas, wxScrolledWindow)
|
||||
EVT_MOUSE_EVENTS(FortyCanvas::OnMouseEvent)
|
||||
END_EVENT_TABLE()
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
FortyCanvas::FortyCanvas(wxWindow* parent, const wxPoint& pos, const wxSize& size) :
|
||||
wxScrolledWindow(parent, wxID_ANY, pos, size, 0),
|
||||
|
@@ -39,7 +39,7 @@ public:
|
||||
void LayoutGame();
|
||||
void ShowPlayerDialog();
|
||||
|
||||
DECLARE_EVENT_TABLE()
|
||||
wxDECLARE_EVENT_TABLE();
|
||||
|
||||
private:
|
||||
wxFont* m_font;
|
||||
|
@@ -34,7 +34,7 @@
|
||||
|
||||
#include "wx/stockitem.h"
|
||||
|
||||
BEGIN_EVENT_TABLE(FortyFrame, wxFrame)
|
||||
wxBEGIN_EVENT_TABLE(FortyFrame, wxFrame)
|
||||
EVT_MENU(wxID_NEW, FortyFrame::NewGame)
|
||||
EVT_MENU(wxID_EXIT, FortyFrame::Exit)
|
||||
EVT_MENU(wxID_ABOUT, FortyFrame::About)
|
||||
@@ -46,10 +46,10 @@ BEGIN_EVENT_TABLE(FortyFrame, wxFrame)
|
||||
EVT_MENU(HELPING_HAND, FortyFrame::ToggleHelpingHand)
|
||||
EVT_MENU(LARGE_CARDS, FortyFrame::ToggleCardSize)
|
||||
EVT_CLOSE(FortyFrame::OnCloseWindow)
|
||||
END_EVENT_TABLE()
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
// Create a new application object
|
||||
IMPLEMENT_APP (FortyApp)
|
||||
wxIMPLEMENT_APP(FortyApp);
|
||||
|
||||
wxColour* FortyApp::m_backgroundColour = 0;
|
||||
wxColour* FortyApp::m_textColour = 0;
|
||||
|
@@ -31,7 +31,7 @@ private:
|
||||
wxString m_helpFile;
|
||||
};
|
||||
|
||||
DECLARE_APP(FortyApp)
|
||||
wxDECLARE_APP(FortyApp);
|
||||
|
||||
class FortyCanvas;
|
||||
class FortyFrame: public wxFrame
|
||||
@@ -56,7 +56,7 @@ public:
|
||||
|
||||
FortyCanvas* GetCanvas() { return m_canvas; }
|
||||
|
||||
DECLARE_EVENT_TABLE()
|
||||
wxDECLARE_EVENT_TABLE();
|
||||
|
||||
private:
|
||||
enum MenuCommands {
|
||||
|
@@ -24,13 +24,13 @@
|
||||
|
||||
const int ID_LISTBOX = 101;
|
||||
|
||||
BEGIN_EVENT_TABLE(PlayerSelectionDialog, wxDialog)
|
||||
wxBEGIN_EVENT_TABLE(PlayerSelectionDialog, wxDialog)
|
||||
EVT_SIZE(PlayerSelectionDialog::OnSize)
|
||||
EVT_BUTTON(wxID_OK, PlayerSelectionDialog::ButtonCallback)
|
||||
EVT_BUTTON(wxID_CANCEL, PlayerSelectionDialog::ButtonCallback)
|
||||
EVT_LISTBOX(ID_LISTBOX, PlayerSelectionDialog::SelectCallback)
|
||||
EVT_CLOSE(PlayerSelectionDialog::OnCloseWindow)
|
||||
END_EVENT_TABLE()
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
PlayerSelectionDialog::PlayerSelectionDialog(
|
||||
wxWindow* parent,
|
||||
|
@@ -23,7 +23,7 @@ public:
|
||||
void SelectCallback(wxCommandEvent& event);
|
||||
void OnSize(wxSizeEvent& event);
|
||||
|
||||
DECLARE_EVENT_TABLE()
|
||||
wxDECLARE_EVENT_TABLE();
|
||||
|
||||
protected:
|
||||
friend void SelectCallback(wxListBox&, wxCommandEvent&);
|
||||
|
@@ -125,9 +125,9 @@ void ScoreCanvas::OnDraw(wxDC& dc)
|
||||
}
|
||||
#endif
|
||||
|
||||
BEGIN_EVENT_TABLE(ScoreDialog, wxDialog)
|
||||
wxBEGIN_EVENT_TABLE(ScoreDialog, wxDialog)
|
||||
EVT_CLOSE(ScoreDialog::OnCloseWindow)
|
||||
END_EVENT_TABLE()
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
ScoreDialog::ScoreDialog(wxWindow* parent, ScoreFile* file) :
|
||||
wxDialog(parent, wxID_ANY, _("Scores"),
|
||||
|
@@ -27,7 +27,7 @@ private:
|
||||
ScoreFile* m_scoreFile;
|
||||
wxButton* m_OK;
|
||||
|
||||
DECLARE_EVENT_TABLE()
|
||||
wxDECLARE_EVENT_TABLE();
|
||||
};
|
||||
|
||||
#endif
|
||||
|
@@ -57,7 +57,7 @@ public:
|
||||
bool OnInit();
|
||||
};
|
||||
|
||||
IMPLEMENT_APP(MyApp)
|
||||
wxIMPLEMENT_APP(MyApp);
|
||||
|
||||
// Define a new frame type
|
||||
class MyFrame: public wxFrame
|
||||
@@ -68,7 +68,7 @@ public:
|
||||
void OnCloseWindow(wxCloseEvent& event);
|
||||
void OnExit(wxCommandEvent& event);
|
||||
|
||||
DECLARE_EVENT_TABLE()
|
||||
wxDECLARE_EVENT_TABLE();
|
||||
};
|
||||
|
||||
// Define a new canvas which can receive some events
|
||||
@@ -85,7 +85,7 @@ private:
|
||||
wxBrush WaterBrush;
|
||||
int Sealevel;
|
||||
|
||||
DECLARE_EVENT_TABLE()
|
||||
wxDECLARE_EVENT_TABLE();
|
||||
};
|
||||
|
||||
// `Main program' equivalent, creating windows and returning main app frame
|
||||
@@ -112,10 +112,10 @@ bool MyApp::OnInit()
|
||||
return true;
|
||||
}
|
||||
|
||||
BEGIN_EVENT_TABLE(MyFrame, wxFrame)
|
||||
wxBEGIN_EVENT_TABLE(MyFrame, wxFrame)
|
||||
EVT_CLOSE(MyFrame::OnCloseWindow)
|
||||
EVT_MENU(wxID_EXIT, MyFrame::OnExit)
|
||||
END_EVENT_TABLE()
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
// My frame constructor
|
||||
MyFrame::MyFrame(wxFrame *frame, const wxString& title, const wxPoint& pos, const wxSize& size):
|
||||
@@ -140,9 +140,9 @@ void MyFrame::OnCloseWindow(wxCloseEvent& WXUNUSED(event))
|
||||
destroyed = true;
|
||||
}
|
||||
|
||||
BEGIN_EVENT_TABLE(MyCanvas, wxWindow)
|
||||
wxBEGIN_EVENT_TABLE(MyCanvas, wxWindow)
|
||||
EVT_PAINT(MyCanvas::OnPaint)
|
||||
END_EVENT_TABLE()
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
// Define a constructor for my canvas
|
||||
MyCanvas::MyCanvas(wxFrame *frame):
|
||||
|
@@ -57,9 +57,9 @@ enum
|
||||
// --------------------------------------------------------------------------
|
||||
|
||||
// Event tables
|
||||
BEGIN_EVENT_TABLE(LifeSamplesDialog, wxDialog)
|
||||
wxBEGIN_EVENT_TABLE(LifeSamplesDialog, wxDialog)
|
||||
EVT_LISTBOX (ID_LISTBOX, LifeSamplesDialog::OnListBox)
|
||||
END_EVENT_TABLE()
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
|
||||
// ==========================================================================
|
||||
|
@@ -34,7 +34,7 @@ public:
|
||||
|
||||
private:
|
||||
// any class wishing to process wxWidgets events must use this macro
|
||||
DECLARE_EVENT_TABLE()
|
||||
wxDECLARE_EVENT_TABLE();
|
||||
|
||||
int m_value;
|
||||
wxListBox *m_list;
|
||||
|
@@ -922,7 +922,7 @@ bool Life::NextTic()
|
||||
|
||||
class LifeModule: public wxModule
|
||||
{
|
||||
DECLARE_DYNAMIC_CLASS(LifeModule)
|
||||
wxDECLARE_DYNAMIC_CLASS(LifeModule);
|
||||
|
||||
public:
|
||||
LifeModule() {};
|
||||
@@ -930,7 +930,7 @@ public:
|
||||
void OnExit();
|
||||
};
|
||||
|
||||
IMPLEMENT_DYNAMIC_CLASS(LifeModule, wxModule)
|
||||
wxIMPLEMENT_DYNAMIC_CLASS(LifeModule, wxModule);
|
||||
|
||||
bool LifeModule::OnInit()
|
||||
{
|
||||
|
@@ -97,7 +97,7 @@ enum
|
||||
// --------------------------------------------------------------------------
|
||||
|
||||
// Event tables
|
||||
BEGIN_EVENT_TABLE(LifeFrame, wxFrame)
|
||||
wxBEGIN_EVENT_TABLE(LifeFrame, wxFrame)
|
||||
EVT_MENU (wxID_NEW, LifeFrame::OnMenu)
|
||||
#if wxUSE_FILEDLG
|
||||
EVT_MENU (wxID_OPEN, LifeFrame::OnOpen)
|
||||
@@ -122,13 +122,13 @@ BEGIN_EVENT_TABLE(LifeFrame, wxFrame)
|
||||
EVT_COMMAND_SCROLL (ID_SLIDER, LifeFrame::OnSlider)
|
||||
EVT_TIMER (ID_TIMER, LifeFrame::OnTimer)
|
||||
EVT_CLOSE ( LifeFrame::OnClose)
|
||||
END_EVENT_TABLE()
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
BEGIN_EVENT_TABLE(LifeNavigator, wxMiniFrame)
|
||||
wxBEGIN_EVENT_TABLE(LifeNavigator, wxMiniFrame)
|
||||
EVT_CLOSE ( LifeNavigator::OnClose)
|
||||
END_EVENT_TABLE()
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
BEGIN_EVENT_TABLE(LifeCanvas, wxWindow)
|
||||
wxBEGIN_EVENT_TABLE(LifeCanvas, wxWindow)
|
||||
EVT_PAINT ( LifeCanvas::OnPaint)
|
||||
EVT_SCROLLWIN ( LifeCanvas::OnScroll)
|
||||
EVT_SIZE ( LifeCanvas::OnSize)
|
||||
@@ -137,11 +137,11 @@ BEGIN_EVENT_TABLE(LifeCanvas, wxWindow)
|
||||
EVT_LEFT_UP ( LifeCanvas::OnMouse)
|
||||
EVT_LEFT_DCLICK ( LifeCanvas::OnMouse)
|
||||
EVT_ERASE_BACKGROUND( LifeCanvas::OnEraseBackground)
|
||||
END_EVENT_TABLE()
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
|
||||
// Create a new application object
|
||||
IMPLEMENT_APP(LifeApp)
|
||||
wxIMPLEMENT_APP(LifeApp);
|
||||
|
||||
|
||||
// ==========================================================================
|
||||
|
@@ -41,7 +41,7 @@ public:
|
||||
|
||||
private:
|
||||
// any class wishing to process wxWidgets events must use this macro
|
||||
DECLARE_EVENT_TABLE()
|
||||
wxDECLARE_EVENT_TABLE();
|
||||
|
||||
// draw a cell (parametrized by DC)
|
||||
void DrawCell(wxInt32 i, wxInt32 j, wxDC &dc);
|
||||
@@ -93,7 +93,7 @@ public:
|
||||
|
||||
private:
|
||||
// any class wishing to process wxWidgets events must use this macro
|
||||
DECLARE_EVENT_TABLE()
|
||||
wxDECLARE_EVENT_TABLE();
|
||||
|
||||
// event handlers
|
||||
void OnClose(wxCloseEvent& event);
|
||||
@@ -117,7 +117,7 @@ public:
|
||||
|
||||
private:
|
||||
// any class wishing to process wxWidgets events must use this macro
|
||||
DECLARE_EVENT_TABLE()
|
||||
wxDECLARE_EVENT_TABLE();
|
||||
|
||||
// event handlers
|
||||
void OnMenu(wxCommandEvent& event);
|
||||
|
@@ -96,7 +96,7 @@ void FindMax(int *max_thing, int thing);
|
||||
STDAPI_(__int64) CeGetRandomSeed();
|
||||
#endif
|
||||
|
||||
IMPLEMENT_APP(MyApp)
|
||||
wxIMPLEMENT_APP(MyApp);
|
||||
|
||||
MainWindow *TheMainWindow = NULL;
|
||||
|
||||
@@ -108,11 +108,11 @@ void MainWindow::CreateFonts()
|
||||
m_italicFont = wxTheFontList->FindOrCreateFont(pointSize, wxSWISS, wxITALIC, wxNORMAL);
|
||||
}
|
||||
|
||||
BEGIN_EVENT_TABLE(MainWindow, wxFrame)
|
||||
wxBEGIN_EVENT_TABLE(MainWindow, wxFrame)
|
||||
EVT_CLOSE(MainWindow::OnCloseWindow)
|
||||
EVT_CHAR(MainWindow::OnChar)
|
||||
EVT_MENU(wxID_ANY, MainWindow::OnPopup)
|
||||
END_EVENT_TABLE()
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
MainWindow::MainWindow(wxFrame *frame, wxWindowID id, const wxString& title,
|
||||
const wxPoint& pos, const wxSize& size, long style):
|
||||
@@ -581,11 +581,11 @@ void MainWindow::OnChar(wxKeyEvent& event)
|
||||
canvas->OnChar(event);
|
||||
}
|
||||
|
||||
BEGIN_EVENT_TABLE(MyCanvas, wxWindow)
|
||||
wxBEGIN_EVENT_TABLE(MyCanvas, wxWindow)
|
||||
EVT_MOUSE_EVENTS(MyCanvas::OnMouseEvent)
|
||||
EVT_CHAR(MyCanvas::OnChar)
|
||||
EVT_PAINT(MyCanvas::OnPaint)
|
||||
END_EVENT_TABLE()
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
// Define a constructor for my canvas
|
||||
MyCanvas::MyCanvas(wxFrame *frame):
|
||||
|
@@ -25,7 +25,7 @@ public:
|
||||
int OnExit();
|
||||
};
|
||||
|
||||
DECLARE_APP(MyApp)
|
||||
wxDECLARE_APP(MyApp);
|
||||
|
||||
// Define a new canvas which can receive some events
|
||||
class MyCanvas: public wxWindow
|
||||
@@ -41,7 +41,7 @@ public:
|
||||
private:
|
||||
wxMenu *m_popupMenu;
|
||||
|
||||
DECLARE_EVENT_TABLE()
|
||||
wxDECLARE_EVENT_TABLE();
|
||||
};
|
||||
|
||||
// Define a new frame
|
||||
@@ -94,7 +94,7 @@ private:
|
||||
// Icons
|
||||
wxIcon *m_corners[4];
|
||||
|
||||
DECLARE_EVENT_TABLE()
|
||||
wxDECLARE_EVENT_TABLE();
|
||||
};
|
||||
|
||||
// Menu items
|
||||
|
Reference in New Issue
Block a user