fix bug that throws exception in listbox::column_at(#248)
This commit is contained in:
parent
fba4097851
commit
29fc286ba3
@ -433,8 +433,16 @@ namespace nana
|
||||
{
|
||||
check_range(pos, cont_.size());
|
||||
|
||||
//The order of cont_'s elements is the display order.
|
||||
if (!disp_order)
|
||||
pos = this->cast(pos, false);
|
||||
{
|
||||
/// It always match the item with pos, otherwise a bug occurs.
|
||||
for (auto & m : cont_)
|
||||
{
|
||||
if (m.index == pos)
|
||||
return m;
|
||||
}
|
||||
}
|
||||
|
||||
return cont_[pos];
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user