diff options
author | George Hazan <george.hazan@gmail.com> | 2012-06-30 13:33:28 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2012-06-30 13:33:28 +0000 |
commit | b8a02a2b98e7b0e6a8a54cb140a873039d9c6d3d (patch) | |
tree | 8dd46393de0047d87492a37e4ab057f143153aa8 /plugins | |
parent | b0632a264c7ce0120af88e915a455c3167f1d5c5 (diff) |
- setting thread names;
- warning fixes;
- code cleaning;
- option to disable sounds during idle
git-svn-id: http://svn.miranda-ng.org/main/trunk@692 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/BasicHistory/HistoryWindow.cpp | 4 | ||||
-rw-r--r-- | plugins/SeenPlugin/utils.cpp | 26 | ||||
-rw-r--r-- | plugins/Svc_dbepp/moduletree.cpp | 3 | ||||
-rw-r--r-- | plugins/Updater/options.cpp | 9 |
4 files changed, 11 insertions, 31 deletions
diff --git a/plugins/BasicHistory/HistoryWindow.cpp b/plugins/BasicHistory/HistoryWindow.cpp index 55cef0da86..d5c3948cb7 100644 --- a/plugins/BasicHistory/HistoryWindow.cpp +++ b/plugins/BasicHistory/HistoryWindow.cpp @@ -39,8 +39,8 @@ extern char* metaContactProto; void ResetCList(HWND hWnd);
-HistoryWindow::HistoryWindow(HANDLE _hContact)
- : isDestroyed(true),
+HistoryWindow::HistoryWindow(HANDLE _hContact) :
+ isDestroyed(true),
OldSplitterProc(0),
splitterY(0),
splitterOrgY(0),
diff --git a/plugins/SeenPlugin/utils.cpp b/plugins/SeenPlugin/utils.cpp index e33d6edfa0..533882977e 100644 --- a/plugins/SeenPlugin/utils.cpp +++ b/plugins/SeenPlugin/utils.cpp @@ -596,36 +596,22 @@ int addContactToQueue(HANDLE hContact){ static DWORD __stdcall waitThread(logthread_info* infoParam)
{
-// char str[MAXMODULELABELLENGTH];
-// sprintf(str,"In Thread: %s; %s; %s\n",
-// infoParam->sProtoName,
-// (char *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME,(WPARAM)infoParam->hContact,0),
-// (const char *)CallService(MS_CLIST_GETSTATUSMODEDESCRIPTION,(WPARAM)infoParam->courStatus,0)
-// );
-// OutputDebugStringA(str);
WORD prevStatus = DBGetContactSettingWord(infoParam->hContact,S_MOD,"StatusTriger",ID_STATUS_OFFLINE);
Sleep(1500); // I hope in 1.5 second all the needed info will be set
- if (includeIdle){
- if (DBGetContactSettingDword(infoParam->hContact,infoParam->sProtoName,"IdleTS",0)) {
+ if (includeIdle)
+ if (DBGetContactSettingDword(infoParam->hContact,infoParam->sProtoName,"IdleTS",0))
infoParam->courStatus &=0x7FFF;
- }
- }
+
if (infoParam->courStatus != prevStatus){
DBWriteContactSettingWord(infoParam->hContact,S_MOD,"OldStatus",(WORD)(prevStatus|0x8000));
- if (includeIdle){
+ if (includeIdle)
DBWriteContactSettingByte(infoParam->hContact,S_MOD,"OldIdle",(BYTE)((prevStatus&0x8000)==0));
- }
+
DBWriteContactSettingWord(infoParam->hContact,S_MOD,"StatusTriger",infoParam->courStatus);
}
-// sprintf(str,"OutThread: %s; %s; %s\n",
-// infoParam->sProtoName,
-// (char *)CallService(MS_CLIST_GETCONTACTDISPLAYNAME,(WPARAM)infoParam->hContact,0),
-// (const char *)CallService(MS_CLIST_GETSTATUSMODEDESCRIPTION,(WPARAM)infoParam->courStatus,0)
-// );
-// infoParam->hContact = 0; //declare the slot as empty
+
contactQueue[infoParam->queueIndex] = 0;
free(infoParam);
-// OutputDebugStringA(str);
return 0;
}
diff --git a/plugins/Svc_dbepp/moduletree.cpp b/plugins/Svc_dbepp/moduletree.cpp index c927851ecc..b5554cabc5 100644 --- a/plugins/Svc_dbepp/moduletree.cpp +++ b/plugins/Svc_dbepp/moduletree.cpp @@ -462,10 +462,8 @@ void replaceTreeItem(HWND hwnd, HANDLE hContact, const char *module, const char TreeView_InsertItem(hwnd, &tvi);
}
-
}
-
void refreshTree(int restore)
{
UseKnownModList = DBGetContactSettingByte(NULL,modname,"UseKnownModList",0);
@@ -474,7 +472,6 @@ void refreshTree(int restore) forkthread(PopulateModuleTreeThreadFunc,0,(HWND)restore);
}
-
void __cdecl PopulateModuleTreeThreadFunc(LPVOID di)
{
TVINSERTSTRUCT tvi;
diff --git a/plugins/Updater/options.cpp b/plugins/Updater/options.cpp index 15e1d69754..e440cd684e 100644 --- a/plugins/Updater/options.cpp +++ b/plugins/Updater/options.cpp @@ -388,14 +388,11 @@ int OptInit(WPARAM wParam,LPARAM lParam) return 0;
}
-
-#define DBGetString DBGetContactSettingTString
-#define DBWriteString DBWriteContactSettingTString
-
-
-void InitOptionsMenuItems() {
+void InitOptionsMenuItems()
+{
if(options.restart_menu_item)
add_restart_menu_item();
+
if(options.update_and_exit_menu_item)
add_update_and_exit_menu_item();
}
|