diff options
author | Cho <cho@lindenlab.com> | 2013-12-10 18:55:49 +0000 |
---|---|---|
committer | Cho <cho@lindenlab.com> | 2013-12-10 18:55:49 +0000 |
commit | 88f139594bb819bc31b438edcceaf9cd661b3f82 (patch) | |
tree | fbeeff278d960ff95df30b67c89e94a8a8a05b4a /indra/newview | |
parent | 11e3f8c3a1209c17814d90978a1c0b80225bc122 (diff) |
Added placeholder http SLURL for Twitter sharing on Aditi for ACME-1216
Diffstat (limited to 'indra/newview')
-rw-r--r-- | indra/newview/llfloatertwitter.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/indra/newview/llfloatertwitter.cpp b/indra/newview/llfloatertwitter.cpp index 18a1fcbba9..ea263566a6 100644 --- a/indra/newview/llfloatertwitter.cpp +++ b/indra/newview/llfloatertwitter.cpp @@ -53,6 +53,7 @@ static LLRegisterPanelClassWrapper<LLTwitterPhotoPanel> t_panel_photo("lltwitter static LLRegisterPanelClassWrapper<LLTwitterAccountPanel> t_panel_account("lltwitteraccountpanel"); const S32 MAX_POSTCARD_DATASIZE = 1024 * 1024; // one megabyte +const std::string DEFAULT_PHOTO_LOCATION_URL = "http://maps.secondlife.com/"; const std::string DEFAULT_PHOTO_QUERY_PARAMETERS = "?sourceid=slshare_photo&utm_source=twitter&utm_medium=photo&utm_campaign=slshare"; /////////////////////////// @@ -271,6 +272,13 @@ void LLTwitterPhotoPanel::sendPhoto() LLAgentUI::buildSLURL(slurl); std::string slurl_string = slurl.getSLURLString(); + // Use a valid http:// URL if the scheme is secondlife:// + LLURI slurl_uri(slurl_string); + if (slurl_uri.scheme() == LLSLURL::SLURL_SECONDLIFE_SCHEME) + { + slurl_string = DEFAULT_PHOTO_LOCATION_URL; + } + // Add query parameters so Google Analytics can track incoming clicks! slurl_string += DEFAULT_PHOTO_QUERY_PARAMETERS; @@ -281,7 +289,6 @@ void LLTwitterPhotoPanel::sendPhoto() status = status + " " + slurl_string; } - // Add the photo if required bool add_photo = mPhotoCheckbox->getValue().asBoolean(); if (add_photo) |