summaryrefslogtreecommitdiff
path: root/protocols/Sametime/src
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2016-07-25 10:31:04 +0000
committerGeorge Hazan <george.hazan@gmail.com>2016-07-25 10:31:04 +0000
commit8ae3679aa1339ce9abee53adb69902bd6b7513dc (patch)
tree94ef8927e12043ed6dcc15e1e640d68a8add520e /protocols/Sametime/src
parent1e273e28d89b5838e3d0f0cafac9676577cb71ce (diff)
hello, Unix.
phase 1: removing _T() git-svn-id: http://svn.miranda-ng.org/main/trunk@17127 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/Sametime/src')
-rw-r--r--protocols/Sametime/src/conference.cpp54
-rw-r--r--protocols/Sametime/src/files.cpp42
-rw-r--r--protocols/Sametime/src/messaging.cpp30
-rw-r--r--protocols/Sametime/src/options.cpp66
-rw-r--r--protocols/Sametime/src/places.cpp4
-rw-r--r--protocols/Sametime/src/sametime.cpp20
-rw-r--r--protocols/Sametime/src/sametime_proto.cpp46
-rw-r--r--protocols/Sametime/src/sametime_session.cpp60
-rw-r--r--protocols/Sametime/src/session_announce_win.cpp6
-rw-r--r--protocols/Sametime/src/userlist.cpp28
-rw-r--r--protocols/Sametime/src/utils.cpp12
11 files changed, 184 insertions, 184 deletions
diff --git a/protocols/Sametime/src/conference.cpp b/protocols/Sametime/src/conference.cpp
index d4aee066df..46cf1bbf83 100644
--- a/protocols/Sametime/src/conference.cpp
+++ b/protocols/Sametime/src/conference.cpp
@@ -27,12 +27,12 @@ void mwServiceConf_on_invited(mwConference* conf, mwLoginInfo* inviter, const ch
{
GList *members, *mem;
CSametimeProto* proto = getProtoFromMwConference(conf);
- proto->debugLog(_T("mwServiceConf_on_invited() start"));
+ proto->debugLog(L"mwServiceConf_on_invited() start");
members = mem = mwConference_getMembers(conf);
for (;mem;mem=mem->next) {
if (proto->my_login_info && strcmp(proto->my_login_info->login_id, ((mwLoginInfo*)mem->data)->login_id) == 0) {
- proto->debugLog(_T("mwServiceConf_on_invited() already present"));
+ proto->debugLog(L"mwServiceConf_on_invited() already present");
mwConference_reject(conf, 0, T2Utf(TranslateT("Invitation rejected - already present.")));
return;
}
@@ -46,11 +46,11 @@ void mwServiceConf_on_invited(mwConference* conf, mwLoginInfo* inviter, const ch
MultiByteToWideChar(CP_UTF8, 0, (const char*)invite, -1, ws_invite, 128);
if (MessageBoxW(0, ws_invite, ws_username, MB_OKCANCEL) == IDOK) {
- proto->debugLog(_T("mwServiceConf_on_invited() mwConference_accept"));
+ proto->debugLog(L"mwServiceConf_on_invited() mwConference_accept");
mwConference_accept(conf);
}
else {
- proto->debugLog(_T("mwServiceConf_on_invited() mwConference_reject"));
+ proto->debugLog(L"mwServiceConf_on_invited() mwConference_reject");
char* temp = mir_utf8encodeT(TranslateT("Your invitation has been rejected."));
mwConference_reject(conf, 0, temp);
mir_free(temp);
@@ -59,7 +59,7 @@ void mwServiceConf_on_invited(mwConference* conf, mwLoginInfo* inviter, const ch
void CSametimeProto::ClearInviteQueue()
{
- debugLog(_T("CSametimeProto::ClearInviteQueue() start"));
+ debugLog(L"CSametimeProto::ClearInviteQueue() start");
if (!my_conference)
return;
@@ -106,7 +106,7 @@ void CSametimeProto::ClearInviteQueue()
void mwServiceConf_conf_opened(mwConference* conf, GList* members)
{
CSametimeProto* proto = getProtoFromMwConference(conf);
- proto->debugLog(_T("mwServiceConf_conf_opened() start"));
+ proto->debugLog(L"mwServiceConf_conf_opened() start");
TCHAR* tszConfId = mir_utf8decodeT(mwConference_getName(conf));
TCHAR* tszConfTitle = mir_utf8decodeT(mwConference_getTitle(conf));
@@ -139,7 +139,7 @@ void mwServiceConf_conf_opened(mwConference* conf, GList* members)
GList *user = members;
for (;user; user=user->next) {
- proto->debugLog(_T("mwServiceConf_conf_opened() add user"));
+ proto->debugLog(L"mwServiceConf_conf_opened() add user");
TCHAR* tszUserName = mir_utf8decodeT(((mwLoginInfo*)user->data)->user_name);
TCHAR* tszUserId = mir_utf8decodeT(((mwLoginInfo*)user->data)->login_id);
@@ -171,7 +171,7 @@ void mwServiceConf_conf_opened(mwConference* conf, GList* members)
void mwServiceConf_conf_closed(mwConference* conf, guint32 reason)
{
CSametimeProto* proto = getProtoFromMwConference(conf);
- proto->debugLog(_T("mwServiceConf_conf_closed() start"));
+ proto->debugLog(L"mwServiceConf_conf_closed() start");
TCHAR* tszConfId = mir_utf8decodeT(mwConference_getName(conf));
@@ -191,7 +191,7 @@ void mwServiceConf_conf_closed(mwConference* conf, guint32 reason)
void mwServiceConf_on_peer_joined(mwConference* conf, mwLoginInfo *user)
{
CSametimeProto* proto = getProtoFromMwConference(conf);
- proto->debugLog(_T("mwServiceConf_on_peer_joined() start"));
+ proto->debugLog(L"mwServiceConf_on_peer_joined() start");
MCONTACT hContact = proto->FindContactByUserId(user->user_id);
if (!hContact) {
@@ -221,7 +221,7 @@ void mwServiceConf_on_peer_joined(mwConference* conf, mwLoginInfo *user)
gce.dwFlags = GCEF_ADDTOLOG;
gce.ptszNick = tszUserName;
gce.ptszUID = tszUserId;
- gce.ptszStatus = _T("Normal");
+ gce.ptszStatus = L"Normal";
gce.time = (DWORD)time(0);
CallServiceSync(MS_GC_EVENT, 0, (LPARAM) &gce);
@@ -235,7 +235,7 @@ void mwServiceConf_on_peer_joined(mwConference* conf, mwLoginInfo *user)
void mwServiceConf_on_peer_parted(mwConference* conf, mwLoginInfo* user)
{
CSametimeProto* proto = getProtoFromMwConference(conf);
- proto->debugLog(_T("mwServiceConf_on_peer_parted() start"));
+ proto->debugLog(L"mwServiceConf_on_peer_parted() start");
ptrT tszConfId(mir_utf8decodeT(mwConference_getName(conf)));
ptrT tszUserName(mir_utf8decodeT(user->user_name));
@@ -250,7 +250,7 @@ void mwServiceConf_on_peer_parted(mwConference* conf, mwLoginInfo* user)
gce.dwFlags = GCEF_ADDTOLOG;
gce.ptszNick = tszUserName;
gce.ptszUID = tszUserId;
- gce.ptszStatus = _T("Normal");
+ gce.ptszStatus = L"Normal";
gce.time = (DWORD)time(0);
CallServiceSync(MS_GC_EVENT, 0, (LPARAM)&gce);
}
@@ -259,7 +259,7 @@ void mwServiceConf_on_peer_parted(mwConference* conf, mwLoginInfo* user)
void mwServiceConf_on_text(mwConference* conf, mwLoginInfo* user, const char* what)
{
CSametimeProto* proto = getProtoFromMwConference(conf);
- proto->debugLog(_T("mwServiceConf_on_text() start"));
+ proto->debugLog(L"mwServiceConf_on_text() start");
TCHAR* tszConfId = mir_utf8decodeT(mwConference_getName(conf));
@@ -290,7 +290,7 @@ void mwServiceConf_on_text(mwConference* conf, mwLoginInfo* user, const char* wh
void mwServiceConf_on_typing(mwConference* conf, mwLoginInfo* who, gboolean typing)
{
CSametimeProto* proto = getProtoFromMwConference(conf);
- proto->debugLog(_T("mwServiceConf_on_typing() start"));
+ proto->debugLog(L"mwServiceConf_on_typing() start");
///TODO unimplemented
}
@@ -312,7 +312,7 @@ mwConferenceHandler mwConference_handler = {
void CSametimeProto::TerminateConference(char* name)
{
- debugLog(_T("CSametimeProto::TerminateConference() start"));
+ debugLog(L"CSametimeProto::TerminateConference() start");
GList *conferences, *conf;
conferences = conf = mwServiceConference_getConferences(service_conference);
@@ -346,17 +346,17 @@ int CSametimeProto::GcEventHook(WPARAM wParam, LPARAM lParam) {
switch(gch->pDest->iType) {
case GC_USER_MESSAGE:
{
- debugLog(_T("CSametimeProto::GcEventHook() GC_USER_MESSAGE"));
+ debugLog(L"CSametimeProto::GcEventHook() GC_USER_MESSAGE");
mwConference_sendText((mwConference*)conf->data, T2Utf(gch->ptszText));
}
break;
case GC_SESSION_TERMINATE:
{
if (my_conference == conf->data){
- debugLog(_T("CSametimeProto::GcEventHook() GC_SESSION_TERMINATE CloseMyConference"));
+ debugLog(L"CSametimeProto::GcEventHook() GC_SESSION_TERMINATE CloseMyConference");
CloseMyConference(this);
} else {
- debugLog(_T("CSametimeProto::GcEventHook() GC_SESSION_TERMINATE mwConference_destroy"));
+ debugLog(L"CSametimeProto::GcEventHook() GC_SESSION_TERMINATE mwConference_destroy");
mwConference_destroy((mwConference*)conf->data, 0, T2Utf(TranslateT("I'm outa here.")));
}
}
@@ -378,7 +378,7 @@ int CSametimeProto::ChatDeleted(MCONTACT hContact) {
if (db_get_b(hContact, m_szModuleName, "ChatRoom", 0) == 0)
return 0;
- debugLog(_T("CSametimeProto::ChatDeleted() hContact=[%x]"), hContact);
+ debugLog(L"CSametimeProto::ChatDeleted() hContact=[%x]", hContact);
DBVARIANT dbv;
if (!db_get_s(hContact, m_szModuleName, "ChatRoomID", &dbv)) {
TerminateConference(dbv.pszVal);
@@ -392,7 +392,7 @@ int CSametimeProto::ChatDeleted(MCONTACT hContact) {
INT_PTR CSametimeProto::onMenuLeaveChat(WPARAM wParam, LPARAM lParam)
{
MCONTACT hContact = (MCONTACT)wParam;
- debugLog(_T("CSametimeProto::onMenuLeaveChat() hContact=[%x]"), hContact);
+ debugLog(L"CSametimeProto::onMenuLeaveChat() hContact=[%x]", hContact);
ChatDeleted(hContact);
return 0;
}
@@ -401,7 +401,7 @@ INT_PTR CSametimeProto::onMenuLeaveChat(WPARAM wParam, LPARAM lParam)
INT_PTR CSametimeProto::onMenuCreateChat(WPARAM wParam, LPARAM lParam)
{
MCONTACT hContact = (MCONTACT)wParam;
- debugLog(_T("CSametimeProto::onMenuCreateChat() hContact=[%x]"), hContact);
+ debugLog(L"CSametimeProto::onMenuCreateChat() hContact=[%x]", hContact);
mwAwareIdBlock id_block;
mwIdBlock idb;
if (my_login_info && GetAwareIdFromContact(hContact, &id_block)) {
@@ -416,12 +416,12 @@ INT_PTR CSametimeProto::onMenuCreateChat(WPARAM wParam, LPARAM lParam)
invite_queue.push(idb.user);
if (!my_conference) {
- debugLog(_T("CSametimeProto::onMenuCreateChat() mwConference_open"));
+ debugLog(L"CSametimeProto::onMenuCreateChat() mwConference_open");
my_conference = mwConference_new(service_conference, T2Utf(title));
mwConference_open(my_conference);
}
else {
- debugLog(_T("CSametimeProto::onMenuCreateChat() ClearInviteQueue"));
+ debugLog(L"CSametimeProto::onMenuCreateChat() ClearInviteQueue");
ClearInviteQueue();
}
@@ -434,7 +434,7 @@ INT_PTR CSametimeProto::onMenuCreateChat(WPARAM wParam, LPARAM lParam)
int CSametimeProto::PrebuildContactMenu(WPARAM wParam, LPARAM lParam)
{
MCONTACT hContact = (MCONTACT)wParam;
- debugLog(_T("CSametimeProto::PrebuildContactMenu() hContact=[%x]"), hContact);
+ debugLog(L"CSametimeProto::PrebuildContactMenu() hContact=[%x]", hContact);
Menu_ShowItem(hLeaveChatMenuItem, db_get_b(hContact, m_szModuleName, "ChatRoom", 0) == 1);
@@ -463,7 +463,7 @@ int CSametimeProto::PrebuildContactMenu(WPARAM wParam, LPARAM lParam)
void CSametimeProto::InitConference()
{
- debugLog(_T("CSametimeProto::InitConference()"));
+ debugLog(L"CSametimeProto::InitConference()");
my_login_info = mwSession_getLoginInfo(session);
@@ -476,7 +476,7 @@ void CSametimeProto::InitConference()
void CSametimeProto::DeinitConference()
{
GList *conferences, *conf;
- debugLog(_T("CSametimeProto::DeinitConference()"));
+ debugLog(L"CSametimeProto::DeinitConference()");
if (service_conference){
conferences = conf = mwServiceConference_getConferences(service_conference);
@@ -500,7 +500,7 @@ void CSametimeProto::DeinitConference()
void CSametimeProto::InitConferenceMenu()
{
- debugLog(_T("CSametimeProto::InitConferenceMenu()"));
+ debugLog(L"CSametimeProto::InitConferenceMenu()");
CreateProtoService(MS_SAMETIME_MENULEAVECHAT, &CSametimeProto::onMenuLeaveChat);
CreateProtoService(MS_SAMETIME_MENUCREATECHAT, &CSametimeProto::onMenuCreateChat);
diff --git a/protocols/Sametime/src/files.cpp b/protocols/Sametime/src/files.cpp
index 4782563a7e..bbc71b346b 100644
--- a/protocols/Sametime/src/files.cpp
+++ b/protocols/Sametime/src/files.cpp
@@ -13,11 +13,11 @@ CSametimeProto* getProtoFromMwFileTransfer(mwFileTransfer* ft)
void mwFileTransfer_offered(mwFileTransfer* ft)
{
CSametimeProto* proto = getProtoFromMwFileTransfer(ft);
- proto->debugLog(_T("mwFileTransfer_offered() start"));
+ proto->debugLog(L"mwFileTransfer_offered() start");
const mwIdBlock* idb = mwFileTransfer_getUser(ft);
MCONTACT hContact = proto->FindContactByUserId(idb->user);
- proto->debugLog(_T("Sametime mwFileTransfer_offered hContact=[%x]"), hContact);
+ proto->debugLog(L"Sametime mwFileTransfer_offered hContact=[%x]", hContact);
if (!hContact) {
mwSametimeList* user_list = mwSametimeList_new();
@@ -33,7 +33,7 @@ void mwFileTransfer_offered(mwFileTransfer* ft)
TCHAR descriptionT[512];
if (message) {
TCHAR* messageT = mir_utf8decodeT(message);
- mir_sntprintf(descriptionT, _T("%s - %s"), filenameT, messageT);
+ mir_sntprintf(descriptionT, L"%s - %s", filenameT, messageT);
mir_free(messageT);
} else
_tcsncpy_s(descriptionT, filenameT, _TRUNCATE);
@@ -59,7 +59,7 @@ int SendFileChunk(CSametimeProto* proto, mwFileTransfer* ft, FileTransferClientD
return 0;
if (!ReadFile(ftcd->hFile, ftcd->buffer, FILE_BUFF_SIZE, &bytes_read, 0)) {
- proto->debugLog(_T("Sametime closing file transfer (SendFileChunk)"));
+ proto->debugLog(L"Sametime closing file transfer (SendFileChunk)");
mwFileTransfer_close(ft, mwFileTransfer_SUCCESS);
return 0;
}
@@ -79,7 +79,7 @@ void __cdecl SendThread(LPVOID param) {
CSametimeProto* proto = getProtoFromMwFileTransfer(ft);
FileTransferClientData* ftcd = (FileTransferClientData*)mwFileTransfer_getClientData(ft);
- proto->debugLog(_T("SendThread() start"));
+ proto->debugLog(L"SendThread() start");
PROTOFILETRANSFERSTATUS pfts = {0};
@@ -114,7 +114,7 @@ void __cdecl SendThread(LPVOID param) {
if (ftcd->buffer) delete[] ftcd->buffer;
delete ftcd;
- proto->debugLog(_T("SendThread() end"));
+ proto->debugLog(L"SendThread() end");
return;
}
@@ -124,7 +124,7 @@ void mwFileTransfer_opened(mwFileTransfer* ft)
CSametimeProto* proto = getProtoFromMwFileTransfer(ft);
FileTransferClientData* ftcd = (FileTransferClientData*)mwFileTransfer_getClientData(ft);
- proto->debugLog(_T("Sametime mwFileTransfer_opened start"));
+ proto->debugLog(L"Sametime mwFileTransfer_opened start");
if (ftcd->sending) {
// create a thread to send chunks - since it seems not all clients send acks for each of our chunks!
@@ -139,7 +139,7 @@ void mwFileTransfer_closed(mwFileTransfer* ft, guint32 code)
{
CSametimeProto* proto = getProtoFromMwFileTransfer(ft);
FileTransferClientData* ftcd = (FileTransferClientData*)mwFileTransfer_getClientData(ft);
- proto->debugLog(_T("mwFileTransfer_closed() start"));
+ proto->debugLog(L"mwFileTransfer_closed() start");
if (ftcd) {
if (ftcd->hFile != INVALID_HANDLE_VALUE)
@@ -217,14 +217,14 @@ void mwFileTransfer_recv(mwFileTransfer* ft, struct mwOpaque* data)
{
CSametimeProto* proto = getProtoFromMwFileTransfer(ft);
FileTransferClientData* ftcd = (FileTransferClientData*)mwFileTransfer_getClientData(ft);
- proto->debugLog(_T("mwFileTransfer_recv() start"));
+ proto->debugLog(L"mwFileTransfer_recv() start");
DWORD bytes_written;
if (!WriteFile(ftcd->hFile, data->data, data->len, &bytes_written, 0)) {
- proto->debugLog(_T("mwFileTransfer_recv() !WriteFile"));
+ proto->debugLog(L"mwFileTransfer_recv() !WriteFile");
mwFileTransfer_cancel(ft);
proto->ProtoBroadcastAck(ftcd->hContact, ACKTYPE_FILE, ACKRESULT_FAILED, ftcd->hFt, 0);
- proto->debugLog(_T("mwFileTransfer_recv() ACKRESULT_FAILED"));
+ proto->debugLog(L"mwFileTransfer_recv() ACKRESULT_FAILED");
}
else {
mwFileTransfer_ack(ft); // acknowledge chunk
@@ -248,11 +248,11 @@ void mwFileTransfer_recv(mwFileTransfer* ft, struct mwOpaque* data)
pfts.currentFileTime = 0; //?
proto->ProtoBroadcastAck(ftcd->hContact, ACKTYPE_FILE, ACKRESULT_DATA, ftcd->hFt, (LPARAM)&pfts);
- proto->debugLog(_T("mwFileTransfer_recv() ACKRESULT_DATA"));
+ proto->debugLog(L"mwFileTransfer_recv() ACKRESULT_DATA");
if (mwFileTransfer_isDone(ft)) {
proto->ProtoBroadcastAck(ftcd->hContact, ACKTYPE_FILE, ACKRESULT_SUCCESS, ftcd->hFt, 0);
- proto->debugLog(_T("mwFileTransfer_recv() ACKRESULT_SUCCESS"));
+ proto->debugLog(L"mwFileTransfer_recv() ACKRESULT_SUCCESS");
}
}
}
@@ -265,7 +265,7 @@ void mwFileTransfer_handle_ack(mwFileTransfer* ft)
// see SendThread above - not all clients send us acks
CSametimeProto* proto = getProtoFromMwFileTransfer(ft);
//FileTransferClientData* ftcd = (FileTransferClientData*)mwFileTransfer_getClientData(ft);
- proto->debugLog(_T("mwFileTransfer_handle_ack()"));
+ proto->debugLog(L"mwFileTransfer_handle_ack()");
}
/** optional. called from mwService_free */
@@ -284,7 +284,7 @@ mwFileTransferHandler mwFileTransfer_handler = {
HANDLE CSametimeProto::SendFilesToUser(MCONTACT hContact, TCHAR** files, const TCHAR* ptszDesc)
{
- debugLog(_T("CSametimeProto::SendFilesToUser() start"));
+ debugLog(L"CSametimeProto::SendFilesToUser() start");
mwAwareIdBlock id_block;
if (GetAwareIdFromContact(hContact, &id_block)) {
@@ -359,7 +359,7 @@ HANDLE CSametimeProto::AcceptFileTransfer(MCONTACT hContact, HANDLE hFt, char* s
mwFileTransfer* ft = (mwFileTransfer*)hFt;
CSametimeProto* proto = getProtoFromMwFileTransfer(ft);
- debugLog(_T("CSametimeProto::AcceptFileTransfer() start"));
+ debugLog(L"CSametimeProto::AcceptFileTransfer() start");
FileTransferClientData* ftcd = new FileTransferClientData;
memset(ftcd, 0, sizeof(FileTransferClientData));
@@ -388,7 +388,7 @@ HANDLE CSametimeProto::AcceptFileTransfer(MCONTACT hContact, HANDLE hFt, char* s
ftcd->hFile = CreateFileA(fp, GENERIC_WRITE, FILE_SHARE_READ, 0, OPEN_ALWAYS, 0, 0);
if (ftcd->hFile == INVALID_HANDLE_VALUE) {
- debugLog(_T("CSametimeProto::AcceptFileTransfer() INVALID_HANDLE_VALUE"));
+ debugLog(L"CSametimeProto::AcceptFileTransfer() INVALID_HANDLE_VALUE");
mwFileTransfer_close(ft, mwFileTransfer_ERROR);
return 0;
}
@@ -405,7 +405,7 @@ void CSametimeProto::RejectFileTransfer(HANDLE hFt)
{
mwFileTransfer* ft = (mwFileTransfer*)hFt;
CSametimeProto* proto = getProtoFromMwFileTransfer(ft);
- debugLog(_T("CSametimeProto::RejectFileTransfer() start"));
+ debugLog(L"CSametimeProto::RejectFileTransfer() start");
mwFileTransfer_reject(ft);
}
@@ -414,7 +414,7 @@ void CSametimeProto::CancelFileTransfer(HANDLE hFt)
{
mwFileTransfer* ft = (mwFileTransfer*)hFt;
CSametimeProto* proto = getProtoFromMwFileTransfer(ft);
- debugLog(_T("CSametimeProto::CancelFileTransfer() start"));
+ debugLog(L"CSametimeProto::CancelFileTransfer() start");
FileTransferClientData* ftcd = (FileTransferClientData*)mwFileTransfer_getClientData(ft);
@@ -429,13 +429,13 @@ void CSametimeProto::CancelFileTransfer(HANDLE hFt)
void CSametimeProto::InitFiles()
{
- debugLog(_T("CSametimeProto::InitFiles()"));
+ debugLog(L"CSametimeProto::InitFiles()");
mwSession_addService(session, (mwService*)(service_files = mwServiceFileTransfer_new(session, &mwFileTransfer_handler)));
}
void CSametimeProto::DeinitFiles()
{
- debugLog(_T("CSametimeProto::DeinitFiles()"));
+ debugLog(L"CSametimeProto::DeinitFiles()");
mwSession_removeService(session, mwService_FILE_TRANSFER);
mwService_free((mwService*)service_files);
service_files = 0;
diff --git a/protocols/Sametime/src/messaging.cpp b/protocols/Sametime/src/messaging.cpp
index 0a7f8a24f2..2bde61b90e 100644
--- a/protocols/Sametime/src/messaging.cpp
+++ b/protocols/Sametime/src/messaging.cpp
@@ -12,13 +12,13 @@ CSametimeProto* getProtoFromMwConversation(mwConversation* conv)
void mwIm_conversation_opened(mwConversation* conv)
{
CSametimeProto* proto = getProtoFromMwConversation(conv);
- proto->debugLog(_T("mwIm_conversation_opened() start"));
+ proto->debugLog(L"mwIm_conversation_opened() start");
mwIdBlock* idb = mwConversation_getTarget(conv);
MCONTACT hContact = proto->FindContactByUserId(idb->user);
if (!hContact) {
- proto->debugLog(_T("mwIm_conversation_opened() !hContact"));
+ proto->debugLog(L"mwIm_conversation_opened() !hContact");
mwSametimeList* user_list = mwSametimeList_new();
mwSametimeGroup* stgroup = mwSametimeGroup_new(user_list, mwSametimeGroup_NORMAL, Translate("None"));
mwSametimeUser* stuser = mwSametimeUser_new(stgroup, mwSametimeUser_NORMAL, idb);
@@ -45,7 +45,7 @@ void mwIm_conversation_opened(mwConversation* conv)
void mwIm_conversation_closed(mwConversation* conv, guint32 err)
{
CSametimeProto* proto = getProtoFromMwConversation(conv);
- proto->debugLog(_T("mwIm_conversation_closed() start err=[%d]"), err);
+ proto->debugLog(L"mwIm_conversation_closed() start err=[%d]", err);
if (err & ERR_FAILURE && err != CONNECTION_RESET) {
proto->showPopup(err);
@@ -67,11 +67,11 @@ void mwIm_conversation_closed(mwConversation* conv, guint32 err)
void mwIm_conversation_recv(mwConversation* conv, mwImSendType type, gconstpointer msg)
{
CSametimeProto* proto = getProtoFromMwConversation(conv);
- proto->debugLog(_T("mwIm_conversation_recv() start"));
+ proto->debugLog(L"mwIm_conversation_recv() start");
mwIdBlock* idb = mwConversation_getTarget(conv);
MCONTACT hContact = proto->FindContactByUserId(idb->user);
- proto->debugLog(_T("mwIm_conversation_recv() type=[%d] hContact=[%x]"), type, hContact);
+ proto->debugLog(L"mwIm_conversation_recv() type=[%d] hContact=[%x]", type, hContact);
if (type == mwImSend_TYPING) {
CallService(MS_PROTO_CONTACTISTYPING, hContact, (GPOINTER_TO_UINT(msg) == 0 ? 0 : 2));
@@ -91,7 +91,7 @@ void mwIm_conversation_recv(mwConversation* conv, mwImSendType type, gconstpoint
void mwIm_place_invite(struct mwConversation* conv, const char* message, const char* title, const char* name)
{
CSametimeProto* proto = getProtoFromMwConversation(conv);
- proto->debugLog(_T("mwIm_place_invite() start"));
+ proto->debugLog(L"mwIm_place_invite() start");
///TODO unimplemented
@@ -114,7 +114,7 @@ mwImHandler mwIm_handler = {
HANDLE CSametimeProto::SendMessageToUser(MCONTACT hContact, const char *szMsg)
{
- debugLog(_T("CSametimeProto::SendMessageToUser() hContact=[%x]"), hContact);
+ debugLog(L"CSametimeProto::SendMessageToUser() hContact=[%x]", hContact);
mwAwareIdBlock id_block;
if (GetAwareIdFromContact(hContact, &id_block)) {
@@ -125,13 +125,13 @@ HANDLE CSametimeProto::SendMessageToUser(MCONTACT hContact, const char *szMsg)
mwConversation* conv = mwServiceIm_getConversation(service_im, &idb);
if (conv) {
if (!mwConversation_isOpen(conv)) {
- debugLog(_T("CSametimeProto::SendMessageToUser() mwConversation_isOpen"));
+ debugLog(L"CSametimeProto::SendMessageToUser() mwConversation_isOpen");
mir_cslock lck(q_cs);
contact_message_queue[hContact].push(szMsg);
mwConversation_open(conv);
}
else {
- debugLog(_T("CSametimeProto::SendMessageToUser() !mwConversation_isOpen"));
+ debugLog(L"CSametimeProto::SendMessageToUser() !mwConversation_isOpen");
mwConversation_send(conv, mwImSend_PLAIN, szMsg);
}
@@ -147,7 +147,7 @@ HANDLE CSametimeProto::SendMessageToUser(MCONTACT hContact, const char *szMsg)
void CSametimeProto::SendTyping(MCONTACT hContact, bool typing)
{
- debugLog(_T("CSametimeProto::SendTyping() hContact=[%x] type=[%d]"), hContact, typing);
+ debugLog(L"CSametimeProto::SendTyping() hContact=[%x] type=[%d]", hContact, typing);
mwAwareIdBlock id_block;
if (GetAwareIdFromContact(hContact, &id_block)) {
@@ -158,7 +158,7 @@ void CSametimeProto::SendTyping(MCONTACT hContact, bool typing)
mwConversation* conv = mwServiceIm_getConversation(service_im, &idb);
if (conv) {
if (mwConversation_isOpen(conv)) {
- debugLog(_T("CSametimeProto::SendTyping() send"));
+ debugLog(L"CSametimeProto::SendTyping() send");
mwConversation_send(conv, mwImSend_TYPING, (gconstpointer)GUINT_TO_POINTER(typing ? 1 : 0));
}
}
@@ -169,7 +169,7 @@ void CSametimeProto::SendTyping(MCONTACT hContact, bool typing)
void CSametimeProto::CloseIm(MCONTACT hContact)
{
- debugLog(_T("CSametimeProto::CloseIm() hContact=[%x]"), hContact);
+ debugLog(L"CSametimeProto::CloseIm() hContact=[%x]", hContact);
mwAwareIdBlock id_block;
if (GetAwareIdFromContact(hContact, &id_block)) {
@@ -180,7 +180,7 @@ void CSametimeProto::CloseIm(MCONTACT hContact)
mwConversation* conv = mwServiceIm_getConversation(service_im, &idb);
if (conv) {
if (mwConversation_isOpen(conv)) {
- debugLog(_T("CSametimeProto::CloseIm() mwConversation_close"));
+ debugLog(L"CSametimeProto::CloseIm() mwConversation_close");
mwConversation_close(conv, 0);
}
}
@@ -190,14 +190,14 @@ void CSametimeProto::CloseIm(MCONTACT hContact)
void CSametimeProto::InitMessaging()
{
- debugLog(_T("CSametimeProto::InitMessaging()"));
+ debugLog(L"CSametimeProto::InitMessaging()");
mwSession_addService(session, (mwService*)(service_im = mwServiceIm_new(session, &mwIm_handler)));
mwServiceIm_setClientType(service_im, mwImClient_PLAIN);
}
void CSametimeProto::DeinitMessaging()
{
- debugLog(_T("CSametimeProto::DeinitMessaging()"));
+ debugLog(L"CSametimeProto::DeinitMessaging()");
mwSession_removeService(session, mwService_IM);
mwService_free((mwService*)service_im);
service_im = 0;
diff --git a/protocols/Sametime/src/options.cpp b/protocols/Sametime/src/options.cpp
index 6d47ca05fd..9f31d92ba6 100644
--- a/protocols/Sametime/src/options.cpp
+++ b/protocols/Sametime/src/options.cpp
@@ -7,30 +7,30 @@
#define NUM_IDS 24
TCHAR* client_names[NUM_IDS] = {
- _T("Official Binary Library"),
- _T("Official Java Applet"),
- _T("Official Binary Application"),
- _T("Official Java Application"),
- _T("Notes 6.5"),
- _T("Notes 7.0"),
- _T("Notes 8.0 Basic"),
- _T("Notes 8.5.2"),
- _T("Sametime Connect 8.0"),
- _T("Sametime Connect 8.5.2"),
- _T("ICT"),
- _T("NotesBuddy"),
- _T("NotesBuddy 4.15"),
- _T("Sanity"),
- _T("Perl"),
- _T("PMR Alert"),
- _T("Trillian (SourceForge)"),
- _T("Trillian (IBM)"),
- _T("Meanwhile Library"),
- _T("Meanwhile (Python)"),
- _T("Meanwhile (Gaim)"),
- _T("Meanwhile (Adium)"),
- _T("Meanwhile (Kopete)"),
- _T("Custom")
+ L"Official Binary Library",
+ L"Official Java Applet",
+ L"Official Binary Application",
+ L"Official Java Application",
+ L"Notes 6.5",
+ L"Notes 7.0",
+ L"Notes 8.0 Basic",
+ L"Notes 8.5.2",
+ L"Sametime Connect 8.0",
+ L"Sametime Connect 8.5.2",
+ L"ICT",
+ L"NotesBuddy",
+ L"NotesBuddy 4.15",
+ L"Sanity",
+ L"Perl",
+ L"PMR Alert",
+ L"Trillian (SourceForge)",
+ L"Trillian (IBM)",
+ L"Meanwhile Library",
+ L"Meanwhile (Python)",
+ L"Meanwhile (Gaim)",
+ L"Meanwhile (Adium)",
+ L"Meanwhile (Kopete)",
+ L"Custom"
};
int client_ids[NUM_IDS] = {
0x1000,
@@ -66,11 +66,11 @@ int client_ids[NUM_IDS] = {
#define NUM_CVS 5
TCHAR* CV_names[NUM_CVS] = {
- _T("Sametime (Use old client version)"),
- _T("Sametime (Miranda default)"),
- _T("Sametime 8"),
- _T("Sametime 8.5.1"),
- _T("Sametime 8.5.2")
+ L"Sametime (Use old client version)",
+ L"Sametime (Miranda default)",
+ L"Sametime 8",
+ L"Sametime 8.5.1",
+ L"Sametime 8.5.2"
};
int CV_major[NUM_CVS] = {
MW_PROTOCOL_VERSION_MAJOR,
@@ -238,7 +238,7 @@ static INT_PTR CALLBACK DlgProcOptNet(HWND hwndDlg, UINT msg, WPARAM wParam, LPA
ofn.hwndOwner = hwndDlg;
ofn.Flags = CC_FULLOPEN;
ofn.nMaxFile = MAX_PATH;
- ofn.lpstrFilter = _T("All\0*.*\0");
+ ofn.lpstrFilter = L"All\0*.*\0";
ofn.nFilterIndex = 1;
ofn.lpstrFileTitle = NULL;
ofn.nMaxFileTitle = 0;
@@ -410,9 +410,9 @@ void CSametimeProto::LoadOptions()
if (options.err_method == ED_POP && !ServiceExists(MS_POPUP_SHOWMESSAGE)) options.err_method = ED_BAL;
if (options.err_method == ED_BAL && !ServiceExists(MS_CLIST_SYSTRAY_NOTIFY)) options.err_method = ED_MB;
- debugLog(_T("LoadOptions() loaded: ServerName:len=[%d], id:len=[%d], pword:len=[%d]"), options.server_name == NULL ? -1 : mir_strlen(options.server_name), options.id == NULL ? -1 : mir_strlen(options.id), options.pword == NULL ? -1 : mir_strlen(options.pword));
- debugLog(_T("LoadOptions() loaded: port=[%d], encrypt_session=[%d], ClientID=[%d], ClientVersionMajor=[%d], ClientVersionMinor=[%d]"), options.port, options.encrypt_session, options.client_id, options.client_versionMajor, options.client_versionMinor);
- debugLog(_T("LoadOptions() loaded: get_server_contacts=[%d], add_contacts=[%d], idle_as_away=[%d], err_method=[%d]"), options.get_server_contacts, options.add_contacts, options.idle_as_away, options.err_method);
+ debugLog(L"LoadOptions() loaded: ServerName:len=[%d], id:len=[%d], pword:len=[%d]", options.server_name == NULL ? -1 : mir_strlen(options.server_name), options.id == NULL ? -1 : mir_strlen(options.id), options.pword == NULL ? -1 : mir_strlen(options.pword));
+ debugLog(L"LoadOptions() loaded: port=[%d], encrypt_session=[%d], ClientID=[%d], ClientVersionMajor=[%d], ClientVersionMinor=[%d]", options.port, options.encrypt_session, options.client_id, options.client_versionMajor, options.client_versionMinor);
+ debugLog(L"LoadOptions() loaded: get_server_contacts=[%d], add_contacts=[%d], idle_as_away=[%d], err_method=[%d]", options.get_server_contacts, options.add_contacts, options.idle_as_away, options.err_method);
}
diff --git a/protocols/Sametime/src/places.cpp b/protocols/Sametime/src/places.cpp
index c7c0a19adf..9bffaa9ac3 100644
--- a/protocols/Sametime/src/places.cpp
+++ b/protocols/Sametime/src/places.cpp
@@ -54,13 +54,13 @@ mwPlaceHandler mwPlace_handler = {
void CSametimeProto::InitPlaces(mwSession* session)
{
- debugLog(_T("CSametimeProto::InitPlaces()"));
+ debugLog(L"CSametimeProto::InitPlaces()");
mwSession_addService(session, (mwService*)(service_places = mwServicePlace_new(session, &mwPlace_handler)));
}
void CSametimeProto::DeinitPlaces(mwSession* session)
{
- debugLog(_T("CSametimeProto::DeinitPlaces()"));
+ debugLog(L"CSametimeProto::DeinitPlaces()");
mwSession_removeService(session, mwService_PLACE);
mwService_free((mwService*)service_places);
service_places = 0;
diff --git a/protocols/Sametime/src/sametime.cpp b/protocols/Sametime/src/sametime.cpp
index 3f04f7ee22..6a9e9a3169 100644
--- a/protocols/Sametime/src/sametime.cpp
+++ b/protocols/Sametime/src/sametime.cpp
@@ -124,12 +124,12 @@ void __cdecl sttFakeAckInfoSuccessThread(void *param)
{
TFakeAckParams* tParam = (TFakeAckParams*)param;
CSametimeProto* proto = tParam->proto;
- proto->debugLog(_T("sttFakeAckInfoSuccessThread() start"));
+ proto->debugLog(L"sttFakeAckInfoSuccessThread() start");
Sleep(100);
proto->ProtoBroadcastAck(tParam->hContact, ACKTYPE_GETINFO, ACKRESULT_SUCCESS, (HANDLE)1, 0);
- proto->debugLog(_T("sttFakeAckInfoSuccessThread() end"));
+ proto->debugLog(L"sttFakeAckInfoSuccessThread() end");
mir_free(tParam);
}
@@ -137,12 +137,12 @@ void __cdecl sttFakeAckMessageSuccessThread(void *param)
{
TFakeAckParams* tParam = (TFakeAckParams*)param;
CSametimeProto* proto = tParam->proto;
- proto->debugLog(_T("sttFakeAckMessageSuccessThread() start"));
+ proto->debugLog(L"sttFakeAckMessageSuccessThread() start");
Sleep(100);
proto->ProtoBroadcastAck(tParam->hContact, ACKTYPE_MESSAGE, ACKRESULT_SUCCESS, (HANDLE)tParam->lParam, 0);
- proto->debugLog(_T("sttFakeAckMessageSuccessThread() end"));
+ proto->debugLog(L"sttFakeAckMessageSuccessThread() end");
mir_free(tParam);
}
@@ -150,12 +150,12 @@ void __cdecl sttFakeAckMessageFailedThread(void *param)
{
TFakeAckParams* tParam = (TFakeAckParams*)param;
CSametimeProto* proto = tParam->proto;
- proto->debugLog(_T("sttFakeAckMessageFailedThread() start"));
+ proto->debugLog(L"sttFakeAckMessageFailedThread() start");
Sleep(100);
proto->ProtoBroadcastAck(tParam->hContact, ACKTYPE_MESSAGE, ACKRESULT_FAILED, NULL, tParam->lParam); ///TODO tParam->lParam: add error message
- proto->debugLog(_T("sttFakeAckMessageFailedThread() end"));
+ proto->debugLog(L"sttFakeAckMessageFailedThread() end");
mir_free(tParam);
}
@@ -163,12 +163,12 @@ void __cdecl sttRecvAwayThread(void *param)
{
TFakeAckParams* tParam = (TFakeAckParams*)param;
CSametimeProto* proto = tParam->proto;
- proto->debugLog(_T("sttRecvAwayThread() start"));
+ proto->debugLog(L"sttRecvAwayThread() start");
Sleep(100);
proto->UserRecvAwayMessage(tParam->hContact);
- proto->debugLog(_T("sttRecvAwayThread() end"));
+ proto->debugLog(L"sttRecvAwayThread() end");
free(tParam);
}
@@ -223,7 +223,7 @@ int CSametimeProto::OnSametimeContactDeleted(WPARAM hContact, LPARAM)
void CSametimeProto::SetAllOffline()
{
- debugLog(_T("SetAllOffline() start"));
+ debugLog(L"SetAllOffline() start");
for (MCONTACT hContact = db_find_first(m_szModuleName); hContact; hContact = db_find_next(hContact, m_szModuleName)) {
if (db_get_b(hContact, m_szModuleName, "ChatRoom", 0)) {
@@ -241,7 +241,7 @@ void CSametimeProto::BroadcastNewStatus(int iNewStatus)
if (m_iStatus == iNewStatus)
return;
- debugLog(_T("BroadcastNewStatus() m_iStatus=[%d], iNewStatus=[%d]"), m_iStatus, iNewStatus);
+ debugLog(L"BroadcastNewStatus() m_iStatus=[%d], iNewStatus=[%d]", m_iStatus, iNewStatus);
previous_status = m_iStatus;
m_iStatus = iNewStatus;
diff --git a/protocols/Sametime/src/sametime_proto.cpp b/protocols/Sametime/src/sametime_proto.cpp
index aa7f4a7409..4278a309c8 100644
--- a/protocols/Sametime/src/sametime_proto.cpp
+++ b/protocols/Sametime/src/sametime_proto.cpp
@@ -24,7 +24,7 @@ CSametimeProto::CSametimeProto(const char* pszProtoName, const TCHAR* tszUserNam
m_hNetlibUser = (HANDLE)CallService(MS_NETLIB_REGISTERUSER, 0, (LPARAM)&nlu);
RegisterGLibLogger();
- debugLog(_T("CSametimeProto::CSametimeProto() start m_szModuleName=[%s], m_tszUserName=[%s]"), _A2T(m_szModuleName), m_tszUserName);
+ debugLog(L"CSametimeProto::CSametimeProto() start m_szModuleName=[%s], m_tszUserName=[%s]", _A2T(m_szModuleName), m_tszUserName);
SametimeInitIcons();
@@ -58,17 +58,17 @@ CSametimeProto::CSametimeProto(const char* pszProtoName, const TCHAR* tszUserNam
LoadOptions();
- debugLog(_T("CSametimeProto::CSametimeProto() end"));
+ debugLog(L"CSametimeProto::CSametimeProto() end");
}
CSametimeProto::~CSametimeProto()
{
- debugLog(_T("CSametimeProto::~CSametimeProto() start"));
+ debugLog(L"CSametimeProto::~CSametimeProto() start");
DeinitAwayMsg();
UnregisterPopups();
- debugLog(_T("CSametimeProto::~CSametimeProto() end"));
+ debugLog(L"CSametimeProto::~CSametimeProto() end");
UnRegisterGLibLogger();
Netlib_CloseHandle(m_hNetlibUser);
@@ -79,13 +79,13 @@ CSametimeProto::~CSametimeProto()
MCONTACT CSametimeProto::AddToList(int flags, PROTOSEARCHRESULT* psr)
{
MYPROTOSEARCHRESULT* sr = (MYPROTOSEARCHRESULT*)psr;
- debugLog(_T("CSametimeProto::AddToList() flags=[%d]"), flags);
+ debugLog(L"CSametimeProto::AddToList() flags=[%d]", flags);
return AddSearchedUser(sr, flags & PALF_TEMPORARY);
}
HANDLE CSametimeProto::FileAllow(MCONTACT hContact, HANDLE hTransfer, const TCHAR* szPath)
{
- debugLog(_T("CSametimeProto::FileAllow() hContact=[%x], szPath=[%s]"), hContact, szPath);
+ debugLog(L"CSametimeProto::FileAllow() hContact=[%x], szPath=[%s]", hContact, szPath);
char* szPathA = mir_t2a(szPath);
HANDLE res = AcceptFileTransfer(hContact, hTransfer, szPathA);
mir_free(szPathA);
@@ -94,21 +94,21 @@ HANDLE CSametimeProto::FileAllow(MCONTACT hContact, HANDLE hTransfer, const TCHA
int CSametimeProto::FileCancel(MCONTACT hContact, HANDLE hTransfer)
{
- debugLog(_T("CSametimeProto::FileCancel() hContact=[%x]"), hContact);
+ debugLog(L"CSametimeProto::FileCancel() hContact=[%x]", hContact);
CancelFileTransfer(hTransfer);
return 0;
}
int CSametimeProto::FileDeny(MCONTACT hContact, HANDLE hTransfer, const TCHAR* szReason)
{
- debugLog(_T("CSametimeProto::FileDeny() hContact=[%x], szReason=[%s]"), hContact, szReason);
+ debugLog(L"CSametimeProto::FileDeny() hContact=[%x], szReason=[%s]", hContact, szReason);
RejectFileTransfer(hTransfer);
return 0;
}
int CSametimeProto::FileResume(HANDLE hTransfer, int* action, const TCHAR** szFilename)
{
- debugLog(_T("CSametimeProto::FileResume() action=[%d]"), &action);
+ debugLog(L"CSametimeProto::FileResume() action=[%d]", &action);
return 0;
}
@@ -138,7 +138,7 @@ DWORD_PTR CSametimeProto::GetCaps(int type, MCONTACT hContact)
int CSametimeProto::GetInfo(MCONTACT hContact, int infoType)
{
// GetInfo - retrieves a contact info
- debugLog(_T("CSametimeProto::GetInfo() hContact=[%x], infoType=[%d]"), hContact, infoType);
+ debugLog(L"CSametimeProto::GetInfo() hContact=[%x], infoType=[%d]", hContact, infoType);
if (getByte(hContact, "ChatRoom", 0))
return 1;
@@ -159,7 +159,7 @@ int CSametimeProto::GetInfo(MCONTACT hContact, int infoType)
HANDLE CSametimeProto::SearchBasic(const TCHAR* id)
{
- debugLog(_T("CSametimeProto::SearchBasic() id:len=[%d]"), id == NULL ? -1 : mir_tstrlen(id));
+ debugLog(L"CSametimeProto::SearchBasic() id:len=[%d]", id == NULL ? -1 : mir_tstrlen(id));
return (HANDLE)SearchForUser(T2Utf(id), FALSE);
///TODO - add timeout (like at GGPROTO::searchthread)
}
@@ -168,7 +168,7 @@ HWND CSametimeProto::SearchAdvanced(HWND owner)
{
TCHAR buf[512];
if (GetDlgItemText(owner, IDC_EDIT1, buf, _countof(buf))) {
- debugLog(_T("CSametimeProto::SearchAdvanced() buf:len=[%d]"), mir_tstrlen(buf));
+ debugLog(L"CSametimeProto::SearchAdvanced() buf:len=[%d]", mir_tstrlen(buf));
return (HWND)SearchForUser(T2Utf(buf), TRUE);
}
return NULL;
@@ -176,14 +176,14 @@ HWND CSametimeProto::SearchAdvanced(HWND owner)
HWND CSametimeProto::CreateExtendedSearchUI(HWND owner)
{
- debugLog(_T("CSametimeProto::CreateExtendedSearchUI() start"));
+ debugLog(L"CSametimeProto::CreateExtendedSearchUI() start");
return CreateDialogParam(hInst, MAKEINTRESOURCE(IDD_USERSEARCH), owner, SearchDialogFunc, (LPARAM)this);
}
int CSametimeProto::RecvFile(MCONTACT hContact, PROTORECVFILET* pre)
{
- debugLog(_T("CSametimeProto::RecvFile() hContact=[%x]"), hContact);
+ debugLog(L"CSametimeProto::RecvFile() hContact=[%x]", hContact);
db_unset(hContact, "CList", "Hidden");
db_unset(hContact, "CList", "NotOnList");
@@ -193,7 +193,7 @@ int CSametimeProto::RecvFile(MCONTACT hContact, PROTORECVFILET* pre)
int CSametimeProto::RecvMsg(MCONTACT hContact, PROTORECVEVENT* pre)
{
- debugLog(_T("CSametimeProto::RecvMsg() hContact=[%x]"), hContact);
+ debugLog(L"CSametimeProto::RecvMsg() hContact=[%x]", hContact);
db_unset(hContact, "CList", "Hidden");
db_unset(hContact, "CList", "NotOnList");
@@ -203,7 +203,7 @@ int CSametimeProto::RecvMsg(MCONTACT hContact, PROTORECVEVENT* pre)
HANDLE CSametimeProto::SendFile(MCONTACT hContact, const TCHAR* szDescription, TCHAR** ppszFiles)
{
- debugLog(_T("CSametimeProto::SendFile() hContact=[%x]"), hContact);
+ debugLog(L"CSametimeProto::SendFile() hContact=[%x]", hContact);
if (m_iStatus != ID_STATUS_OFFLINE) {
if (hContact && ppszFiles && szDescription) {
if (db_get_w(hContact, m_szModuleName, "Status", ID_STATUS_OFFLINE) != ID_STATUS_OFFLINE) {
@@ -216,7 +216,7 @@ HANDLE CSametimeProto::SendFile(MCONTACT hContact, const TCHAR* szDescription, T
int CSametimeProto::SendMsg(MCONTACT hContact, int, const char* msg)
{
- debugLog(_T("CSametimeProto::SendMsg() hContact=[%x]"), hContact);
+ debugLog(L"CSametimeProto::SendMsg() hContact=[%x]", hContact);
char *proto = GetContactProto(hContact);
if (!proto || mir_strcmp(proto, m_szModuleName) != 0 || db_get_w(hContact, m_szModuleName, "Status", ID_STATUS_OFFLINE) == ID_STATUS_OFFLINE) {
@@ -244,7 +244,7 @@ int CSametimeProto::SendMsg(MCONTACT hContact, int, const char* msg)
int CSametimeProto::SetStatus(int iNewStatus)
{
- debugLog(_T("CSametimeProto::SetStatus() m_iStatus=[%d], m_iDesiredStatus=[%d], iNewStatus=[%d]"), m_iStatus, m_iDesiredStatus, iNewStatus);
+ debugLog(L"CSametimeProto::SetStatus() m_iStatus=[%d], m_iDesiredStatus=[%d], iNewStatus=[%d]", m_iStatus, m_iDesiredStatus, iNewStatus);
m_iDesiredStatus = iNewStatus;
if (iNewStatus != ID_STATUS_OFFLINE) {
if (m_iStatus == ID_STATUS_OFFLINE)
@@ -261,7 +261,7 @@ int CSametimeProto::SetStatus(int iNewStatus)
HANDLE CSametimeProto::GetAwayMsg(MCONTACT hContact)
{
- debugLog(_T("CSametimeProto::GetInfo() hContact=[%x], m_iStatus=[%d]"), hContact, m_iStatus);
+ debugLog(L"CSametimeProto::GetInfo() hContact=[%x], m_iStatus=[%d]", hContact, m_iStatus);
if (hContact && m_iStatus != ID_STATUS_OFFLINE) {
TFakeAckParams* tfap;
tfap = (TFakeAckParams*)malloc(sizeof(TFakeAckParams));
@@ -275,7 +275,7 @@ HANDLE CSametimeProto::GetAwayMsg(MCONTACT hContact)
int CSametimeProto::RecvAwayMsg(MCONTACT hContact, int mode, PROTORECVEVENT* evt)
{
- debugLog(_T("CSametimeProto::RecvAwayMsg() hContact=[%x], mode=[%d]"), hContact, mode);
+ debugLog(L"CSametimeProto::RecvAwayMsg() hContact=[%x], mode=[%d]", hContact, mode);
ptrT pszMsg(mir_utf8decodeT(evt->szMessage));
ProtoBroadcastAck(hContact, ACKTYPE_AWAYMSG, ACKRESULT_SUCCESS, (HANDLE)evt->lParam, pszMsg);
@@ -284,14 +284,14 @@ int CSametimeProto::RecvAwayMsg(MCONTACT hContact, int mode, PROTORECVEVENT* evt
int CSametimeProto::SetAwayMsg(int iStatus, const TCHAR* msg)
{
- debugLog(_T("CSametimeProto::SetAwayMsg() iStatus=[%d], msg:len=[%d]"), iStatus, msg == NULL ? -1 : mir_tstrlen(msg));
+ debugLog(L"CSametimeProto::SetAwayMsg() iStatus=[%d], msg:len=[%d]", iStatus, msg == NULL ? -1 : mir_tstrlen(msg));
SetSessionAwayMessage(iStatus, msg);
return 0;
}
int CSametimeProto::UserIsTyping(MCONTACT hContact, int type)
{
- debugLog(_T("CSametimeProto::UserIsTyping() hContact=[%x], type=[%d]"), hContact, type);
+ debugLog(L"CSametimeProto::UserIsTyping() hContact=[%x], type=[%d]", hContact, type);
SendTyping(hContact, type == PROTOTYPE_SELFTYPING_ON);
return 0;
}
@@ -300,7 +300,7 @@ int CSametimeProto::OnEvent(PROTOEVENTTYPE iEventType, WPARAM wParam, LPARAM lPa
{
switch (iEventType) {
case EV_PROTO_ONOPTIONS:
- debugLog(_T("CSametimeProto::OnEvent() EV_PROTO_ONOPTIONS"));
+ debugLog(L"CSametimeProto::OnEvent() EV_PROTO_ONOPTIONS");
OptInit(wParam, lParam);
break;
}
diff --git a/protocols/Sametime/src/sametime_session.cpp b/protocols/Sametime/src/sametime_session.cpp
index 1d54872cd9..496b1ea95e 100644
--- a/protocols/Sametime/src/sametime_session.cpp
+++ b/protocols/Sametime/src/sametime_session.cpp
@@ -17,13 +17,13 @@ struct {
void __cdecl SessionClear(mwSession* session)
{
CSametimeProto* proto = (CSametimeProto*)mwSession_getProperty(session, "PROTO_STRUCT_PTR");
- proto->debugLog(_T("SessionClear()"));
+ proto->debugLog(L"SessionClear()");
}
int __cdecl SessionWrite(mwSession* session, const unsigned char* buf, gsize len)
{
CSametimeProto* proto = (CSametimeProto*)mwSession_getProperty(session, "PROTO_STRUCT_PTR");
- proto->debugLog(_T("SessionWrite() server_connection=[%d], len=[%d]"), proto->server_connection, len);
+ proto->debugLog(L"SessionWrite() server_connection=[%d], len=[%d]", proto->server_connection, len);
if (!proto->server_connection) return 1;
if (Netlib_Send(proto->server_connection, (const char*)buf, len, 0) == SOCKET_ERROR)
return 1;
@@ -33,7 +33,7 @@ int __cdecl SessionWrite(mwSession* session, const unsigned char* buf, gsize len
void __cdecl SessionClose(mwSession* session)
{
CSametimeProto* proto = (CSametimeProto*)mwSession_getProperty(session, "PROTO_STRUCT_PTR");
- proto->debugLog(_T("SessionClose() server_connection=[%d]"), proto->server_connection);
+ proto->debugLog(L"SessionClose() server_connection=[%d]", proto->server_connection);
Netlib_CloseHandle(proto->server_connection);
proto->server_connection = 0;
}
@@ -52,7 +52,7 @@ void CSametimeProto::SessionStopping()
void CSametimeProto::InitMeanwhileServices()
{
- debugLog(_T("InitMeanwhileServices() start"));
+ debugLog(L"InitMeanwhileServices() start");
if (options.encrypt_session) {
mwSession_addCipher(session, mwCipher_new_RC2_128(session));
@@ -77,7 +77,7 @@ void CSametimeProto::InitMeanwhileServices()
void CSametimeProto::DeinitMeanwhileServices()
{
- debugLog(_T("DeinitMeanwhileServices() start"));
+ debugLog(L"DeinitMeanwhileServices() start");
DeinitConference();
DeinitFiles();
DeinitMessaging();
@@ -89,7 +89,7 @@ void CSametimeProto::DeinitMeanwhileServices()
void __cdecl SessionStateChange(mwSession* session, mwSessionState state, gpointer info)
{
CSametimeProto* proto = (CSametimeProto*)mwSession_getProperty(session, "PROTO_STRUCT_PTR");
- proto->debugLog(_T("SessionStateChange() state=[%d]"), state);
+ proto->debugLog(L"SessionStateChange() state=[%d]", state);
switch (state) {
case mwSession_STARTING:
@@ -136,7 +136,7 @@ void __cdecl SessionStateChange(mwSession* session, mwSessionState state, gpoint
void __cdecl SessionAdmin(struct mwSession* session, const char* text)
{
CSametimeProto* proto = (CSametimeProto*)mwSession_getProperty(session, "PROTO_STRUCT_PTR");
- proto->debugLog(_T("SessionAdmin()"));
+ proto->debugLog(L"SessionAdmin()");
TCHAR* tt = mir_utf8decodeT(text);
MessageBox(0, tt, TranslateT("Sametime administrator message"), MB_OK);
mir_free(tt);
@@ -145,7 +145,7 @@ void __cdecl SessionAdmin(struct mwSession* session, const char* text)
void __cdecl SessionAnnounce(struct mwSession* session, struct mwLoginInfo* from, gboolean may_reply, const char* text)
{
CSametimeProto* proto = (CSametimeProto*)mwSession_getProperty(session, "PROTO_STRUCT_PTR");
- proto->debugLog(_T("SessionAnnounce()"));
+ proto->debugLog(L"SessionAnnounce()");
TCHAR* stzFrom;
TCHAR* stzText;
TCHAR stzFromBuff[256];
@@ -160,7 +160,7 @@ void __cdecl SessionAnnounce(struct mwSession* session, struct mwLoginInfo* from
void __cdecl SessionSetPrivacyInfo(struct mwSession* session)
{
CSametimeProto* proto = (CSametimeProto*)mwSession_getProperty(session, "PROTO_STRUCT_PTR");
- proto->debugLog(_T("SessionSetPrivacyInfo()"));
+ proto->debugLog(L"SessionSetPrivacyInfo()");
}
void __cdecl SessionSetUserStatus(struct mwSession* session)
@@ -171,7 +171,7 @@ void __cdecl SessionSetUserStatus(struct mwSession* session)
struct mwUserStatus us;
mwUserStatus_clone(&us, mwSession_getUserStatus(session));
- proto->debugLog(_T("SessionSetUserStatus() us.status=[%d]"), us.status);
+ proto->debugLog(L"SessionSetUserStatus() us.status=[%d]", us.status);
switch (us.status) {
case mwStatus_ACTIVE:
@@ -224,7 +224,7 @@ void __cdecl SessionSetUserStatus(struct mwSession* session)
if (proto->first_online) {
proto->first_online = false;
//proto->showPopup(TranslateT("Setting login status"), SAMETIME_POPUP_INFO);
- proto->debugLog(_T("Setting login status"));
+ proto->debugLog(L"Setting login status");
proto->SetSessionStatus(proto->login_status);
}
else proto->BroadcastNewStatus(new_status);
@@ -241,7 +241,7 @@ void CSametimeProto::UpdateSelfStatus()
int CSametimeProto::SetSessionStatus(int status)
{
struct mwUserStatus us;
- debugLog(_T("SetSessionStatus() start status=[%d]"), status);
+ debugLog(L"SetSessionStatus() start status=[%d]", status);
if (idle_timerid) KillTimer(0, idle_timerid);
@@ -271,7 +271,7 @@ int CSametimeProto::SetSessionStatus(int status)
us.desc = AwayMessages.szOnline; us.status = mwStatus_ACTIVE; break;
}
- debugLog(_T("SetSessionStatus() mwSession_setUserStatus us.status=[%d], us.desc:len=[%d]"), us.status, us.desc == NULL ? -1 : mir_strlen(us.desc));
+ debugLog(L"SetSessionStatus() mwSession_setUserStatus us.status=[%d], us.desc:len=[%d]", us.status, us.desc == NULL ? -1 : mir_strlen(us.desc));
mwSession_setUserStatus(session, &us);
return 0;
@@ -297,7 +297,7 @@ VOID CALLBACK IdleTimerProc(HWND hwnd, UINT uMsg, UINT_PTR idEvent, DWORD dwTime
int CSametimeProto::SetIdle(bool idle)
{
// set a timer, to wait for any autoaway module which might set our status
- debugLog(_T("CSametimeProto::SetIdle() idle=[%d], idle_status=[%d], idle_timerid=[%d]"), idle, idle_status, idle_timerid);
+ debugLog(L"CSametimeProto::SetIdle() idle=[%d], idle_status=[%d], idle_timerid=[%d]", idle, idle_status, idle_timerid);
if (idle && !idle_status) {
idle_status = true;
if (!idle_timerid)
@@ -313,7 +313,7 @@ int CSametimeProto::SetIdle(bool idle)
void CSametimeProto::SetSessionAwayMessage(int status, const TCHAR* msgT)
{
- debugLog(_T("SetSessionAwayMessage() status=[%d], msgT:len=[%d]"), status, msgT == NULL ? -1 : mir_tstrlen(msgT));
+ debugLog(L"SetSessionAwayMessage() status=[%d], msgT:len=[%d]", status, msgT == NULL ? -1 : mir_tstrlen(msgT));
T2Utf msg(msgT);
if (status == ID_STATUS_ONLINE)
@@ -345,7 +345,7 @@ void __cdecl KeepAliveThread(LPVOID param)
{
CSametimeProto* proto = (CSametimeProto*)param;
int i = 120;
- proto->debugLog(_T("KeepAliveThread() start"));
+ proto->debugLog(L"KeepAliveThread() start");
while (1) {
@@ -363,7 +363,7 @@ void __cdecl KeepAliveThread(LPVOID param)
mir_cslock lck(proto->session_cs);
if (Miranda_Terminated() || !proto->session) {
- proto->debugLog(_T("KeepAliveThread() end"));
+ proto->debugLog(L"KeepAliveThread() end");
break;
}
}
@@ -380,7 +380,7 @@ void __cdecl SessionThread(LPVOID param)
{
CSametimeProto* proto = (CSametimeProto*)param;
HANDLE hNetlibUser = proto->m_hNetlibUser;
- proto->debugLog(_T("SessionThread() start"));
+ proto->debugLog(L"SessionThread() start");
continue_connect = true;
@@ -406,7 +406,7 @@ void __cdecl SessionThread(LPVOID param)
proto->showPopup(TranslateT("No server connection!"), SAMETIME_POPUP_ERROR);
}
- proto->debugLog(_T("SessionThread() end, no server_connection, continue_connect=[%d]"), continue_connect);
+ proto->debugLog(L"SessionThread() end, no server_connection, continue_connect=[%d]", continue_connect);
return;
}
@@ -436,7 +436,7 @@ void __cdecl SessionThread(LPVOID param)
//while(session && server_connection && mwSession_getState(session) != mwSession_STOPPED) {
while (proto->server_connection) {// && session) {// && !mwSession_isStopped(session)) { // break on error
bytes = Netlib_Recv(proto->server_connection, (char *)recv_buffer, 1024 * 32, 0);
- proto->debugLog(_T("SessionThread() Netlib_Recv'ed bytes=[%d]"), bytes);
+ proto->debugLog(L"SessionThread() Netlib_Recv'ed bytes=[%d]", bytes);
if (bytes == 0) {
break;
@@ -462,7 +462,7 @@ void __cdecl SessionThread(LPVOID param)
proto->SetAllOffline();
proto->first_online = true;
- proto->debugLog(_T("SessionThread() end"));
+ proto->debugLog(L"SessionThread() end");
return;
}
@@ -488,11 +488,11 @@ WORD CSametimeProto::GetServerVersion()
int CSametimeProto::LogIn(int ls, HANDLE hNetlibUser)
{
- debugLog(_T("LogIn() start"));
+ debugLog(L"LogIn() start");
mir_cslock lck(session_cs);
if (session) {
- debugLog(_T("LogIn() end, currently in session"));
+ debugLog(L"LogIn() end, currently in session");
return 0;
}
@@ -505,12 +505,12 @@ int CSametimeProto::LogIn(int ls, HANDLE hNetlibUser)
int CSametimeProto::LogOut()
{
- debugLog(_T("LogOut() start"));
+ debugLog(L"LogOut() start");
continue_connect = false;
mir_cslock lck(session_cs);
if (session && server_connection && m_iStatus != ID_STATUS_OFFLINE && !mwSession_isStopped(session) && !mwSession_isStopping(session)) {
- debugLog(_T("LogOut() mwSession_stop"));
+ debugLog(L"LogOut() mwSession_stop");
mwSession_stop(session, 0);
}
@@ -519,15 +519,15 @@ int CSametimeProto::LogOut()
int CSametimeProto::OnLogInRedirect(char* newHost)
{
- debugLog(_T("OnLogInRedirect() mwSession_LOGIN_REDIR newHost=[%s]"), newHost ? _A2T(newHost) : "(null)");
+ debugLog(L"OnLogInRedirect() mwSession_LOGIN_REDIR newHost=[%s]", newHost ? _A2T(newHost) : "(null)");
if (!newHost || !mir_strcmp(newHost, options.server_name) || db_get_b(0, m_szModuleName, "ForceLogin", 0) == 1) {
- debugLog(_T("OnLogInRedirect() forceLogin"));
+ debugLog(L"OnLogInRedirect() forceLogin");
mwSession_forceLogin(session);
return 0;
}
- debugLog(_T("OnLogInRedirect() redirect"));
+ debugLog(L"OnLogInRedirect() redirect");
mir_strcpy(options.server_name, newHost);
LogOut();
Sleep(50); //wait for SessionThread end
@@ -561,7 +561,7 @@ void SendAnnouncement(SendAnnouncementFunc_arg* arg)
INT_PTR CSametimeProto::SessionAnnounce(WPARAM wParam, LPARAM lParam)
{
- debugLog(_T("CSametimeProto::SessionAnnounce() start"));
+ debugLog(L"CSametimeProto::SessionAnnounce() start");
SessionAnnounceDialogProc_arg* sadpArg = (SessionAnnounceDialogProc_arg*)mir_calloc(sizeof(SessionAnnounceDialogProc_arg));
sadpArg->proto = this;
sadpArg->sendAnnouncementFunc = SendAnnouncement;
@@ -571,7 +571,7 @@ INT_PTR CSametimeProto::SessionAnnounce(WPARAM wParam, LPARAM lParam)
void CSametimeProto::InitSessionMenu()
{
- debugLog(_T("CSametimeProto::InitSessionMenu()"));
+ debugLog(L"CSametimeProto::InitSessionMenu()");
CreateProtoService(MS_SAMETIME_MENUANNOUNCESESSION, &CSametimeProto::SessionAnnounce);
diff --git a/protocols/Sametime/src/session_announce_win.cpp b/protocols/Sametime/src/session_announce_win.cpp
index fe30966af1..03081b51c5 100644
--- a/protocols/Sametime/src/session_announce_win.cpp
+++ b/protocols/Sametime/src/session_announce_win.cpp
@@ -14,7 +14,7 @@ INT_PTR CALLBACK SessionAnnounceDialogProc(HWND hwndDlg, UINT uMsg, WPARAM wPara
SetWindowLongPtr(hwndDlg, GWLP_USERDATA, lParam);
arg = (SessionAnnounceDialogProc_arg*)lParam;
proto = arg->proto;
- proto->debugLog(_T("SessionAnnounceDialogProc WM_INITDIALOG"));
+ proto->debugLog(L"SessionAnnounceDialogProc WM_INITDIALOG");
SendDlgItemMessage(hwndDlg, IDC_LST_ANTO, LVM_SETEXTENDEDLISTVIEWSTYLE, 0, LVS_EX_FULLROWSELECT | LVS_EX_CHECKBOXES);
{
@@ -55,7 +55,7 @@ INT_PTR CALLBACK SessionAnnounceDialogProc(HWND hwndDlg, UINT uMsg, WPARAM wPara
case WM_CLOSE:
proto = arg->proto;
- proto->debugLog(_T("SessionAnnounceDialogProc WM_CLOSE"));
+ proto->debugLog(L"SessionAnnounceDialogProc WM_CLOSE");
mir_free(arg);
DestroyWindow(hwndDlg);
break;
@@ -79,7 +79,7 @@ INT_PTR CALLBACK SessionAnnounceDialogProc(HWND hwndDlg, UINT uMsg, WPARAM wPara
return 0;
case IDOK:
- proto->debugLog(_T("SessionAnnounceDialogProc IDOK BN_CLICKED"));
+ proto->debugLog(L"SessionAnnounceDialogProc IDOK BN_CLICKED");
{
// build SendAnnouncementFunc_arg
SendAnnouncementFunc_arg* safArg = (SendAnnouncementFunc_arg*)mir_calloc(sizeof(SendAnnouncementFunc_arg));
diff --git a/protocols/Sametime/src/userlist.cpp b/protocols/Sametime/src/userlist.cpp
index ce68a3f3d7..3766dc73f7 100644
--- a/protocols/Sametime/src/userlist.cpp
+++ b/protocols/Sametime/src/userlist.cpp
@@ -54,7 +54,7 @@ void CSametimeProto::AddGroup(const char* name, bool expanded)
MCONTACT CSametimeProto::AddContact(mwSametimeUser* user, bool temporary)
{
- debugLog(_T("CSametimeProto::AddContact() start"));
+ debugLog(L"CSametimeProto::AddContact() start");
const char* id = mwSametimeUser_getUser(user);
const char* name = mwSametimeUser_getShortName(user);
const char* nick = mwSametimeUser_getAlias(user);
@@ -66,12 +66,12 @@ MCONTACT CSametimeProto::AddContact(mwSametimeUser* user, bool temporary)
if (!hContact) {
hContact = (MCONTACT)CallService(MS_DB_CONTACT_ADD, 0, 0);
if (!hContact) {
- debugLog(_T("AddContact(): Failed to create Sametime contact"));
+ debugLog(L"AddContact(): Failed to create Sametime contact");
return NULL; ///TODO error handling
}
if (Proto_AddToContact(hContact, m_szModuleName) != 0) {
CallService(MS_DB_CONTACT_DELETE, (WPARAM)hContact, 0);
- debugLog(_T("AddContact(): Failed to register Sametime contact"));
+ debugLog(L"AddContact(): Failed to register Sametime contact");
return NULL; ///TODO error handling
}
new_contact = true;
@@ -125,7 +125,7 @@ MCONTACT CSametimeProto::AddContact(mwSametimeUser* user, bool temporary)
void CSametimeProto::ImportContactsFromList(mwSametimeList* user_list, bool temporary)
{
- debugLog(_T("CSametimeProto::ImportContactsFromList() start"));
+ debugLog(L"CSametimeProto::ImportContactsFromList() start");
// add contacts
mwSametimeGroup* stgroup;
mwSametimeUser* stuser;
@@ -187,7 +187,7 @@ void CSametimeProto::ImportContactsFromList(mwSametimeList* user_list, bool temp
void CSametimeProto::ExportContactsToList(mwSametimeList* user_list)
{
- debugLog(_T("CSametimeProto::ExportContactsToList() start"));
+ debugLog(L"CSametimeProto::ExportContactsToList() start");
mwSametimeGroup* stgroup = 0;
char* group_name;
char* group_alias;
@@ -300,7 +300,7 @@ void CSametimeProto::ExportContactsToList(mwSametimeList* user_list)
void CSametimeProto::ImportContactsFromFile(TCHAR* filename)
{
- debugLog(_T("CSametimeProto::ImportContactsFromFile() start"));
+ debugLog(L"CSametimeProto::ImportContactsFromFile() start");
std::ifstream in(filename);
std::string text;
std::string line;
@@ -326,9 +326,9 @@ void CSametimeProto::ExportContactsToServer()
mwPutBuffer* buff;
mwOpaque* op;
- debugLog(_T("CSametimeProto::ExportContactsToServer() start"));
+ debugLog(L"CSametimeProto::ExportContactsToServer() start");
if (MW_SERVICE_IS_DEAD(service_storage)) {
- debugLog(_T("CSametimeProto::ExportContactsToServer() Failed"));
+ debugLog(L"CSametimeProto::ExportContactsToServer() Failed");
showPopup(TranslateT("Failed to upload contacts - storage service unavailable."), SAMETIME_POPUP_ERROR);
return;
}
@@ -386,7 +386,7 @@ int CSametimeProto::ContactDeleted(MCONTACT hContact)
if (db_get_b(hContact, m_szModuleName, "ChatRoom", 0))
return 0;
- debugLog(_T("CSametimeProto::ContactDeleted()"));
+ debugLog(L"CSametimeProto::ContactDeleted()");
if (GetAwareIdFromContact(hContact, &id_block)) {
GList* gl = g_list_prepend(NULL, &id_block);
@@ -580,7 +580,7 @@ mwAwareListHandler mwAwareList_handler =
void CSametimeProto::UserListCreate()
{
- debugLog(_T("CSametimeProto::UserListCreate() start"));
+ debugLog(L"CSametimeProto::UserListCreate() start");
mwServiceAware_unsetAttribute(service_aware, mwAttribute_SPEAKERS);
mwServiceAware_unsetAttribute(service_aware, mwAttribute_MICROPHONE);
mwServiceAware_unsetAttribute(service_aware, mwAttribute_VIDEO_CAMERA);
@@ -634,7 +634,7 @@ void CSametimeProto::UserListDestroy()
void CSametimeProto::UserRecvAwayMessage(MCONTACT hContact)
{
- debugLog(_T("CSametimeProto::UserRecvAwayMessage() start hContact=[%x]"), hContact);
+ debugLog(L"CSametimeProto::UserRecvAwayMessage() start hContact=[%x]", hContact);
DBVARIANT dbv;
if (!db_get_s((MCONTACT)hContact, "CList", "StatusMsg", &dbv, DBVT_TCHAR)) {
ProtoBroadcastAck((MCONTACT)hContact, ACKTYPE_AWAYMSG, ACKRESULT_SUCCESS, (HANDLE)1, (LPARAM)dbv.ptszVal);
@@ -765,7 +765,7 @@ INT_PTR CALLBACK CALLBACK SearchDialogFunc(HWND hwndDlg, UINT msg, WPARAM wParam
MCONTACT CSametimeProto::AddSearchedUser(MYPROTOSEARCHRESULT* mpsr, bool temporary)
{
MCONTACT hContact = 0;
- debugLog(_T("CSametimeProto::AddSearchedUser() start"));
+ debugLog(L"CSametimeProto::AddSearchedUser() start");
mwSametimeList* user_list = mwSametimeList_new();
mwSametimeGroup* stgroup = 0;
if (mpsr->group) {
@@ -799,7 +799,7 @@ void mwServiceAware_clear_callback(mwServiceAware* srvc)
void CSametimeProto::InitUserList()
{
- debugLog(_T("CSametimeProto::InitUserList()"));
+ debugLog(L"CSametimeProto::InitUserList()");
mwSession_addService(session, (mwService*)(service_storage = mwServiceStorage_new(session)));
mwSession_addService(session, (mwService*)(service_resolve = mwServiceResolve_new(session)));
@@ -813,7 +813,7 @@ void CSametimeProto::InitUserList()
void CSametimeProto::DeinitUserList()
{
- debugLog(_T("CSametimeProto::DeinitUserList()"));
+ debugLog(L"CSametimeProto::DeinitUserList()");
mwSession_removeService(session, mwService_AWARE);
mwService_free((mwService*)service_aware);
diff --git a/protocols/Sametime/src/utils.cpp b/protocols/Sametime/src/utils.cpp
index 346ccd5027..0a73ddce90 100644
--- a/protocols/Sametime/src/utils.cpp
+++ b/protocols/Sametime/src/utils.cpp
@@ -32,7 +32,7 @@ void CSametimeProto::RegisterPopups()
TCHAR szDescr[256];
char szName[256];
- debugLog(_T("CSametimeProto::RegisterPopups()"));
+ debugLog(L"CSametimeProto::RegisterPopups()");
POPUPCLASS puc = { sizeof(puc) };
puc.PluginWindowProc = PopupWindowProc;
@@ -41,7 +41,7 @@ void CSametimeProto::RegisterPopups()
puc.pszName = szName;
mir_snprintf(szName, "%s_%s", m_szModuleName, "Notify");
- mir_sntprintf(szDescr, _T("%s/%s"), m_tszUserName, TranslateT("Notification"));
+ mir_sntprintf(szDescr, L"%s/%s", m_tszUserName, TranslateT("Notification"));
puc.hIcon = CopyIcon(LoadIconEx("notify", FALSE));
ReleaseIconEx("notify", FALSE);
puc.iSeconds = 8;
@@ -50,7 +50,7 @@ void CSametimeProto::RegisterPopups()
hPopupNotify = Popup_RegisterClass(&puc);
mir_snprintf(szName, "%s_%s", m_szModuleName, "Error");
- mir_sntprintf(szDescr, _T("%s/%s"), m_tszUserName, TranslateT("Error"));
+ mir_sntprintf(szDescr, L"%s/%s", m_tszUserName, TranslateT("Error"));
puc.hIcon = CopyIcon(LoadIconEx("error", FALSE));
ReleaseIconEx("error", FALSE);
puc.iSeconds = 10;
@@ -62,7 +62,7 @@ void CSametimeProto::RegisterPopups()
void CSametimeProto::UnregisterPopups()
{
- debugLog(_T("CSametimeProto::RegisterPopups()"));
+ debugLog(L"CSametimeProto::RegisterPopups()");
Popup_UnregisterClass(hPopupError);
Popup_UnregisterClass(hPopupNotify);
}
@@ -163,12 +163,12 @@ void LogFromGLib(const gchar* log_domain, GLogLevelFlags log_level, const gchar*
void CSametimeProto::RegisterGLibLogger()
{
- debugLog(_T("CSametimeProto::RegisterGLibLogger"));
+ debugLog(L"CSametimeProto::RegisterGLibLogger");
gLogHandler = g_log_set_handler(G_LOG_DOMAIN, G_LOG_LEVEL_MASK, LogFromGLib, this);
}
void CSametimeProto::UnRegisterGLibLogger()
{
- debugLog(_T("CSametimeProto::UnRegisterGLibLogger"));
+ debugLog(L"CSametimeProto::UnRegisterGLibLogger");
if (gLogHandler) g_log_remove_handler(G_LOG_DOMAIN, gLogHandler);
}