summaryrefslogtreecommitdiff
path: root/indra/llui/llurlentry.cpp
diff options
context:
space:
mode:
authorBrad Payne (Vir Linden) <vir@lindenlab.com>2015-04-24 08:55:20 -0400
committerBrad Payne (Vir Linden) <vir@lindenlab.com>2015-04-24 08:55:20 -0400
commit3ae8a821c3b627f3b02df636e7649f28b97d6f57 (patch)
tree79d5d3f2b262b7f5d60cc6135b80221878aa74b8 /indra/llui/llurlentry.cpp
parent39b17157f9c31a4b911113561d4fc8f86396c430 (diff)
parentfde0868231a25b8c9ce03a86cb53f1738d35688d (diff)
merge
Diffstat (limited to 'indra/llui/llurlentry.cpp')
-rwxr-xr-xindra/llui/llurlentry.cpp28
1 files changed, 14 insertions, 14 deletions
diff --git a/indra/llui/llurlentry.cpp b/indra/llui/llurlentry.cpp
index e18d7405ab..5f60d80858 100755
--- a/indra/llui/llurlentry.cpp
+++ b/indra/llui/llurlentry.cpp
@@ -39,8 +39,6 @@
#include "lluicolortable.h"
#include "message.h"
-#include "uriparser/Uri.h"
-
#define APP_HEADER_REGEX "((x-grid-location-info://[-\\w\\.]+/app)|(secondlife:///app))"
// Utility functions
@@ -495,6 +493,17 @@ LLUrlEntrySecondlifeURL::LLUrlEntrySecondlifeURL()
mIcon = "Hand";
mMenuName = "menu_url_http.xml";
+ mTooltip = LLTrans::getString("TooltipHttpUrl");
+}
+
+/// Return the url from a string that matched the regex
+std::string LLUrlEntrySecondlifeURL::getUrl(const std::string &string) const
+{
+ if (string.find("://") == std::string::npos)
+ {
+ return "https://" + escapeUrl(string);
+ }
+ return escapeUrl(string);
}
std::string LLUrlEntrySecondlifeURL::getLabel(const std::string &url, const LLUrlLabelCallback &cb)
@@ -512,15 +521,6 @@ std::string LLUrlEntrySecondlifeURL::getTooltip(const std::string &url) const
return url;
}
-std::string LLUrlEntrySecondlifeURL::getUrl(const std::string &string) const
-{
- if (string.find("://") == std::string::npos)
- {
- return "http://" + escapeUrl(string);
- }
- return escapeUrl(string);
-}
-
//
// LLUrlEntrySimpleSecondlifeURL Describes *secondlife.com and *lindenlab.com urls to substitute icon 'hand.png' before link
//
@@ -1033,9 +1033,9 @@ void LLUrlEntryParcel::processParcelInfo(const LLParcelData& parcel_data)
// If parcel name is empty use Sim_name (x, y, z) for parcel label.
else if (!parcel_data.sim_name.empty())
{
- S32 region_x = llround(parcel_data.global_x) % REGION_WIDTH_UNITS;
- S32 region_y = llround(parcel_data.global_y) % REGION_WIDTH_UNITS;
- S32 region_z = llround(parcel_data.global_z);
+ S32 region_x = ll_round(parcel_data.global_x) % REGION_WIDTH_UNITS;
+ S32 region_y = ll_round(parcel_data.global_y) % REGION_WIDTH_UNITS;
+ S32 region_z = ll_round(parcel_data.global_z);
label = llformat("%s (%d, %d, %d)",
parcel_data.sim_name.c_str(), region_x, region_y, region_z);