Permalink
Browse files

Hack to resolve SV-2036. A lot of this code will probably get wiped o…

…ut in a merge soonish, so not investing time into a more proper fix.
  • Loading branch information...
Shyotl committed Jun 21, 2016
1 parent 95f56f0 commit cd25894a3959d290ce44083eb302939df3449f99
Showing with 9 additions and 0 deletions.
  1. +1 −0 indra/newview/llfolderview.h
  2. +8 −0 indra/newview/llinventoryactions.cpp
@@ -248,6 +248,7 @@ class LLFolderView : public LLFolderViewFolder, public LLEditMenuHandler
void setNeedsAutoRename(BOOL val) { mNeedsAutoRename = val; }
void setPinningSelectedItem(BOOL val) { mPinningSelectedItem = val; }
void setAutoSelectOverride(BOOL val) { mAutoSelectOverride = val; }
bool getAutoSelectOverride() const { return mAutoSelectOverride; }
BOOL getDebugFilters() { return mDebugFilters; }
@@ -173,7 +173,15 @@ void do_create(LLInventoryModel *model, LLInventoryPanel *ptr, const LLSD& sdtyp
LLFolderType::FT_NONE, LLStringUtil::null);
}
model->notifyObservers();
// Singu Note: SV-2036
// Hack! setSelection sets category to fetching state, which disables scrolling. Scrolling, however, is desired.
// Setting autoSelectOverride to true just happens to skip the fetch check, thus allowing the scroll to proceed.
bool autoselected = ptr->getRootFolder()->getAutoSelectOverride();
ptr->getRootFolder()->setAutoSelectOverride(true);
ptr->setSelection(category, TRUE);
// Restore autoSelectOverride to whatever it was before we hijacked it.
ptr->getRootFolder()->setAutoSelectOverride(autoselected);
}
else if ("lsl" == type)
{

0 comments on commit cd25894

Please sign in to comment.