diff options
author | Kent Quirk <q@lindenlab.com> | 2010-11-05 18:39:26 -0400 |
---|---|---|
committer | Kent Quirk <q@lindenlab.com> | 2010-11-05 18:39:26 -0400 |
commit | bc7b6411d9148f918be3f781c55459d044288b6a (patch) | |
tree | 9ed2e3a06e434436ae7de34f8ffec2a5adee843a /indra/llui | |
parent | 049a1a8e3827381d7e09faafc7088f81520e0ea9 (diff) |
SEC-784
Diffstat (limited to 'indra/llui')
-rw-r--r-- | indra/llui/llurlentry.cpp | 8 | ||||
-rw-r--r-- | indra/llui/llurlentry.h | 1 |
2 files changed, 8 insertions, 1 deletions
diff --git a/indra/llui/llurlentry.cpp b/indra/llui/llurlentry.cpp index f58c07754f..efb3f1a8be 100644 --- a/indra/llui/llurlentry.cpp +++ b/indra/llui/llurlentry.cpp @@ -209,7 +209,13 @@ LLUrlEntryHTTPLabel::LLUrlEntryHTTPLabel() std::string LLUrlEntryHTTPLabel::getLabel(const std::string &url, const LLUrlLabelCallback &cb) { - return getLabelFromWikiLink(url); + std::string label = getLabelFromWikiLink(url); + return (!LLUrlRegistry::instance().hasUrl(label)) ? label : getUrl(url); +} + +std::string LLUrlEntryHTTPLabel::getTooltip(const std::string &string) const +{ + return getUrl(string); } std::string LLUrlEntryHTTPLabel::getUrl(const std::string &string) const diff --git a/indra/llui/llurlentry.h b/indra/llui/llurlentry.h index f6424c28b8..9b91c103ef 100644 --- a/indra/llui/llurlentry.h +++ b/indra/llui/llurlentry.h @@ -133,6 +133,7 @@ class LLUrlEntryHTTPLabel : public LLUrlEntryBase public: LLUrlEntryHTTPLabel(); /*virtual*/ std::string getLabel(const std::string &url, const LLUrlLabelCallback &cb); + /*virtual*/ std::string getTooltip(const std::string &string) const; /*virtual*/ std::string getUrl(const std::string &string) const; }; |