void LLPanelGroup::onOpen(const LLSD& key) { if(!key.has("group_id")) return; // open the desired panel if (key.has("open_tab_name")) { // onOpen from selected panel will be called from onTabSelected callback LLTabContainer* tab_ctrl = getChild<LLTabContainer>("groups_accordion"); tab_ctrl->selectTabByName(key["open_tab_name"]); } LLUUID group_id = key["group_id"]; if(!key.has("action")) { setGroupID(group_id); getChild<LLAccordionCtrl>("groups_accordion")->expandDefaultTab(); return; } std::string str_action = key["action"]; if(str_action == "refresh") { if(mID == group_id || group_id == LLUUID::null) refreshData(); } else if(str_action == "close") { onBackBtnClick(); } else if(str_action == "create") { setGroupID(LLUUID::null); } else if(str_action == "refresh_notices") { LLPanelGroupNotices* panel_notices = findChild<LLPanelGroupNotices>("group_notices_tab_panel"); if(panel_notices) panel_notices->refreshNotices(); } }
void LLPanelGroup::onOpen(const LLSD& key) { if(!key.has("group_id")) return; LLUUID group_id = key["group_id"]; if(!key.has("action")) { setGroupID(group_id); getChild<LLAccordionCtrl>("groups_accordion")->expandDefaultTab(); return; } std::string str_action = key["action"]; if(str_action == "refresh") { if(mID == group_id || group_id == LLUUID::null) refreshData(); } else if(str_action == "close") { onBackBtnClick(); } else if(str_action == "create") { setGroupID(LLUUID::null); } else if(str_action == "refresh_notices") { LLPanelGroupNotices* panel_notices = findChild<LLPanelGroupNotices>("group_notices_tab_panel"); if(panel_notices) panel_notices->refreshNotices(); } }
void LLPanelGroup::onBtnCancel() { onBackBtnClick(); }