LLFolderViewItem* LLLandmarksPanel::selectItemInAccordionTab(LLPlacesInventoryPanel* inventory_list, const std::string& tab_name, const LLUUID& obj_id, BOOL take_keyboard_focus) const { if (!inventory_list) return NULL; LLFolderView* root = inventory_list->getRootFolder(); LLFolderViewItem* item = inventory_list->getItemByID(obj_id); if (!item) return NULL; LLAccordionCtrlTab* tab = getChild<LLAccordionCtrlTab>(tab_name); if (!tab->isExpanded()) { tab->changeOpenClose(false); } root->setSelection(item, FALSE, take_keyboard_focus); LLAccordionCtrl* accordion = getChild<LLAccordionCtrl>("landmarks_accordion"); LLRect screen_rc; localRectToScreen(item->getRect(), &screen_rc); accordion->notifyParent(LLSD().with("scrollToShowRect", screen_rc.getValue())); return item; }