summaryrefslogtreecommitdiff
path: root/protocols/FacebookRM
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2016-09-19 14:17:59 +0000
committerGeorge Hazan <george.hazan@gmail.com>2016-09-19 14:17:59 +0000
commit9f974ab8617b6b7c19bac9e71d06de89d7e7bd03 (patch)
treeadfbe951d1c291fe0904a083d332889aa043f3ac /protocols/FacebookRM
parent0f37fbfbfe24563a6be07f9abd245374e66cb173 (diff)
- struct GCSESSION died;
- Chat_NewSession simply gets 5 parameters; - minor chat code cleaning git-svn-id: http://svn.miranda-ng.org/main/trunk@17318 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/FacebookRM')
-rw-r--r--protocols/FacebookRM/src/chat.cpp18
1 files changed, 4 insertions, 14 deletions
diff --git a/protocols/FacebookRM/src/chat.cpp b/protocols/FacebookRM/src/chat.cpp
index 5f46bfd42a..2d288ac103 100644
--- a/protocols/FacebookRM/src/chat.cpp
+++ b/protocols/FacebookRM/src/chat.cpp
@@ -245,12 +245,7 @@ void FacebookProto::AddChat(const char *id, const wchar_t *tname)
ptrW tid(mir_a2u(id));
// Create the group chat session
- GCSESSION gcw = {};
- gcw.iType = GCW_PRIVMESS;
- gcw.ptszID = tid;
- gcw.pszModule = m_szModuleName;
- gcw.ptszName = tname;
- Chat_NewSession(&gcw);
+ Chat_NewSession(GCW_PRIVMESS, m_szModuleName, tid, tname);
// Send setting events
Chat_AddGroup(m_szModuleName, tid, TranslateT("Myself"));
@@ -411,16 +406,11 @@ void FacebookProto::PrepareNotificationsChatRoom() {
mir_snwprintf(nameT, L"%s: %s", m_tszUserName, TranslateT("Notifications"));
// Create the group chat session
- GCSESSION gcw = {};
- gcw.iType = GCW_PRIVMESS;
- gcw.ptszID = _A2W(FACEBOOK_NOTIFICATIONS_CHATROOM);
- gcw.pszModule = m_szModuleName;
- gcw.ptszName = nameT;
- Chat_NewSession(&gcw);
+ Chat_NewSession(GCW_PRIVMESS, m_szModuleName, _A2W(FACEBOOK_NOTIFICATIONS_CHATROOM), nameT);
// Send setting events
- Chat_Control(m_szModuleName, gcw.ptszID, WINDOW_HIDDEN);
- Chat_Control(m_szModuleName, gcw.ptszID, SESSION_ONLINE);
+ Chat_Control(m_szModuleName, _A2W(FACEBOOK_NOTIFICATIONS_CHATROOM), WINDOW_HIDDEN);
+ Chat_Control(m_szModuleName, _A2W(FACEBOOK_NOTIFICATIONS_CHATROOM), SESSION_ONLINE);
}
}