Make radio button navigation functions const

This requires adding a couple of const_cast<>s in their implementation
in order to still allow them returning non-const wxRadioButton pointers,
but this seems preferable to not being able to call them on a const
wxRadioButton in the first place.
This commit is contained in:
Vadim Zeitlin
2020-09-21 15:36:41 +02:00
parent b5fb9bd8d6
commit 1a4f628e40
3 changed files with 24 additions and 24 deletions

View File

@@ -139,7 +139,7 @@ public:
@since 3.1.5
*/
wxRadioButton* GetFirstInGroup();
wxRadioButton* GetFirstInGroup() const;
/**
Returns the last radio button of the @c wxRB_GROUP this instance is in.
@@ -150,7 +150,7 @@ public:
@since 3.1.5
*/
wxRadioButton* GetLastInGroup();
wxRadioButton* GetLastInGroup() const;
/**
Returns the previous radio button of the @c wxRB_GROUP this instance is in.
@@ -162,7 +162,7 @@ public:
@since 3.1.5
*/
wxRadioButton* GetPreviousInGroup();
wxRadioButton* GetPreviousInGroup() const;
/**
Returns the next radio button of the @c wxRB_GROUP this instance is in.
@@ -174,6 +174,6 @@ public:
@since 3.1.5
*/
wxRadioButton* GetNextInGroup();
wxRadioButton* GetNextInGroup() const;
};