diff --git a/src/kits/tracker/FSUtils.cpp b/src/kits/tracker/FSUtils.cpp index b81a914ac5..832195650f 100644 --- a/src/kits/tracker/FSUtils.cpp +++ b/src/kits/tracker/FSUtils.cpp @@ -199,9 +199,8 @@ void TrackerCopyLoopControl::UpdateStatus(const char *name, entry_ref, int32 count, bool optional) { - if (gStatusWindow && gStatusWindow->HasStatus(fThread)) - gStatusWindow->UpdateStatus(fThread, const_cast(name), - count, optional); + if (gStatusWindow) + gStatusWindow->UpdateStatus(fThread, name, count, optional); } @@ -817,7 +816,7 @@ MoveTask(BObjectList *srcList, BEntry *destEntry, BList *pointList, u // update the status because item got skipped and the status // will not get updated by the move call - if (gStatusWindow && gStatusWindow->HasStatus(thread)) + if (gStatusWindow) gStatusWindow->UpdateStatus(thread, srcRef->name, 1); continue; @@ -1478,7 +1477,7 @@ MoveItem(BEntry *entry, BDirectory *destDir, BPoint *loc, uint32 moveMode, // size is irrelevant when simply moving to a new folder thread_id thread = find_thread(NULL); - if (gStatusWindow && gStatusWindow->HasStatus(thread)) + if (gStatusWindow) gStatusWindow->UpdateStatus(thread, ref.name, 1); if (entry->IsDirectory()) return RecursiveMove(entry, destDir); diff --git a/src/kits/tracker/StatusWindow.cpp b/src/kits/tracker/StatusWindow.cpp index 41829afb78..8e510932a6 100644 --- a/src/kits/tracker/StatusWindow.cpp +++ b/src/kits/tracker/StatusWindow.cpp @@ -301,23 +301,6 @@ BStatusWindow::RemoveStatusItem(thread_id thread) } -bool -BStatusWindow::HasStatus(thread_id thread) -{ - AutoLock lock(this); - - int32 numItems = fViewList.CountItems(); - for (int32 index = 0; index < numItems; index++) { - BStatusView* view = fViewList.ItemAt(index); - if (view->Thread() == thread) - return true; - - } - - return false; -} - - bool BStatusWindow::CheckCanceledOrPaused(thread_id thread) { diff --git a/src/kits/tracker/StatusWindow.h b/src/kits/tracker/StatusWindow.h index 690f9d08f3..35bcb68c5f 100644 --- a/src/kits/tracker/StatusWindow.h +++ b/src/kits/tracker/StatusWindow.h @@ -77,7 +77,6 @@ public: // will only be updated if 0.2 seconds // elapsed since the last update void RemoveStatusItem(thread_id); - bool HasStatus(thread_id); bool CheckCanceledOrPaused(thread_id); @@ -171,7 +170,7 @@ BStatusView::Thread() const } -extern BStatusWindow *gStatusWindow; +extern BStatusWindow* gStatusWindow; } // namespace BPrivate