summaryrefslogtreecommitdiff
path: root/indra/newview/llfacebookconnect.cpp
diff options
context:
space:
mode:
authorCho <cho@lindenlab.com>2013-07-17 02:59:40 +0100
committerCho <cho@lindenlab.com>2013-07-17 02:59:40 +0100
commit3d6a98d845c871377a52fc924ce06329db34a776 (patch)
tree3987e72c35cdb4a695f91a01383aae6d55628805 /indra/newview/llfacebookconnect.cpp
parentfdea8c66de408a2054bbe86b1967cea11409c313 (diff)
created floater_fbc_web for ACME-734 and ACME-735
Diffstat (limited to 'indra/newview/llfacebookconnect.cpp')
-rw-r--r--indra/newview/llfacebookconnect.cpp12
1 files changed, 10 insertions, 2 deletions
diff --git a/indra/newview/llfacebookconnect.cpp b/indra/newview/llfacebookconnect.cpp
index cf77dd365b..ac92fc6ed5 100644
--- a/indra/newview/llfacebookconnect.cpp
+++ b/indra/newview/llfacebookconnect.cpp
@@ -52,7 +52,7 @@ void log_facebook_connect_error(const std::string& request, U32 status, const st
// Note: 302 (redirect) is *not* an error that warrants logging
if (status != 302)
{
- LL_WARNS("FacebookConnect") << request << " request failed with a " << status << " " << reason << ". Reason: " << code << "(" << description << ")" << LL_ENDL;
+ LL_WARNS("FacebookConnect") << request << " request failed with a " << status << " " << reason << ". Reason: " << code << " (" << description << ")" << LL_ENDL;
}
}
@@ -76,10 +76,18 @@ public:
{
if (tokens[0].asString() == "connect")
{
+ // connect to facebook
if (query_map.has("code"))
{
LLFacebookConnect::instance().connectToFacebook(query_map["code"], query_map.get("state"));
}
+
+ // this command probably came from the fbc_web browser, so close it
+ LLFloater* fbc_web = LLFloaterReg::getInstance("fbc_web");
+ if (fbc_web)
+ {
+ fbc_web->closeFloater();
+ }
return true;
}
}
@@ -280,7 +288,7 @@ void LLFacebookConnect::openFacebookWeb(std::string url)
// Open the URL in an internal browser window without navigation UI
LLFloaterWebContent::Params p;
p.url(url).show_chrome(false);
- LLFloaterReg::showInstance("web_content", p);
+ LLFloaterReg::showInstance("fbc_web", p);
//LLUrlAction::openURLExternal(url);
}