Skip to content

Commit

Permalink
fix listboxes having problems to find sort toggle buttons in differen…
Browse files Browse the repository at this point in the history
…t columns.
  • Loading branch information
gfgtdf committed Feb 15, 2016
1 parent 09e88c8 commit ff9a9e0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/gui/widgets/listbox.cpp
Expand Up @@ -526,7 +526,7 @@ void tlistbox::finalize(tbuilder_grid_const_ptr header,
}
tgrid& p = find_widget<tgrid>(this, "_header_grid", false);
for(unsigned i = 0, max = std::max(p.get_cols(), p.get_rows()); i < max; ++i) {
if(tselectable_* selectable = find_widget<tselectable_>(p.widget(0,i), "sort_" + lexical_cast<std::string>(i), false, false)) {
if(tselectable_* selectable = find_widget<tselectable_>(&p, "sort_" + lexical_cast<std::string>(i), false, false)) {
selectable->set_callback_state_change(boost::bind(&tlistbox::order_by_column, this, i, _1));
if(orders_.size() < max ) {
orders_.resize(max);
Expand Down

0 comments on commit ff9a9e0

Please sign in to comment.