Fix -Woverloaded-virtual warnings

hides overloaded virtual function

Fix member signatures of deriving classes to its super classes.
Removes the unused idGameBustOutWindow::Activate() and the
useless idMarkerWindow::GetWinVarByName().
This commit is contained in:
dhewg 2011-12-03 00:40:47 +01:00
parent 2556a3923f
commit 50a48cdf6b
11 changed files with 5 additions and 31 deletions

View file

@ -148,6 +148,6 @@ idDeclEntityDef::Print
Dumps all key/value pairs, including inherited ones
================
*/
void idDeclEntityDef::Print( void ) {
void idDeclEntityDef::Print( void ) const {
dict.Print();
}

View file

@ -45,7 +45,7 @@ public:
virtual const char * DefaultDefinition() const;
virtual bool Parse( const char *text, const int textLength );
virtual void FreeData( void );
virtual void Print( void );
virtual void Print( void ) const;
};
#endif /* !__DECLENTITYDEF_H__ */

View file

@ -2238,7 +2238,7 @@ void idRenderModelStatic::WriteToDemoFile( class idDemoFile *f ) {
idRenderModelStatic::IsLoaded
================
*/
bool idRenderModelStatic::IsLoaded( void ) {
bool idRenderModelStatic::IsLoaded( void ) const {
return !purged;
}

View file

@ -208,7 +208,7 @@ public:
virtual void LoadModel() = 0;
// internal use
virtual bool IsLoaded() = 0;
virtual bool IsLoaded() const = 0;
virtual void SetLevelLoadReferenced( bool referenced ) = 0;
virtual bool IsLevelLoadReferenced() = 0;

View file

@ -50,7 +50,7 @@ public:
virtual void PurgeModel();
virtual void Reset() {};
virtual void LoadModel();
virtual bool IsLoaded();
virtual bool IsLoaded() const;
virtual void SetLevelLoadReferenced( bool referenced );
virtual bool IsLevelLoadReferenced();
virtual void TouchData();

View file

@ -536,15 +536,6 @@ void idGameBearShootWindow::Draw(int time, float x, float y) {
}
}
/*
=============================
idGameBearShootWindow::Activate
=============================
*/
const char *idGameBearShootWindow::Activate(bool activate) {
return "";
}
/*
=============================
idGameBearShootWindow::UpdateTurret

View file

@ -78,7 +78,6 @@ public:
virtual const char* HandleEvent(const sysEvent_t *event, bool *updateVisuals);
virtual void PostParse();
virtual void Draw(int time, float x, float y);
virtual const char* Activate(bool activate);
virtual idWinVar * GetWinVarByName (const char *_name, bool winLookup = false, drawWin_t** owner = NULL);
private:

View file

@ -771,16 +771,6 @@ void idGameBustOutWindow::Draw(int time, float x, float y) {
}
}
/*
=============================
idGameBustOutWindow::Activate
=============================
*/
const char *idGameBustOutWindow::Activate(bool activate) {
return "";
}
/*
=============================
idGameBustOutWindow::UpdateScore

View file

@ -120,7 +120,6 @@ public:
virtual const char* HandleEvent(const sysEvent_t *event, bool *updateVisuals);
virtual void PostParse();
virtual void Draw(int time, float x, float y);
virtual const char* Activate(bool activate);
virtual idWinVar * GetWinVarByName (const char *_name, bool winLookup = false, drawWin_t** owner = NULL);
idList<BOEntity*> entities;

View file

@ -84,10 +84,6 @@ bool idMarkerWindow::ParseInternalVar(const char *_name, idParser *src) {
return idWindow::ParseInternalVar(_name, src);
}
idWinVar *idMarkerWindow::GetWinVarByName(const char *_name, bool fixup) {
return idWindow::GetWinVarByName(_name, fixup);
}
const char *idMarkerWindow::HandleEvent(const sysEvent_t *event, bool *updateVisuals) {
if (!(event->evType == SE_KEY && event->evValue2)) {

View file

@ -42,7 +42,6 @@ public:
idMarkerWindow(idDeviceContext *d, idUserInterfaceLocal *gui);
virtual ~idMarkerWindow();
virtual size_t Allocated(){return idWindow::Allocated();};
virtual idWinVar *GetWinVarByName(const char *_name, bool winLookup = false);
virtual const char *HandleEvent(const sysEvent_t *event, bool *updateVisuals);
virtual void PostParse();