summaryrefslogtreecommitdiff
path: root/protocols/JabberG/src
diff options
context:
space:
mode:
Diffstat (limited to 'protocols/JabberG/src')
-rw-r--r--protocols/JabberG/src/jabber_groupchat.cpp4
-rw-r--r--protocols/JabberG/src/jabber_iqid.cpp10
-rw-r--r--protocols/JabberG/src/jabber_notes.cpp2
-rw-r--r--protocols/JabberG/src/jabber_proto.cpp2
-rw-r--r--protocols/JabberG/src/jabber_search.cpp2
-rw-r--r--protocols/JabberG/src/jabber_svc.cpp2
-rw-r--r--protocols/JabberG/src/jabber_thread.cpp4
-rw-r--r--protocols/JabberG/src/jabber_util.cpp4
8 files changed, 15 insertions, 15 deletions
diff --git a/protocols/JabberG/src/jabber_groupchat.cpp b/protocols/JabberG/src/jabber_groupchat.cpp
index a0655c0d27..9a7efeed41 100644
--- a/protocols/JabberG/src/jabber_groupchat.cpp
+++ b/protocols/JabberG/src/jabber_groupchat.cpp
@@ -867,7 +867,7 @@ void CJabberProto::RenameParticipantNick(JABBER_LIST_ITEM *item, const TCHAR *ol
JABBER_RESOURCE_STATUS *r = item->findResource(oldNick);
if (r == NULL)
return;
-
+
replaceStrT(r->resourceName, newNick);
if ( !lstrcmp(item->nick, oldNick)) {
@@ -1100,7 +1100,7 @@ void CJabberProto::GroupchatProcessPresence(HXML node)
ptrT str( JabberErrorMsg(errorNode, &errorCode));
if (errorCode == JABBER_ERROR_CONFLICT) {
- ptrT newNick( db_get_tsa(NULL, m_szModuleName, "GcAltNick"));
+ ptrT newNick( getTStringA("GcAltNick"));
if (++item->iChatState == 1 && newNick != NULL && newNick[0] != 0) {
replaceStrT(item->nick, newNick);
TCHAR text[1024] = { 0 };
diff --git a/protocols/JabberG/src/jabber_iqid.cpp b/protocols/JabberG/src/jabber_iqid.cpp
index b45bdfe821..d36c82292d 100644
--- a/protocols/JabberG/src/jabber_iqid.cpp
+++ b/protocols/JabberG/src/jabber_iqid.cpp
@@ -331,7 +331,7 @@ void CJabberProto::OnIqResultSession(HXML iqNode, CJabberIqInfo* pInfo)
void CJabberProto::GroupchatJoinByHContact(HANDLE hContact, bool autojoin)
{
- ptrT roomjid( db_get_tsa(hContact, m_szModuleName, "ChatRoomID"));
+ ptrT roomjid( getTStringA(hContact, "ChatRoomID"));
if (roomjid == NULL)
return;
@@ -342,7 +342,7 @@ void CJabberProto::GroupchatJoinByHContact(HANDLE hContact, bool autojoin)
server[0] = 0; server++;
- ptrT nick( db_get_tsa(hContact, m_szModuleName, "MyNick"));
+ ptrT nick( getTStringA(hContact, "MyNick"));
if (nick == NULL) {
nick = JabberNickFromJID(m_szJabberJID);
if (nick == NULL)
@@ -520,7 +520,7 @@ void CJabberProto::OnIqResultGetRoster(HXML iqNode, CJabberIqInfo* pInfo)
if (m_options.RosterSync == TRUE) {
for (HANDLE hContact = db_find_first(m_szModuleName); hContact; ) {
HANDLE hNext = db_find_next(hContact, m_szModuleName);
- ptrT jid( db_get_tsa(hContact, m_szModuleName, "jid"));
+ ptrT jid( getTStringA(hContact, "jid"));
if (jid != NULL && !ListGetItemPtr(LIST_ROSTER, jid)) {
Log("Syncing roster: preparing to delete %S (hContact=0x%x)", jid, hContact);
CallService(MS_DB_CONTACT_DELETE, (WPARAM)hContact, 0);
@@ -1028,10 +1028,10 @@ void CJabberProto::OnIqResultGetVcard(HXML iqNode)
} }
if (hasFn && !hasNick) {
- ptrT nick( db_get_tsa(hContact, m_szModuleName, "Nick"));
+ ptrT nick( getTStringA(hContact, "Nick"));
ptrT jidNick( JabberNickFromJID(jid));
if (!nick || (jidNick && !_tcsicmp(nick, jidNick)))
- setTString(hContact, "Nick", ptrT( db_get_tsa(hContact, m_szModuleName, "FullName")));
+ setTString(hContact, "Nick", ptrT( getTStringA(hContact, "FullName")));
}
if ( !hasFn)
delSetting(hContact, "FullName");
diff --git a/protocols/JabberG/src/jabber_notes.cpp b/protocols/JabberG/src/jabber_notes.cpp
index d442ee8a46..d0b3c9ea3f 100644
--- a/protocols/JabberG/src/jabber_notes.cpp
+++ b/protocols/JabberG/src/jabber_notes.cpp
@@ -854,7 +854,7 @@ INT_PTR __cdecl CJabberProto::OnMenuHandleNotes(WPARAM, LPARAM)
INT_PTR __cdecl CJabberProto::OnMenuSendNote(WPARAM wParam, LPARAM)
{
if (wParam) {
- CNoteItem *pItem = new CNoteItem(NULL, ptrT( db_get_tsa((HANDLE)wParam, m_szModuleName, "jid")));
+ CNoteItem *pItem = new CNoteItem(NULL, ptrT( getTStringA((HANDLE)wParam, "jid")));
CJabberDlgBase *pDlg = new CJabberDlgNoteItem(this, pItem, &CJabberProto::ProcessOutgoingNote);
pDlg->Show();
}
diff --git a/protocols/JabberG/src/jabber_proto.cpp b/protocols/JabberG/src/jabber_proto.cpp
index a17213387b..a8f61f9fb3 100644
--- a/protocols/JabberG/src/jabber_proto.cpp
+++ b/protocols/JabberG/src/jabber_proto.cpp
@@ -817,7 +817,7 @@ HANDLE __cdecl CJabberProto::SearchBasic(const TCHAR *szJid)
numericjid = (*i >= '0') && (*i <= '9');
mir_free(szServer);
- szServer = db_get_tsa(NULL, m_szModuleName, "LoginServer");
+ szServer = getTStringA(NULL, "LoginServer");
if (szServer == NULL)
szServer = mir_tstrdup(_T("jabber.org"));
else if (numericjid && !_tcsicmp(szServer, _T("S.ms"))) {
diff --git a/protocols/JabberG/src/jabber_search.cpp b/protocols/JabberG/src/jabber_search.cpp
index 342e761c2b..49f946cd42 100644
--- a/protocols/JabberG/src/jabber_search.cpp
+++ b/protocols/JabberG/src/jabber_search.cpp
@@ -702,7 +702,7 @@ static INT_PTR CALLBACK JabberSearchAdvancedDlgProc(HWND hwndDlg, UINT msg, WPAR
HWND __cdecl CJabberProto::CreateExtendedSearchUI(HWND parent)
{
if (parent && hInst) {
- ptrT szServer( db_get_tsa(NULL, m_szModuleName, "LoginServer"));
+ ptrT szServer( getTStringA("LoginServer"));
if (szServer == NULL || _tcsicmp(szServer, _T("S.ms")))
return CreateDialogParam(hInst, MAKEINTRESOURCE(IDD_SEARCHUSER), parent, JabberSearchAdvancedDlgProc, (LPARAM)this);
}
diff --git a/protocols/JabberG/src/jabber_svc.cpp b/protocols/JabberG/src/jabber_svc.cpp
index c8a3bedb96..6e24c20f52 100644
--- a/protocols/JabberG/src/jabber_svc.cpp
+++ b/protocols/JabberG/src/jabber_svc.cpp
@@ -779,7 +779,7 @@ HANDLE CJabberSysInterface::ContactFromJID(LPCTSTR jid)
LPTSTR CJabberSysInterface::ContactToJID(HANDLE hContact)
{
- return db_get_tsa(hContact, m_psProto->m_szModuleName, m_psProto->isChatRoom(hContact) ? "ChatRoomID" : "jid");
+ return m_psProto->getTStringA(hContact, m_psProto->isChatRoom(hContact) ? "ChatRoomID" : "jid");
}
LPTSTR CJabberSysInterface::GetBestResourceName(LPCTSTR jid)
diff --git a/protocols/JabberG/src/jabber_thread.cpp b/protocols/JabberG/src/jabber_thread.cpp
index 01d13405db..deb993b7a5 100644
--- a/protocols/JabberG/src/jabber_thread.cpp
+++ b/protocols/JabberG/src/jabber_thread.cpp
@@ -1665,7 +1665,7 @@ void CJabberProto::OnProcessPresence(HXML node, ThreadData* info)
Log("AvatarXVcard deleted");
setTString(hContact, "AvatarHash", ptszHash);
hasAvatar = true;
- ptrT saved( db_get_tsa(hContact, m_szModuleName, "AvatarSaved"));
+ ptrT saved( getTStringA(hContact, "AvatarSaved"));
if (saved != NULL || lstrcmp(saved, ptszHash)) {
Log("Avatar was changed");
ProtoBroadcastAck(hContact, ACKTYPE_AVATAR, ACKRESULT_STATUS, NULL, NULL);
@@ -1685,7 +1685,7 @@ void CJabberProto::OnProcessPresence(HXML node, ThreadData* info)
Log("AvatarXVcard set");
setTString(hContact, "AvatarHash", txt);
hasAvatar = true;
- ptrT saved( db_get_tsa(hContact, m_szModuleName, "AvatarSaved"));
+ ptrT saved( getTStringA(hContact, "AvatarSaved"));
if (saved || lstrcmp(saved, txt)) {
Log("Avatar was changed. Using vcard-temp:x:update");
ProtoBroadcastAck(hContact, ACKTYPE_AVATAR, ACKRESULT_STATUS, NULL, NULL);
diff --git a/protocols/JabberG/src/jabber_util.cpp b/protocols/JabberG/src/jabber_util.cpp
index 7f3a953551..f9d7f926e0 100644
--- a/protocols/JabberG/src/jabber_util.cpp
+++ b/protocols/JabberG/src/jabber_util.cpp
@@ -752,7 +752,7 @@ void CJabberProto::SendPresenceTo(int status, TCHAR* to, HXML extra, const TCHAR
ptrA hashValue( getStringA("AvatarHash"));
if (hashValue != NULL) // XEP-0153: vCard-Based Avatars
x << XCHILD(_T("photo"), _A2T(hashValue));
- else
+ else
x << XCHILD(_T("photo"));
}
@@ -918,7 +918,7 @@ TCHAR* CJabberProto::GetClientJID(HANDLE hContact, TCHAR *dest, size_t destLen)
if (hContact == NULL)
return NULL;
- ptrT jid( db_get_tsa(hContact, m_szModuleName, "jid"));
+ ptrT jid( getTStringA(hContact, "jid"));
return GetClientJID(jid, dest, destLen);
}