Added option (FSSortFSFoldersToTop) to control sorting #FS folders to the top (default on)

meow-7.2.2
Kadah_Coba 2013-07-03 20:11:04 -07:00
parent cc6e28169f
commit e8ef73c4af
3 changed files with 39 additions and 0 deletions

View File

@ -20731,5 +20731,16 @@ Change of this parameter will affect the layout of buttons in notification toast
<key>Value</key>
<integer>1</integer>
</map>
<key>FSSortFSFoldersToTop</key>
<map>
<key>Comment</key>
<string>Sorts the #FS and #RLV folders to the top like system folders.</string>
<key>Persist</key>
<integer>1</integer>
<key>Type</key>
<string>Boolean</string>
<key>Value</key>
<integer>1</integer>
</map>
</map>
</llsd>

View File

@ -662,6 +662,18 @@
<integer>0</integer>
</map>
<key>FSSortFSFoldersToTop</key>
<map>
<key>Persist</key>
<integer>1</integer>
<key>Comment</key>
<string>Sorts the #FS and #RLV folders to the top like system folders.</string>
<key>Type</key>
<string>Boolean</string>
<key>Value</key>
<integer>0</integer>
</map>

View File

@ -4028,6 +4028,22 @@ EInventorySortGroup LLFolderBridge::getSortGroup() const
return SG_TRASH_FOLDER;
}
//<FS:KC> Don't sort #FS folders to top
static LLCachedControl<bool> sFSSortFSFoldersToTopPt(gSavedSettings, "FSSortFSFoldersToTop");
if (!sFSSortFSFoldersToTopPt)
{
LLViewerInventoryCategory* cat = getCategory();
if(cat)
{
std::string catName(cat->getName());
if ((catName == ROOT_FIRESTORM_FOLDER) || (catName == RLV_ROOT_FOLDER) || (catName == "#Phoenix"))
{
return SG_NORMAL_FOLDER;
}
}
}
//</FS:KC>
if(LLFolderType::lookupIsProtectedType(preferred_type))
{
return SG_SYSTEM_FOLDER;