forgot these ones

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16491 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Jérôme Duval 2006-02-21 12:10:18 +00:00
parent 5d62b41983
commit 3b07a76bbd

View File

@ -850,7 +850,7 @@ BListView::DeselectAll()
for (int32 index = fFirstSelected; index <= fLastSelected; index++) { for (int32 index = fFirstSelected; index <= fLastSelected; index++) {
BListItem *item = ItemAt(index); BListItem *item = ItemAt(index);
if (item->IsSelected()) { if (item && item->IsSelected()) {
item->Deselect(); item->Deselect();
InvalidateItem(index); InvalidateItem(index);
} }
@ -874,14 +874,14 @@ BListView::DeselectExcept(int32 start, int32 finish)
// supposed to be selected if not already // supposed to be selected if not already
for (index = fFirstSelected; index < start; index++) { for (index = fFirstSelected; index < start; index++) {
BListItem *item = ItemAt(index); BListItem *item = ItemAt(index);
if (item->IsSelected()) { if (item && item->IsSelected()) {
item->Deselect(); item->Deselect();
InvalidateItem(index); InvalidateItem(index);
} }
} }
for (index = finish + 1; index <= fLastSelected; index++) { for (index = finish + 1; index <= fLastSelected; index++) {
BListItem *item = ItemAt(index); BListItem *item = ItemAt(index);
if (item->IsSelected()) { if (item && item->IsSelected()) {
item->Deselect(); item->Deselect();
InvalidateItem(index); InvalidateItem(index);
} }