summaryrefslogtreecommitdiff
path: root/indra/newview/llagent.h
diff options
context:
space:
mode:
authorTodd Stinson <stinson@lindenlab.com>2012-05-24 19:41:20 -0700
committerTodd Stinson <stinson@lindenlab.com>2012-05-24 19:41:20 -0700
commit55392ef7f6499c639b10e56646cf535742152682 (patch)
tree99fb336c7953ffbf966c20dde07d5854d7a1a4a3 /indra/newview/llagent.h
parent9b27e32a8d73e2f50a86562cf79f4ef637e83dae (diff)
EXP-1942,EXP-1945: Altering behavior when setting maturity preference to check the server response in an effort to ensure the viewer and server remain in sync. This is a partial commit as I still need to add user behavior and notifications when things go wrong.
Diffstat (limited to 'indra/newview/llagent.h')
-rw-r--r--indra/newview/llagent.h15
1 files changed, 12 insertions, 3 deletions
diff --git a/indra/newview/llagent.h b/indra/newview/llagent.h
index 1ca12f14b7..67f7c9c4f4 100644
--- a/indra/newview/llagent.h
+++ b/indra/newview/llagent.h
@@ -694,12 +694,21 @@ public:
typedef boost::function<void (U8)> maturity_preferences_callback_t;
void setMaturityPreferenceAndConfirm(U32 preferredMaturity, maturity_preferences_callback_t pMaturityPreferencesCallback);
private:
+ bool mIsDoSendMaturityPreferenceToServer;
maturity_preferences_callback_t mMaturityPreferenceConfirmCallback;
- bool sendMaturityPreferenceToServer(int preferredMaturity); // ! "U8" instead of "int"?
+ unsigned int mMaturityPerferenceMessageId;
+ boost::signals2::connection mPreferredMaturityValidateSlot;
+ boost::signals2::connection mPreferredMaturityCommitSlot;
+
+ void sendMaturityPreferenceToServer(U8 pPreferredMaturity, U8 pPreviousMaturity); // ! "U8" instead of "int"?
+
+ friend class LLMaturityPreferencesResponder;
+ void handlePreferredMaturityResult(unsigned int pMessageId, U8 pServerMaturity);
+ void handlePreferredMaturityError(unsigned int pMessageId, U8 pPreferredMaturity, U8 pPreviousMaturity);
+ void handlePreferredMaturityUnexpectedResult(unsigned int pMessageId, U8 pPreferredMaturity, U8 pPreviousMaturity, U8 pServerMaturity);
-public:
// Maturity callbacks for PreferredMaturity control variable
- void handleMaturity(const LLSD& newvalue);
+ void handleMaturity(const LLSD &pNewValue, const LLSD &pPreviousValue);
bool validateMaturity(const LLSD& newvalue);