From ac9cc8dd9bb65882a77b93a35448be62c3f83fef Mon Sep 17 00:00:00 2001 From: George Hazan Date: Wed, 23 Jan 2013 17:26:06 +0000 Subject: - GDI resource leak fix; - various cosmetics git-svn-id: http://svn.miranda-ng.org/main/trunk@3252 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/SeenPlugin/src/utils.cpp | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'plugins/SeenPlugin/src/utils.cpp') diff --git a/plugins/SeenPlugin/src/utils.cpp b/plugins/SeenPlugin/src/utils.cpp index 8983ac53e0..8758b3acd3 100644 --- a/plugins/SeenPlugin/src/utils.cpp +++ b/plugins/SeenPlugin/src/utils.cpp @@ -26,8 +26,6 @@ Last change by : $Author: y_b $ void FileWrite(HANDLE); void HistoryWrite(HANDLE hcontact); -//void SetOffline(void); -void ShowHistory(HANDLE hContact, BYTE isAlert); char * courProtoName = 0; @@ -132,7 +130,7 @@ DWORD isSeen(HANDLE hcontact, SYSTEMTIME *st) //perform LOCALTOTIMESTAMP res = (DWORD)ll - CallService(MS_DB_TIME_TIMESTAMPTOLOCAL,0,0); //nevel look for Year/Month/Day/Hour/Minute/Second again - DBWriteContactSettingDword(hcontact,S_MOD,"seenTS",res); + db_set_dw(hcontact,S_MOD,"seenTS",res); } } } } @@ -420,7 +418,7 @@ void DBWriteTimeTS(DWORD t, HANDLE hcontact){ ft.dwLowDateTime = (DWORD)ll; ft.dwHighDateTime = (DWORD)(ll >> 32); FileTimeToSystemTime(&ft, &st); - DBWriteContactSettingDword(hcontact,S_MOD,"seenTS",t); + db_set_dw(hcontact,S_MOD,"seenTS",t); _DBWriteTime(&st, hcontact); } void GetColorsFromDWord(LPCOLORREF First, LPCOLORREF Second, DWORD colDword){ @@ -704,7 +702,7 @@ static DWORD __stdcall cleanThread(logthread_info* infoParam) char *str = (char *)malloc(MAXMODULELABELLENGTH+9); mir_snprintf(str,MAXMODULELABELLENGTH+8,"OffTime-%s",infoParam->sProtoName); - DBDeleteContactSetting(NULL,S_MOD,str); + db_unset(NULL,S_MOD,str); free(str); free(infoParam); @@ -748,7 +746,7 @@ int ModeChange(WPARAM wparam,LPARAM lparam) time_t t; time(&t); mir_snprintf(str,MAXMODULELABELLENGTH+8,"OffTime-%s",ack->szModule); - DBWriteContactSettingDword(NULL,S_MOD,str,t); + db_set_dw(NULL,S_MOD,str,t); free(str); } } if (isetting==db_get_w(NULL,S_MOD,courProtoName,ID_STATUS_OFFLINE)) return 0; -- cgit v1.2.3