BColumnListView: Always update the reference rect in ::FindVisibleRect...
...if the row is present in the list, but continue to return false if the row is not currently visible on the screen. Part of #11675. Cherry-picked from https://review.haiku-os.org/442.
This commit is contained in:
parent
74e882b39b
commit
81d0a0e0a7
@ -4561,13 +4561,11 @@ OutlineView::FindVisibleRect(BRow* row, BRect* _rect)
|
||||
float line = 0.0;
|
||||
for (RecursiveOutlineIterator iterator(&fRows); iterator.CurrentRow();
|
||||
iterator.GoToNext()) {
|
||||
if (line > fVisibleRect.bottom)
|
||||
break;
|
||||
|
||||
if (iterator.CurrentRow() == row) {
|
||||
_rect->Set(fVisibleRect.left, line, fVisibleRect.right,
|
||||
line + row->Height());
|
||||
return true;
|
||||
return line <= fVisibleRect.bottom;
|
||||
}
|
||||
|
||||
line += iterator.CurrentRow()->Height() + 1;
|
||||
|
Loading…
x
Reference in New Issue
Block a user