diff options
| author | Andrey Kleshchev <117672381+akleshchev@users.noreply.github.com> | 2026-01-16 04:49:17 +0200 |
|---|---|---|
| committer | Andrey Kleshchev <117672381+akleshchev@users.noreply.github.com> | 2026-01-17 18:12:24 +0200 |
| commit | 6d8c0d0d57ba28ae00bcdbd3617e54a63507e508 (patch) | |
| tree | 6b3a798fb32c2075e7e2488b8835511f51cec4bb /indra/newview/lloutfitslist.cpp | |
| parent | dcda078b6cdc29c2ae17a6dae4dadf3d446cccf2 (diff) | |
#5276 Freeze when bulk editing outfits
Schedule refreshOutfit into idle loop instead of doing lots of updates at once.
Diffstat (limited to 'indra/newview/lloutfitslist.cpp')
| -rw-r--r-- | indra/newview/lloutfitslist.cpp | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/indra/newview/lloutfitslist.cpp b/indra/newview/lloutfitslist.cpp index 32831fcd9b..7db79c7010 100644 --- a/indra/newview/lloutfitslist.cpp +++ b/indra/newview/lloutfitslist.cpp @@ -1055,6 +1055,15 @@ void LLOutfitListBase::refreshList(const LLUUID& category_id) } } +void LLOutfitListBase::startIdleLoop(const LLUUID cat_id) +{ + if (mRefreshListState.CategoryUUID.isNull()) + { + mRefreshListState.CategoryUUID = cat_id; + gIdleCallbacks.addFunction(onIdle, this); + } +} + // static void LLOutfitListBase::onIdle(void* userdata) { @@ -1129,6 +1138,14 @@ void LLOutfitListBase::onIdleRefreshList() return; } + // Let derived classes process their own updates. + while (updateOneOutfit()) + { + curent_time = LLTimer::getTotalSeconds(); + if (curent_time >= end_time) + return; + } + sortOutfits(); highlightBaseOutfit(); |
