Remove button from button_group when free
This commit is contained in:
parent
bb2341e813
commit
13af5e8878
1 changed files with 3 additions and 3 deletions
|
@ -539,15 +539,15 @@ BaseButton::BaseButton() {
|
||||||
set_focus_mode(FOCUS_ALL);
|
set_focus_mode(FOCUS_ALL);
|
||||||
enabled_focus_mode = FOCUS_ALL;
|
enabled_focus_mode = FOCUS_ALL;
|
||||||
action_mode = ACTION_MODE_BUTTON_RELEASE;
|
action_mode = ACTION_MODE_BUTTON_RELEASE;
|
||||||
|
}
|
||||||
|
|
||||||
|
BaseButton::~BaseButton() {
|
||||||
|
|
||||||
if (button_group.is_valid()) {
|
if (button_group.is_valid()) {
|
||||||
button_group->buttons.erase(this);
|
button_group->buttons.erase(this);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
BaseButton::~BaseButton() {
|
|
||||||
}
|
|
||||||
|
|
||||||
void ButtonGroup::get_buttons(List<BaseButton *> *r_buttons) {
|
void ButtonGroup::get_buttons(List<BaseButton *> *r_buttons) {
|
||||||
|
|
||||||
for (Set<BaseButton *>::Element *E = buttons.front(); E; E = E->next()) {
|
for (Set<BaseButton *>::Element *E = buttons.front(); E; E = E->next()) {
|
||||||
|
|
Loading…
Reference in a new issue