diff options
-rw-r--r-- | indra/newview/llavataractions.cpp | 5 | ||||
-rw-r--r-- | indra/newview/llavataractions.h | 2 | ||||
-rw-r--r-- | indra/newview/llpanelprofile.cpp | 18 |
3 files changed, 10 insertions, 15 deletions
diff --git a/indra/newview/llavataractions.cpp b/indra/newview/llavataractions.cpp index ff00157459..bc9dc968f2 100644 --- a/indra/newview/llavataractions.cpp +++ b/indra/newview/llavataractions.cpp @@ -83,12 +83,13 @@ const U32 KICK_FLAGS_FREEZE = 1 << 0; const U32 KICK_FLAGS_UNFREEZE = 1 << 1; -std::string getProfileURL(const std::string& agent_name) +std::string getProfileURL(const std::string& agent_name, bool feed_only) { - std::string url = "[WEB_PROFILE_URL][AGENT_NAME]"; + std::string url = "[WEB_PROFILE_URL][AGENT_NAME][FEED_ONLY]"; LLSD subs; subs["WEB_PROFILE_URL"] = LLGridManager::getInstance()->getWebProfileURL(); subs["AGENT_NAME"] = agent_name; + subs["FEED_ONLY"] = feed_only ? "/?feed_only=true" : ""; url = LLWeb::expandURLSubstitutions(url, subs); LLStringUtil::toLower(url); return url; diff --git a/indra/newview/llavataractions.h b/indra/newview/llavataractions.h index 7dd358309c..ff2617bcdd 100644 --- a/indra/newview/llavataractions.h +++ b/indra/newview/llavataractions.h @@ -38,7 +38,7 @@ class LLInventoryPanel; class LLFloater; class LLView; -std::string getProfileURL(const std::string& agent_name); +std::string getProfileURL(const std::string& agent_name, bool feed_only = false); /** * Friend-related actions (add, remove, offer teleport, etc) diff --git a/indra/newview/llpanelprofile.cpp b/indra/newview/llpanelprofile.cpp index 1b3462176e..1620a01d1c 100644 --- a/indra/newview/llpanelprofile.cpp +++ b/indra/newview/llpanelprofile.cpp @@ -904,16 +904,13 @@ void LLPanelProfileWeb::apply(LLAvatarData* data) void LLPanelProfileWeb::updateData() { LLUUID avatar_id = getAvatarId(); - if (!getIsLoading() && avatar_id.notNull()) + if (!getIsLoading() && avatar_id.notNull() && !mURLWebProfile.empty()) { setIsLoading(); - if (!mURLWebProfile.empty()) - { - mWebBrowser->setVisible(TRUE); - mPerformanceTimer.start(); - mWebBrowser->navigateTo(mURLWebProfile, HTTP_CONTENT_TEXT_HTML); - } + mWebBrowser->setVisible(TRUE); + mPerformanceTimer.start(); + mWebBrowser->navigateTo(mURLWebProfile, HTTP_CONTENT_TEXT_HTML); } } @@ -931,17 +928,14 @@ void LLPanelProfileWeb::onAvatarNameCache(const LLUUID& agent_id, const LLAvatar LLStringUtil::replaceChar(username, ' ', '.'); } - mURLWebProfile = getProfileURL(username); + mURLWebProfile = getProfileURL(username, true); if (mURLWebProfile.empty()) { return; } //if the tab was opened before name was resolved, load the panel now - if (getIsLoading()) - { - updateData(); - } + updateData(); } void LLPanelProfileWeb::onCommitLoad(LLUICtrl* ctrl) |