mirror of https://github.com/OpenTTD/OpenTTD.git
Remove: Unnecessary virtual destructors on drop down list items.
This commit is contained in:
parent
303cfd86a3
commit
fb35cb5ed2
|
@ -519,8 +519,6 @@ class DropDownListColourItem : public DropDownListItem {
|
|||
public:
|
||||
DropDownListColourItem(int result, bool masked) : DropDownListItem(result, masked) {}
|
||||
|
||||
virtual ~DropDownListColourItem() {}
|
||||
|
||||
StringID String() const
|
||||
{
|
||||
return this->result >= COLOUR_END ? STR_COLOUR_DEFAULT : _colour_dropdown[this->result];
|
||||
|
|
|
@ -97,8 +97,6 @@ public:
|
|||
this->checkmark_width = GetStringBoundingBox(STR_JUST_CHECKMARK).width + 3;
|
||||
}
|
||||
|
||||
virtual ~DropDownListCheckedItem() {}
|
||||
|
||||
uint Width() const
|
||||
{
|
||||
return DropDownListStringItem::Width() + this->checkmark_width;
|
||||
|
@ -129,8 +127,6 @@ public:
|
|||
this->lock_size = GetSpriteSize(SPR_LOCK);
|
||||
}
|
||||
|
||||
virtual ~DropDownListCompanyItem() {}
|
||||
|
||||
bool Selectable() const
|
||||
{
|
||||
return true;
|
||||
|
|
|
@ -43,7 +43,6 @@ public:
|
|||
StringID string; ///< String ID of item
|
||||
|
||||
DropDownListStringItem(StringID string, int result, bool masked) : DropDownListItem(result, masked), string(string) {}
|
||||
virtual ~DropDownListStringItem() {}
|
||||
|
||||
virtual bool Selectable() const { return true; }
|
||||
virtual uint Width() const;
|
||||
|
@ -61,7 +60,6 @@ public:
|
|||
uint64 decode_params[10]; ///< Parameters of the string
|
||||
|
||||
DropDownListParamStringItem(StringID string, int result, bool masked) : DropDownListStringItem(string, result, masked) {}
|
||||
virtual ~DropDownListParamStringItem() {}
|
||||
|
||||
virtual StringID String() const;
|
||||
virtual void SetParam(uint index, uint64 value) { decode_params[index] = value; }
|
||||
|
@ -75,7 +73,6 @@ public:
|
|||
const char *raw_string;
|
||||
|
||||
DropDownListCharStringItem(const char *raw_string, int result, bool masked) : DropDownListStringItem(STR_JUST_RAW_STRING, result, masked), raw_string(raw_string) {}
|
||||
virtual ~DropDownListCharStringItem() {}
|
||||
|
||||
virtual StringID String() const;
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue