summaryrefslogtreecommitdiff
path: root/indra/newview/llfacebookconnect.h
diff options
context:
space:
mode:
authorGilbert Gonzales <gilbert@lindenlab.com>2013-07-31 19:04:45 -0700
committerGilbert Gonzales <gilbert@lindenlab.com>2013-07-31 19:04:45 -0700
commita2b1e06c3def4a8a97a41f3379c336864ede21f8 (patch)
tree878f1ce1d9c2f90812b250a643cf893cf4282850 /indra/newview/llfacebookconnect.h
parentd0764f57a5b9591b452b6718d53a8169499e1856 (diff)
ACME-778: Adjusted the facebook code so that isConnected() does not depend on state changes. Instead it returns true if the user successfully connected and false if the user successfully disconnected.
Diffstat (limited to 'indra/newview/llfacebookconnect.h')
-rw-r--r--indra/newview/llfacebookconnect.h9
1 files changed, 6 insertions, 3 deletions
diff --git a/indra/newview/llfacebookconnect.h b/indra/newview/llfacebookconnect.h
index be3028e3a0..b9afd181e9 100644
--- a/indra/newview/llfacebookconnect.h
+++ b/indra/newview/llfacebookconnect.h
@@ -52,7 +52,8 @@ public:
FB_POSTING = 4,
FB_POSTED = 5,
FB_POST_FAILED = 6,
- FB_DISCONNECTING = 7
+ FB_DISCONNECTING = 7,
+ FB_DISCONNECT_FAILED = 8
};
void connectToFacebook(const std::string& auth_code = "", const std::string& auth_state = ""); // Initiate the complete FB connection. Please use checkConnectionToFacebook() in normal use.
@@ -73,8 +74,9 @@ public:
const LLSD& getContent() const;
void setConnectionState(EConnectionState connection_state);
- bool isConnected() { return ((mConnectionState == FB_CONNECTED) || (mConnectionState == FB_DISCONNECTING) || (mConnectionState == FB_POSTING) || (mConnectionState == FB_POSTED)); }
- bool isTransactionOngoing() { return ((mConnectionState == FB_CONNECTION_IN_PROGRESS) || (mConnectionState == FB_POSTING)); }
+ void setConnected(bool connected);
+ bool isConnected() { return mConnected; }
+ bool isTransactionOngoing() { return ((mConnectionState == FB_CONNECTION_IN_PROGRESS) || (mConnectionState == FB_POSTING) || (mConnectionState == FB_DISCONNECTING)); }
EConnectionState getConnectionState() { return mConnectionState; }
S32 generation() { return mGeneration; }
@@ -88,6 +90,7 @@ private:
std::string getFacebookConnectURL(const std::string& route = "");
EConnectionState mConnectionState;
+ BOOL mConnected;
LLSD mInfo;
LLSD mContent;
S32 mGeneration;