From 47918f4537ee924c4cb9652a72561b5febbddeb6 Mon Sep 17 00:00:00 2001
From: Cho <cho@lindenlab.com>
Date: Wed, 13 Nov 2013 18:44:33 +0000
Subject: [PATCH] changed Twitter photo character limit to 100 just to be safe,
 and switched to use cap server for Flickr and Twitter service

---
 indra/newview/llflickrconnect.cpp                          | 4 ++--
 indra/newview/llfloaterflickr.cpp                          | 4 +++-
 indra/newview/llfloatertwitter.cpp                         | 2 +-
 indra/newview/lltwitterconnect.cpp                         | 4 ++--
 indra/newview/skins/default/xui/en/panel_twitter_photo.xml | 2 +-
 5 files changed, 9 insertions(+), 7 deletions(-)

diff --git a/indra/newview/llflickrconnect.cpp b/indra/newview/llflickrconnect.cpp
index 3da3ef22b2c..3a21933b635 100644
--- a/indra/newview/llflickrconnect.cpp
+++ b/indra/newview/llflickrconnect.cpp
@@ -296,8 +296,8 @@ std::string LLFlickrConnect::getFlickrConnectURL(const std::string& route, bool
     LLViewerRegion *regionp = gAgent.getRegion();
     if (regionp)
     {
-		url = "http://pdp15.lindenlab.com/flickr/agent/" + gAgentID.asString(); // TEMPORARY FOR TESTING - CHO
-        //url = regionp->getCapability("FlickrConnect");
+		//url = "http://pdp15.lindenlab.com/flickr/agent/" + gAgentID.asString(); // TEMPORARY FOR TESTING - CHO
+        url = regionp->getCapability("FlickrConnect");
         url += route;
     
         if (include_read_from_master && mReadFromMaster)
diff --git a/indra/newview/llfloaterflickr.cpp b/indra/newview/llfloaterflickr.cpp
index 7140b527b92..0bfbd02a045 100644
--- a/indra/newview/llfloaterflickr.cpp
+++ b/indra/newview/llfloaterflickr.cpp
@@ -261,11 +261,13 @@ void LLFlickrPhotoPanel::sendPhoto()
 		// Add query parameters so Google Analytics can track incoming clicks!
 		slurl_string += DEFAULT_PHOTO_QUERY_PARAMETERS;
 
+		slurl_string = "<a href=\"" + slurl_string + "\">VISIT THIS LOCATION</a>";
+
 		// Add it to the description (pretty crude, but we don't have a better option with photos)
 		if (description.empty())
 			description = slurl_string;
 		else
-			description = description + " " + slurl_string;
+			description = description + "\n\n" + slurl_string;
 	}
 
 	// Get the content rating
diff --git a/indra/newview/llfloatertwitter.cpp b/indra/newview/llfloatertwitter.cpp
index 46cad7ec450..6f8ad109c6c 100644
--- a/indra/newview/llfloatertwitter.cpp
+++ b/indra/newview/llfloatertwitter.cpp
@@ -117,7 +117,7 @@ void LLTwitterPhotoPanel::draw()
 	LLTextEditor* status_text_box = dynamic_cast<LLTextEditor*>(mStatusTextBox);
 	if (status_text_box)
 	{
-		int max_status_length = add_photo ? 119 : 140;
+		int max_status_length = add_photo ? 100 : 140;
 		status_text_box->setMaxTextLength(max_status_length);
 		if (status_text_box->getText().length() > max_status_length)
 		{
diff --git a/indra/newview/lltwitterconnect.cpp b/indra/newview/lltwitterconnect.cpp
index fe45d3e4d0f..e015867df2b 100644
--- a/indra/newview/lltwitterconnect.cpp
+++ b/indra/newview/lltwitterconnect.cpp
@@ -296,8 +296,8 @@ std::string LLTwitterConnect::getTwitterConnectURL(const std::string& route, boo
     LLViewerRegion *regionp = gAgent.getRegion();
     if (regionp)
     {
-		url = "http://pdp15.lindenlab.com/twitter/agent/" + gAgentID.asString(); // TEMPORARY FOR TESTING - CHO
-        //url = regionp->getCapability("TwitterConnect");
+		//url = "http://pdp15.lindenlab.com/twitter/agent/" + gAgentID.asString(); // TEMPORARY FOR TESTING - CHO
+        url = regionp->getCapability("TwitterConnect");
         url += route;
     
         if (include_read_from_master && mReadFromMaster)
diff --git a/indra/newview/skins/default/xui/en/panel_twitter_photo.xml b/indra/newview/skins/default/xui/en/panel_twitter_photo.xml
index fd2bffe675d..8e2412c84e5 100644
--- a/indra/newview/skins/default/xui/en/panel_twitter_photo.xml
+++ b/indra/newview/skins/default/xui/en/panel_twitter_photo.xml
@@ -31,7 +31,7 @@
            width="250"
            left="9"
            length="1"
-           max_length="119"
+           max_length="140"
            name="photo_status"
            type="string"
            word_wrap="true">
-- 
GitLab