replace a bad assert with VALIDATE
assert may only be used for cases that are guaranteed to be true for every possible input.
This commit is contained in:
parent
f3b7a17e51
commit
1f81b0fa24
1 changed files with 2 additions and 1 deletions
|
@ -1027,7 +1027,8 @@ namespace select_action
|
|||
void selection::select(grid& grid, const bool select)
|
||||
{
|
||||
selectable_item* selectable = dynamic_cast<selectable_item*>(grid.get_widget(0, 0));
|
||||
assert(selectable);
|
||||
//the check in selection::init is not strict enouth to guaranetee this.
|
||||
VALIDATE(selectable, "Only toggle buttons and panels are allowed as the cells of a list definition.");
|
||||
|
||||
selectable->set_value(select);
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue