summaryrefslogtreecommitdiff
path: root/protocols/Steam
diff options
context:
space:
mode:
authorRobert Pösel <robyer@seznam.cz>2016-11-22 09:45:49 +0100
committerGitHub <noreply@github.com>2016-11-22 09:45:49 +0100
commit5e7f1af9e78f7f7ae019a03ba34c9ae7ea72cdff (patch)
treef723a38c10f49980157f850b2cd2c44b66e5f89d /protocols/Steam
parent668495e396bf9752411d1f134f88da4ff3b88b0a (diff)
Steam: Small workaround for #633
Diffstat (limited to 'protocols/Steam')
-rw-r--r--protocols/Steam/src/steam_polling.cpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/protocols/Steam/src/steam_polling.cpp b/protocols/Steam/src/steam_polling.cpp
index eb5db69c3c..cdfcfd797d 100644
--- a/protocols/Steam/src/steam_polling.cpp
+++ b/protocols/Steam/src/steam_polling.cpp
@@ -5,6 +5,9 @@
void CSteamProto::ParsePollData(JSONNode *data)
{
JSONNode *node, *item = NULL;
+
+ // FIXME: Temporary solution for receivng too many duplicated typing events; should be reworked better
+ std::string typingUser;
std::string steamIds;
for (size_t i = 0; i < json_size(data); i++)
@@ -47,6 +50,11 @@ void CSteamProto::ParsePollData(JSONNode *data)
}
else if (!lstrcmpi(type, L"typing"))
{
+ // FIXME: Temporary solution for receivng too many duplicated typing events; should be reworked better
+ if (typingUser == steamId)
+ continue;
+ typingUser = steamId;
+
MCONTACT hContact = FindContact(steamId);
if (hContact)
{
@@ -301,4 +309,4 @@ void CSteamProto::PollingThread(void*)
m_hPollingThread = NULL;
debugLogW(L"CSteamProto::PollingThread: leaving");
-} \ No newline at end of file
+}