summaryrefslogtreecommitdiff
path: root/indra/newview/llclassifiedstatsresponder.cpp
diff options
context:
space:
mode:
authorJosh Bell <josh@lindenlab.com>2007-11-01 22:02:35 +0000
committerJosh Bell <josh@lindenlab.com>2007-11-01 22:02:35 +0000
commit7afa8058aae0d5363cc19c7df1e6d2d7ec3bf7ac (patch)
tree52f41bda3e57a58e968421212a8a48eead6f653d /indra/newview/llclassifiedstatsresponder.cpp
parent833e8d5c2a1dd48fd89b8b438dbe56572697bb76 (diff)
svn merge -r 72652:72881 svn+ssh://svn.lindenlab.com/svn/linden/branches/sl-search-11 --> release
QAR-11: pair-reviewed the merge w/ Sam.
Diffstat (limited to 'indra/newview/llclassifiedstatsresponder.cpp')
-rw-r--r--indra/newview/llclassifiedstatsresponder.cpp57
1 files changed, 57 insertions, 0 deletions
diff --git a/indra/newview/llclassifiedstatsresponder.cpp b/indra/newview/llclassifiedstatsresponder.cpp
new file mode 100644
index 0000000000..3a31074ed0
--- /dev/null
+++ b/indra/newview/llclassifiedstatsresponder.cpp
@@ -0,0 +1,57 @@
+/**
+ * @file llparcelrequest.cpp
+ * @brief Implementation of the LLParcelRequest class.
+ *
+ * Copyright (c) 2006-$CurrentYear$, Linden Research, Inc.
+ * $License$
+ */
+
+#include "llviewerprecompiledheaders.h"
+
+#include "llagent.h"
+#include "llclassifiedstatsresponder.h"
+
+#include "llpanelclassified.h"
+#include "llpanel.h"
+#include "llhttpclient.h"
+#include "llsdserialize.h"
+#include "llviewerregion.h"
+#include "llview.h"
+#include "message.h"
+
+LLClassifiedStatsResponder::LLClassifiedStatsResponder(LLViewHandle classified_panel_handle)
+: mClassifiedPanelHandle(classified_panel_handle)
+{
+}
+/*virtual*/
+void LLClassifiedStatsResponder::result(const LLSD& content)
+{
+ LLUUID classified_id = content["classified_id"];
+ S32 teleport = content["teleport_clicks"].asInteger();
+ S32 map = content["map_clicks"].asInteger();
+ S32 profile = content["profile_clicks"].asInteger();
+ S32 search_teleport = content["search_teleport_clicks"].asInteger();
+ S32 search_map = content["search_map_clicks"].asInteger();
+ S32 search_profile = content["search_profile_clicks"].asInteger();
+
+ std::string msg = llformat("Clicks: %d teleport, %d map, %d profile",
+ teleport + search_teleport,
+ map + search_map,
+ profile + search_profile);
+
+ LLPanelClassified* classified_panelp = (LLPanelClassified*)LLPanel::getPanelByHandle(mClassifiedPanelHandle);
+
+ if(classified_panelp)
+ {
+ classified_panelp->setClickThroughText(msg);
+ }
+
+}
+
+/*virtual*/
+void LLClassifiedStatsResponder::error(U32 status, const std::string& reason)
+{
+ llinfos << "LLClassifiedStatsResponder::error("
+ << status << ": " << reason << ")" << llendl;
+}
+