From 48266e479d1fcf5153b29c612866845990fccad8 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Thu, 21 May 2015 16:11:58 +0000 Subject: war against atavisms continues - everything that goes to PSS_MESSAGE should be sent as utf8 string; - thus PREF_UNICODE & PREF_UTF support discontinued, these constants are removed; - support for PREF_UNICODE & PREF_UTF in protocols also removed; - PREF_UNICODE used in file transfers (PROTOFILERECVT) replaced with PRFF_UNICODE / PRFF_TCHAR git-svn-id: http://svn.miranda-ng.org/main/trunk@13734 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/Twitter/src/proto.cpp | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) (limited to 'protocols/Twitter/src/proto.cpp') diff --git a/protocols/Twitter/src/proto.cpp b/protocols/Twitter/src/proto.cpp index 820c67d1e2..dd28a80e25 100644 --- a/protocols/Twitter/src/proto.cpp +++ b/protocols/Twitter/src/proto.cpp @@ -86,7 +86,7 @@ DWORD_PTR TwitterProto::GetCaps(int type, MCONTACT) case PFLAGNUM_3: return PF2_ONLINE; case PFLAGNUM_4: - return PF4_NOCUSTOMAUTH | PF4_IMSENDUTF | PF4_AVATARS; + return PF4_NOCUSTOMAUTH | PF4_AVATARS; case PFLAG_MAXLENOFMESSAGE: return 159; // 140 + + 4 ("RT @"). this allows for the new style retweets case PFLAG_UNIQUEIDTEXT: @@ -136,19 +136,11 @@ void TwitterProto::SendSuccess(void *p) delete data; } -int TwitterProto::SendMsg(MCONTACT hContact, int flags, const char *msg) +int TwitterProto::SendMsg(MCONTACT hContact, int, const char *msg) { if (m_iStatus != ID_STATUS_ONLINE) return 0; - TCHAR *tszMsg; - if (flags & PREF_UTF) - tszMsg = mir_utf8decodeT(msg); - else if (flags & PREF_UNICODE) - tszMsg = mir_u2t((wchar_t*)&msg[strlen(msg) + 1]); - else - tszMsg = mir_a2t(msg); - int seq = InterlockedIncrement(&g_msgid); ForkThread(&TwitterProto::SendSuccess, new send_direct(hContact, msg, seq)); return seq; -- cgit v1.2.3