From f26f7e3e29019abf3a10f6925e30baca19eb4e2d Mon Sep 17 00:00:00 2001 From: Steven Bennetts Date: Wed, 8 Jul 2009 05:19:19 +0000 Subject: merge -r 889-936 https://svn.aws.productengine.com/secondlife/pe/stable/ -> viewer-2-0 Also: * Moved media remote shortcut to Communicate menu * Changed mini map menu to toggle instead of show --- indra/newview/llpanelprofileview.cpp | 43 +++++++++--------------------------- 1 file changed, 11 insertions(+), 32 deletions(-) (limited to 'indra/newview/llpanelprofileview.cpp') diff --git a/indra/newview/llpanelprofileview.cpp b/indra/newview/llpanelprofileview.cpp index 495911c2e3..7d02c8ff0b 100644 --- a/indra/newview/llpanelprofileview.cpp +++ b/indra/newview/llpanelprofileview.cpp @@ -32,11 +32,10 @@ #include "llviewerprecompiledheaders.h" #include "llpanelprofileview.h" -#include -#include -#include + #include "llpanelavatar.h" #include "llpanelpicks.h" +#include "llpanelprofile.h" static LLRegisterPanelClassWrapper t_panel_target_profile("panel_profile_view"); static LLRegisterPanelClassWrapper t_panel_notes("panel_notes"); @@ -46,7 +45,7 @@ static std::string PANEL_PICKS = "panel_picks"; static std::string PANEL_NOTES = "panel_notes"; LLPanelProfileView::LLPanelProfileView() -: LLPanel() +: LLPanelProfile() { } @@ -57,35 +56,23 @@ LLPanelProfileView::~LLPanelProfileView(void) /*virtual*/ void LLPanelProfileView::onOpen(const LLSD& key) { - if (!getVisible()) - setVisible(TRUE); - - LLUUID id(key.asUUID()); - if(id.notNull() && mProfileId.notNull() && mProfileId != id) - { - mTabs[PANEL_PROFILE]->clear(); - mTabs[PANEL_PICKS]->clear(); - mTabs[PANEL_NOTES]->clear(); - } - - mProfileId = id; - mTabs[PANEL_PROFILE]->onOpen(mProfileId); - mTabs[PANEL_PICKS]->onActivate(mProfileId); - mTabs[PANEL_NOTES]->onActivate(mProfileId); + LLPanelProfile::onOpen(key); + + //*NOTE profile view panel doesn't have own side tray tab and + //is usually opened over People side tray tab. By Back button + // Profile View panel just becomes invisible, see onBackBtnClick() + setVisible(TRUE); std::string full_name; - gCacheName->getFullName(key,full_name); + gCacheName->getFullName(key["id"],full_name); childSetValue("user_name",full_name); } BOOL LLPanelProfileView::postBuild() { - mTabContainer = getChild("profile_tabs"); - mTabContainer->setCommitCallback(boost::bind(&LLPanelProfileView::onTabSelected, this, _2)); + LLPanelProfile::postBuild(); - mTabs[PANEL_PROFILE] = (getChild(PANEL_PROFILE)); - mTabs[PANEL_PICKS] = (getChild(PANEL_PICKS)); mTabs[PANEL_NOTES] = (getChild(PANEL_NOTES)); childSetCommitCallback("back",boost::bind(&LLPanelProfileView::onBackBtnClick,this),NULL); @@ -96,14 +83,6 @@ BOOL LLPanelProfileView::postBuild() //private -void LLPanelProfileView::initTabs(const LLSD& key) -{ -} - -void LLPanelProfileView::onTabSelected(const LLSD& param) -{ -} - void LLPanelProfileView::onBackBtnClick() { setVisible(FALSE); -- cgit v1.2.3