diff options
author | Tofu Linden <tofu.linden@lindenlab.com> | 2010-03-17 19:05:33 +0000 |
---|---|---|
committer | Tofu Linden <tofu.linden@lindenlab.com> | 2010-03-17 19:05:33 +0000 |
commit | 0a35c31e51cbb2f407d87db14d40a08a91963c81 (patch) | |
tree | e3a6f7e3c512850f05bf66ffb89c4113d63d223f /indra/newview/llpanellandmarks.cpp | |
parent | c17152c21eff9a165c92c8bf07678c4bca1c8a99 (diff) | |
parent | 03f58118ce4c367bffe26ffc968a529e81331d4b (diff) |
PE merge
Diffstat (limited to 'indra/newview/llpanellandmarks.cpp')
-rw-r--r-- | indra/newview/llpanellandmarks.cpp | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/indra/newview/llpanellandmarks.cpp b/indra/newview/llpanellandmarks.cpp index 879fbba9cd..4842fcac38 100644 --- a/indra/newview/llpanellandmarks.cpp +++ b/indra/newview/llpanellandmarks.cpp @@ -534,7 +534,7 @@ void LLLandmarksPanel::initLandmarksInventoryPanel() // subscribe to have auto-rename functionality while creating New Folder mLandmarksInventoryPanel->setSelectCallback(boost::bind(&LLInventoryPanel::onSelectionChange, mLandmarksInventoryPanel, _1, _2)); - initAccordion("tab_landmarks", mLandmarksInventoryPanel, true); + mMyLandmarksAccordionTab = initAccordion("tab_landmarks", mLandmarksInventoryPanel, true); } void LLLandmarksPanel::initMyInventoryPanel() @@ -588,7 +588,7 @@ void LLLandmarksPanel::initLandmarksPanel(LLPlacesInventoryPanel* inventory_list inventory_list->saveFolderState(); } -void LLLandmarksPanel::initAccordion(const std::string& accordion_tab_name, LLPlacesInventoryPanel* inventory_list, bool expand_tab) +LLAccordionCtrlTab* LLLandmarksPanel::initAccordion(const std::string& accordion_tab_name, LLPlacesInventoryPanel* inventory_list, bool expand_tab) { LLAccordionCtrlTab* accordion_tab = getChild<LLAccordionCtrlTab>(accordion_tab_name); @@ -596,6 +596,7 @@ void LLLandmarksPanel::initAccordion(const std::string& accordion_tab_name, LLPl accordion_tab->setDropDownStateChangedCallback( boost::bind(&LLLandmarksPanel::onAccordionExpandedCollapsed, this, _2, inventory_list)); accordion_tab->setDisplayChildren(expand_tab); + return accordion_tab; } void LLLandmarksPanel::onAccordionExpandedCollapsed(const LLSD& param, LLPlacesInventoryPanel* inventory_list) @@ -776,6 +777,11 @@ void LLLandmarksPanel::onAddAction(const LLSD& userdata) const //in case My Landmarks tab is completely empty (thus cannot be determined as being selected) menu_create_inventory_item(mLandmarksInventoryPanel->getRootFolder(), NULL, LLSD("category"), gInventory.findCategoryUUIDForType(LLFolderType::FT_LANDMARK)); + + if (mMyLandmarksAccordionTab) + { + mMyLandmarksAccordionTab->changeOpenClose(false); + } } } } |