summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
authorCho <cho@lindenlab.com>2013-05-29 01:31:48 +0100
committerCho <cho@lindenlab.com>2013-05-29 01:31:48 +0100
commitff291257886badc495d04d59f78cfc9858964702 (patch)
tree64577ef8210747914f4df2eb9febffeed05088d5 /indra/newview
parent1c740dfb516aa03ea07d37f12de8a98b94be9572 (diff)
updated postCheckinMessage to use new parameters and new route path
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/llfacebookconnect.cpp20
-rw-r--r--indra/newview/llfacebookconnect.h2
-rwxr-xr-xindra/newview/llpanelpeople.cpp2
3 files changed, 15 insertions, 9 deletions
diff --git a/indra/newview/llfacebookconnect.cpp b/indra/newview/llfacebookconnect.cpp
index eb70cf4d10..86da748f0f 100644
--- a/indra/newview/llfacebookconnect.cpp
+++ b/indra/newview/llfacebookconnect.cpp
@@ -276,18 +276,24 @@ void LLFacebookConnect::loadFacebookFriends()
LLSD(), timeout, follow_redirects);
}
-void LLFacebookConnect::postCheckinMessage(const std::string& message, const std::string& url)
+void LLFacebookConnect::postCheckinMessage(const std::string& message, const std::string& link, const std::string& name, const std::string& caption, const std::string& description, const std::string& picture)
{
- // Note: We need to improve the API support to provide all the relevant data if possible
- // Full set described : http://facebook-python-library.docs-library.appspot.com/facebook-python/library-manual.html
- LLSD body;
+ LLSD body;
if (!message.empty())
body["message"] = message;
- if (!url.empty())
- body["link"] = url;
+ if (!link.empty())
+ body["link"] = link;
+ if (!name.empty())
+ body["name"] = name;
+ if (!caption.empty())
+ body["caption"] = caption;
+ if (!description.empty())
+ body["description"] = description;
+ if (!picture.empty())
+ body["picture"] = picture;
// Note: we can use that route for different publish action. We should be able to use the same responder.
- LLHTTPClient::post(getFacebookConnectURL("/share"), body, new LLFacebookPostResponder());
+ LLHTTPClient::post(getFacebookConnectURL("/share/wall"), body, new LLFacebookPostResponder());
}
void LLFacebookConnect::storeContent(const LLSD& content)
diff --git a/indra/newview/llfacebookconnect.h b/indra/newview/llfacebookconnect.h
index f151dd95c1..8886630222 100644
--- a/indra/newview/llfacebookconnect.h
+++ b/indra/newview/llfacebookconnect.h
@@ -46,7 +46,7 @@ public:
void getConnectionToFacebook();
void loadFacebookFriends();
- void postCheckinMessage(const std::string& message, const std::string& url);
+ void postCheckinMessage(const std::string& message, const std::string& link, const std::string& name, const std::string& caption, const std::string& description, const std::string& picture);
void clearContent();
void storeContent(const LLSD& content);
diff --git a/indra/newview/llpanelpeople.cpp b/indra/newview/llpanelpeople.cpp
index e0b1c3abba..69b6bdf737 100755
--- a/indra/newview/llpanelpeople.cpp
+++ b/indra/newview/llpanelpeople.cpp
@@ -1726,7 +1726,7 @@ void LLPanelPeople::onFacebookCheckinClicked()
LLSLURL slurl;
LLAgentUI::buildSLURL(slurl);
- LLFacebookConnect::instance().postCheckinMessage("Here I am in SL!", slurl.getSLURLString());
+ LLFacebookConnect::instance().postCheckinMessage("Here I am in SL!", slurl.getSLURLString(), slurl.getRegion(), "", "", "");
}
void LLPanelPeople::onFacebookAppRequestClicked()