summaryrefslogtreecommitdiff
path: root/indra/newview/llpanellandmarks.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llpanellandmarks.cpp')
-rw-r--r--indra/newview/llpanellandmarks.cpp11
1 files changed, 9 insertions, 2 deletions
diff --git a/indra/newview/llpanellandmarks.cpp b/indra/newview/llpanellandmarks.cpp
index ccd8497484..d763a6e1ec 100644
--- a/indra/newview/llpanellandmarks.cpp
+++ b/indra/newview/llpanellandmarks.cpp
@@ -65,6 +65,7 @@ static const std::string ADD_BUTTON_NAME = "add_btn";
static const std::string ADD_FOLDER_BUTTON_NAME = "add_folder_btn";
static const std::string TRASH_BUTTON_NAME = "trash_btn";
+static const std::string TAB_FAVORITES = "tab_favorites";
// helper functions
static void filter_list(LLPlacesInventoryPanel* inventory_list, const std::string& string);
@@ -383,7 +384,7 @@ void LLLandmarksPanel::updateShowFolderState()
void LLLandmarksPanel::setItemSelected(const LLUUID& obj_id, BOOL take_keyboard_focus)
{
- if (selectItemInAccordionTab(mFavoritesInventoryPanel, "tab_favorites", obj_id, take_keyboard_focus))
+ if (selectItemInAccordionTab(mFavoritesInventoryPanel, TAB_FAVORITES, obj_id, take_keyboard_focus))
{
return;
}
@@ -506,6 +507,12 @@ void LLLandmarksPanel::updateSortOrder(LLInventoryPanel* panel, bool byDate)
}
}
+void LLLandmarksPanel::resetSelection()
+{
+ getChild<LLAccordionCtrlTab>(TAB_FAVORITES)->setDisplayChildren(true);
+ getChild<LLAccordionCtrlTab>(TAB_FAVORITES)->showAndFocusHeader();
+}
+
// virtual
void LLLandmarksPanel::processParcelInfo(const LLParcelData& parcel_data)
{
@@ -550,7 +557,7 @@ void LLLandmarksPanel::initFavoritesInventoryPanel()
initLandmarksPanel(mFavoritesInventoryPanel);
mFavoritesInventoryPanel->getFilter().setEmptyLookupMessage("FavoritesNoMatchingItems");
- initAccordion("tab_favorites", mFavoritesInventoryPanel, true);
+ initAccordion(TAB_FAVORITES, mFavoritesInventoryPanel, true);
}
void LLLandmarksPanel::initLandmarksInventoryPanel()