From 6d8904f7b96bf24618e9493b8cee050868be3e82 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Mon, 21 Jan 2019 14:23:36 +0300 Subject: fixes #1776 (rest of URL atavisms) --- plugins/KeyboardNotify/src/flash.cpp | 14 ++++---------- plugins/KeyboardNotify/src/main.cpp | 4 +--- plugins/KeyboardNotify/src/options.cpp | 7 ++----- plugins/KeyboardNotify/src/resource.h | 1 - 4 files changed, 7 insertions(+), 19 deletions(-) (limited to 'plugins/KeyboardNotify/src') diff --git a/plugins/KeyboardNotify/src/flash.cpp b/plugins/KeyboardNotify/src/flash.cpp index 86b8c528aa..d1d9edfbd4 100644 --- a/plugins/KeyboardNotify/src/flash.cpp +++ b/plugins/KeyboardNotify/src/flash.cpp @@ -35,7 +35,7 @@ static void __cdecl TestThread(void *param); static void PreviewThread(void *); FLASHING_SEQUENCE str2FS(wchar_t *); BYTE KbdChar2Byte(char); -void countUnopenEvents(int *, int *, int *, int *); +void countUnopenEvents(int *, int *, int *); #define Leds2Flash ((BYTE)(bFlashLed[2] + (bFlashLed[0]<<1) + (bFlashLed[1]<<2))) @@ -45,7 +45,7 @@ BOOL bTemporarilyUseExtern; extern BYTE bFlashLed[3]; extern BYTE bFlashEffect; extern BYTE bSequenceOrder; extern WORD wCustomTheme; -extern BYTE bTrillianLedsMsg; extern BYTE bTrillianLedsURL; extern BYTE bTrillianLedsFile; extern BYTE bTrillianLedsOther; +extern BYTE bTrillianLedsMsg, bTrillianLedsFile, bTrillianLedsOther; extern BYTE bEmulateKeypresses; // TestThread/PreviewThread globals @@ -165,10 +165,10 @@ FLASHING_SEQUENCE *getTrillianSeq(void) void updateTrillianSeq(void) { - int i, msgCount=0, fileCount=0, urlCount=0, otherCount=0; + int i, msgCount=0, fileCount=0, otherCount=0; pFS->size = 2; - countUnopenEvents(&msgCount, &fileCount, &urlCount, &otherCount); + countUnopenEvents(&msgCount, &fileCount, &otherCount); if ((bTrillianLedsMsg & Leds2Flash) && (pFS->size + 2 * msgCount) <= MAX_PATH) for (i=0; i < msgCount; i++) { @@ -182,12 +182,6 @@ void updateTrillianSeq(void) pFS->frame[pFS->size++] = 0; } - if ((bTrillianLedsURL & Leds2Flash) && (pFS->size + 2 * urlCount) <= MAX_PATH) - for (i=0; i < urlCount; i++) { - pFS->frame[pFS->size++] = bTrillianLedsURL & Leds2Flash; - pFS->frame[pFS->size++] = 0; - } - if ((bTrillianLedsOther & Leds2Flash) && (pFS->size + 2 * otherCount) <= MAX_PATH) for (i=0; i < otherCount; i++) { pFS->frame[pFS->size++] = bTrillianLedsOther & Leds2Flash; diff --git a/plugins/KeyboardNotify/src/main.cpp b/plugins/KeyboardNotify/src/main.cpp index d10bbdb9af..adbe79029d 100644 --- a/plugins/KeyboardNotify/src/main.cpp +++ b/plugins/KeyboardNotify/src/main.cpp @@ -45,7 +45,6 @@ DWORD dwLastInput = 0; POINT lastGlobalMousePos = { 0, 0 }; BYTE bFlashOnMsg; -BYTE bFlashOnURL; BYTE bFlashOnFile; BYTE bFlashOnOther; BYTE bFullScreenMode; @@ -663,7 +662,6 @@ int UnhookWindowsHooks() void LoadSettings(void) { bFlashOnMsg = g_plugin.getByte("onmsg", DEF_SETTING_ONMSG); - bFlashOnURL = g_plugin.getByte("onurl", DEF_SETTING_ONURL); bFlashOnFile = g_plugin.getByte("onfile", DEF_SETTING_ONFILE); bFlashOnOther = g_plugin.getByte("onother", DEF_SETTING_OTHER); bFullScreenMode = g_plugin.getByte("fscreenmode", DEF_SETTING_FSCREEN); @@ -845,7 +843,7 @@ BOOL CheckMsgWnd(MCONTACT hContact, BOOL *focus) } -void countUnopenEvents(int *msgCount, int *fileCount, int *urlCount, int *otherCount) +void countUnopenEvents(int *msgCount, int *fileCount, int *otherCount) { int nIndex; CLISTEVENT *pCLEvent; diff --git a/plugins/KeyboardNotify/src/options.cpp b/plugins/KeyboardNotify/src/options.cpp index 273d87793c..47fbb0a007 100644 --- a/plugins/KeyboardNotify/src/options.cpp +++ b/plugins/KeyboardNotify/src/options.cpp @@ -18,11 +18,11 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include "stdafx.h" -#define IDI_BLANK 200 +#define IDI_BLANK 200 void LoadSettings(void); -extern BYTE bFlashOnMsg, bFlashOnURL, bFlashOnFile, bFlashOnOther, bFullScreenMode, bScreenSaverRunning, bWorkstationLocked, bProcessesAreRunning, +extern BYTE bFlashOnMsg, bFlashOnFile, bFlashOnOther, bFullScreenMode, bScreenSaverRunning, bWorkstationLocked, bProcessesAreRunning, bWorkstationActive, bFlashIfMsgOpen, bFlashIfMsgOlder, bFlashUntil, bMirandaOrWindows, bFlashLed[3], bFlashEffect, bSequenceOrder, bFlashSpeed, bEmulateKeypresses, bOverride, bFlashIfMsgWinNotTop, bTrillianLedsMsg, bTrillianLedsURL, bTrillianLedsFile, bTrillianLedsOther; extern WORD wSecondsOlder, wBlinksNumber, wStatusMap, wReminderCheck, wCustomTheme, wStartDelay; @@ -597,7 +597,6 @@ static INT_PTR CALLBACK DlgProcBasicOptions(HWND hwndDlg, UINT msg, WPARAM wPara createXstatusListAux(); CheckDlgButton(hwndDlg, IDC_ONMESSAGE, bFlashOnMsg ? BST_CHECKED : BST_UNCHECKED); - CheckDlgButton(hwndDlg, IDC_ONURL, bFlashOnURL ? BST_CHECKED : BST_UNCHECKED); CheckDlgButton(hwndDlg, IDC_ONFILE, bFlashOnFile ? BST_CHECKED : BST_UNCHECKED); CheckDlgButton(hwndDlg, IDC_ONOTHER, bFlashOnOther ? BST_CHECKED : BST_UNCHECKED); @@ -671,7 +670,6 @@ static INT_PTR CALLBACK DlgProcBasicOptions(HWND hwndDlg, UINT msg, WPARAM wPara case WM_COMMAND: switch (LOWORD(wParam)) { case IDC_ONMESSAGE: - case IDC_ONURL: case IDC_ONFILE: case IDC_ONOTHER: case IDC_IFOPEN: @@ -751,7 +749,6 @@ static INT_PTR CALLBACK DlgProcBasicOptions(HWND hwndDlg, UINT msg, WPARAM wPara switch (((LPNMHDR)lParam)->code) { case PSN_APPLY: g_plugin.setByte("onmsg", (BYTE)(IsDlgButtonChecked(hwndDlg, IDC_ONMESSAGE) == BST_CHECKED ? 1 : 0)); - g_plugin.setByte("onurl", (BYTE)(IsDlgButtonChecked(hwndDlg, IDC_ONURL) == BST_CHECKED ? 1 : 0)); g_plugin.setByte("onfile", (BYTE)(IsDlgButtonChecked(hwndDlg, IDC_ONFILE) == BST_CHECKED ? 1 : 0)); g_plugin.setByte("onother", (BYTE)(IsDlgButtonChecked(hwndDlg, IDC_ONOTHER) == BST_CHECKED ? 1 : 0)); diff --git a/plugins/KeyboardNotify/src/resource.h b/plugins/KeyboardNotify/src/resource.h index 78e99972b7..87528e8fec 100644 --- a/plugins/KeyboardNotify/src/resource.h +++ b/plugins/KeyboardNotify/src/resource.h @@ -15,7 +15,6 @@ #define IDD_XSTATUSES 158 #define IDC_ONMESSAGE 1000 #define IDC_ONFILE 1001 -#define IDC_ONURL 1002 #define IDC_ONOTHER 1003 #define IDC_IFOPEN 1004 #define IDC_IFNOTTOP 1005 -- cgit v1.2.3