Mark a bunch of things as overriding virtual functions

This commit is contained in:
Thomas Goyne 2015-07-17 14:56:22 -07:00
parent 7a60ac95ef
commit 09b2736103
4 changed files with 9 additions and 12 deletions

View file

@ -30,7 +30,7 @@ struct OSXQueue : Queue {
struct MainQueue final : OSXQueue {
void DoInvoke(Thunk thunk) override { invoke_main(thunk); }
void DoSync(Thunk thunk) {
void DoSync(Thunk thunk) override {
std::mutex m;
std::condition_variable cv;
std::unique_lock<std::mutex> l(m);

View file

@ -28,11 +28,11 @@
namespace agi { struct Context; }
#define CMD_NAME(a) const char* name() const { return a; }
#define STR_MENU(a) wxString StrMenu(const agi::Context *) const { return _(a); }
#define STR_DISP(a) wxString StrDisplay(const agi::Context *) const { return _(a); }
#define STR_HELP(a) wxString StrHelp() const { return _(a); }
#define CMD_TYPE(a) int Type() const { using namespace cmd; return a; }
#define CMD_NAME(a) const char* name() const override { return a; }
#define STR_MENU(a) wxString StrMenu(const agi::Context *) const override { return _(a); }
#define STR_DISP(a) wxString StrDisplay(const agi::Context *) const override { return _(a); }
#define STR_HELP(a) wxString StrHelp() const override { return _(a); }
#define CMD_TYPE(a) int Type() const override { using namespace cmd; return a; }
#define CMD_ICON(icon) wxBitmap Icon(int size, wxLayoutDirection dir = wxLayout_LeftToRight) const override { \
if (size == 64) return GETIMAGEDIR(icon##_64, dir); \
@ -43,12 +43,12 @@ namespace agi { struct Context; }
}
#define COMMAND_GROUP(cname, cmdname, menu, disp, help) \
struct cname final : public Command { \
struct cname final : public Command { \
CMD_NAME(cmdname) \
STR_MENU(menu) \
STR_DISP(disp) \
STR_HELP(help) \
void operator()(agi::Context *) { } \
void operator()(agi::Context *) override { } \
}
/// Commands

View file

@ -320,7 +320,7 @@ public:
return helper(wxS("999"));
}
void Paint(wxDC &dc, int x, int y, const AssDialogue *d, const agi::Context *) const {
void Paint(wxDC &dc, int x, int y, const AssDialogue *d, const agi::Context *) const override {
int cps = CPS(d);
if (cps < 0 || cps > 100) return;

View file

@ -168,9 +168,6 @@ private:
/// @param feature The current feature to process; not necessarily the one clicked on
virtual void UpdateDrag(FeatureType *feature) { }
/// @brief Draw stuff
virtual void Draw()=0;
protected:
std::set<FeatureType *> sel_features; ///< Currently selected visual features