Add bulk speaker updates. Sped up speaker fetching by disabling list sorting during bulk updates.

This commit is contained in:
Shyotl
2018-02-07 21:18:35 -06:00
parent fa628ce4d1
commit 30df7dacde
6 changed files with 177 additions and 74 deletions

View File

@@ -125,6 +125,7 @@ LLScrollListCtrl::LLScrollListCtrl(const std::string& name, const LLRect& rect,
mNeedsScroll(false),
mCanSelect(true),
mColumnsDirty(false),
mSortEnabled(true),
mMaxItemCount(INT_MAX),
mMaxContentWidth(0),
mBorderThickness( 2 ),
@@ -2301,6 +2302,16 @@ BOOL LLScrollListCtrl::setSort(S32 column_idx, BOOL ascending)
}
}
void LLScrollListCtrl::setSortEnabled(bool sort)
{
bool update = sort && !mSortEnabled;
mSortEnabled = sort;
if (update)
{
updateSort();
}
}
S32 LLScrollListCtrl::getLinesPerPage()
{
//if mPageLines is NOT provided display all item
@@ -2942,7 +2953,7 @@ std::string LLScrollListCtrl::getSortColumnName()
BOOL LLScrollListCtrl::hasSortOrder() const
{
return !mSortColumns.empty();
return mSortEnabled && !mSortColumns.empty();
}
void LLScrollListCtrl::clearSortOrder()