SL-19285 Add 'Close all windows' to Gear menu

meow-7.2.2
Maxim Nikolenko 2023-02-28 14:35:44 +02:00
parent 635fbc0eca
commit 46531cea84
2 changed files with 15 additions and 1 deletions

View File

@ -1489,6 +1489,20 @@ void LLPanelMainInventory::onCustomAction(const LLSD& userdata)
LLFloaterReg::showInstance("linkreplace", params);
}
if (command_name == "close_inv_windows")
{
LLFloaterReg::const_instance_list_t& inst_list = LLFloaterReg::getFloaterList("inventory");
for (LLFloaterReg::const_instance_list_t::const_iterator iter = inst_list.begin(); iter != inst_list.end();)
{
LLFloaterSidePanelContainer* iv = dynamic_cast<LLFloaterSidePanelContainer*>(*iter++);
if (iv)
{
iv->closeFloater();
}
}
LLFloaterReg::hideInstance("inventory_settings");
}
if (command_name == "toggle_search_outfits")
{
mActivePanel->getFilter().toggleSearchVisibilityOutfits();

View File

@ -16,7 +16,7 @@
parameter="new_window" />
</menu_item_call>
<menu_item_call
label="Close All Folders"
label="Collapse All Folders"
layout="topleft"
name="close_folders">
<on_click