diff options
author | dartraiden <wowemuh@gmail.com> | 2019-07-21 19:59:18 +0300 |
---|---|---|
committer | dartraiden <wowemuh@gmail.com> | 2019-07-21 19:59:18 +0300 |
commit | b078dfb78c89aea87cd422eae52694738e473cf3 (patch) | |
tree | ca896e82a8a5ce81f80d041f4aee7fdeeb007162 /plugins/Nudge/src | |
parent | ee7e29d02e94e969c1154515cd0c408c591a2414 (diff) |
Restore "Free for chat" status support (fixes #1963)
Diffstat (limited to 'plugins/Nudge/src')
-rw-r--r-- | plugins/Nudge/src/main.cpp | 4 | ||||
-rw-r--r-- | plugins/Nudge/src/nudge.h | 3 | ||||
-rw-r--r-- | plugins/Nudge/src/options.cpp | 5 | ||||
-rw-r--r-- | plugins/Nudge/src/resource.h | 1 |
4 files changed, 10 insertions, 3 deletions
diff --git a/plugins/Nudge/src/main.cpp b/plugins/Nudge/src/main.cpp index de3edb2e3d..d3febef813 100644 --- a/plugins/Nudge/src/main.cpp +++ b/plugins/Nudge/src/main.cpp @@ -121,7 +121,8 @@ static int NudgeReceived(WPARAM hContact, LPARAM lParam) ((p->statusFlags & NUDGE_ACC_ST3) && (Status == ID_STATUS_DND)) ||
((p->statusFlags & NUDGE_ACC_ST4) && (Status == ID_STATUS_NA)) ||
((p->statusFlags & NUDGE_ACC_ST5) && (Status == ID_STATUS_OCCUPIED)) ||
- ((p->statusFlags & NUDGE_ACC_ST6) && (Status == ID_STATUS_INVISIBLE)))
+ ((p->statusFlags & NUDGE_ACC_ST6) && (Status == ID_STATUS_FREECHAT)) ||
+ ((p->statusFlags & NUDGE_ACC_ST7) && (Status == ID_STATUS_INVISIBLE)))
{
if (diff >= GlobalNudge.recvTimeSec) {
if (p->showPopup)
@@ -161,6 +162,7 @@ static int NudgeReceived(WPARAM hContact, LPARAM lParam) ((DefaultNudge.statusFlags & NUDGE_ACC_ST3) && (Status == ID_STATUS_DND)) ||
((DefaultNudge.statusFlags & NUDGE_ACC_ST4) && (Status == ID_STATUS_NA)) ||
((DefaultNudge.statusFlags & NUDGE_ACC_ST5) && (Status == ID_STATUS_OCCUPIED)) ||
+ ((DefaultNudge.statusFlags & NUDGE_ACC_ST6) && (Status == ID_STATUS_FREECHAT)) ||
((DefaultNudge.statusFlags & NUDGE_ACC_ST6) && (Status == ID_STATUS_INVISIBLE)))
{
if (diff >= GlobalNudge.recvTimeSec) {
diff --git a/plugins/Nudge/src/nudge.h b/plugins/Nudge/src/nudge.h index 792a98444d..8b48a3ccf8 100644 --- a/plugins/Nudge/src/nudge.h +++ b/plugins/Nudge/src/nudge.h @@ -10,7 +10,8 @@ #define NUDGE_ACC_ST3 0x00000008 //Check (countdown) when Not available
#define NUDGE_ACC_ST4 0x00000010 //Check (countdown) when Occupied
#define NUDGE_ACC_ST5 0x00000020 //Check (countdown) when DND
-#define NUDGE_ACC_ST6 0x00000040 //Check (countdown) when Invisible
+#define NUDGE_ACC_ST6 0x00000040 //Check (countdown) when Free for chat
+#define NUDGE_ACC_ST7 0x00000080 //Check (countdown) when Invisible
#define TEXT_LEN 1024
diff --git a/plugins/Nudge/src/options.cpp b/plugins/Nudge/src/options.cpp index 4c88ba1d50..fada736a01 100644 --- a/plugins/Nudge/src/options.cpp +++ b/plugins/Nudge/src/options.cpp @@ -49,6 +49,7 @@ static void UpdateControls(HWND hwnd) CheckDlgButton(hwnd, IDC_CHECKST4, ActualNudge->statusFlags & NUDGE_ACC_ST4 ? BST_CHECKED : BST_UNCHECKED);
CheckDlgButton(hwnd, IDC_CHECKST5, ActualNudge->statusFlags & NUDGE_ACC_ST5 ? BST_CHECKED : BST_UNCHECKED);
CheckDlgButton(hwnd, IDC_CHECKST6, ActualNudge->statusFlags & NUDGE_ACC_ST6 ? BST_CHECKED : BST_UNCHECKED);
+ CheckDlgButton(hwnd, IDC_CHECKST7, ActualNudge->statusFlags & NUDGE_ACC_ST7 ? BST_CHECKED : BST_UNCHECKED);
SetDlgItemText(hwnd, IDC_SENDTEXT, ActualNudge->senText);
SetDlgItemText(hwnd, IDC_RECVTEXT, ActualNudge->recText);
}
@@ -266,6 +267,7 @@ static INT_PTR CALLBACK DlgProcNudgeOpt(HWND hwnd, UINT msg, WPARAM wParam, LPAR case IDC_CHECKST4:
case IDC_CHECKST5:
case IDC_CHECKST6:
+ case IDC_CHECKST7:
case IDC_CHECKPOP:
case IDC_OPENMESSAGE:
case IDC_CHECKCLIST:
@@ -315,7 +317,8 @@ static INT_PTR CALLBACK DlgProcNudgeOpt(HWND hwnd, UINT msg, WPARAM wParam, LPAR ((IsDlgButtonChecked(hwnd, IDC_CHECKST3) == BST_CHECKED) ? NUDGE_ACC_ST3 : 0) |
((IsDlgButtonChecked(hwnd, IDC_CHECKST4) == BST_CHECKED) ? NUDGE_ACC_ST4 : 0) |
((IsDlgButtonChecked(hwnd, IDC_CHECKST5) == BST_CHECKED) ? NUDGE_ACC_ST5 : 0) |
- ((IsDlgButtonChecked(hwnd, IDC_CHECKST6) == BST_CHECKED) ? NUDGE_ACC_ST6 : 0);
+ ((IsDlgButtonChecked(hwnd, IDC_CHECKST6) == BST_CHECKED) ? NUDGE_ACC_ST6 : 0) |
+ ((IsDlgButtonChecked(hwnd, IDC_CHECKST7) == BST_CHECKED) ? NUDGE_ACC_ST7 : 0);
GetDlgItemText(hwnd, IDC_SENDTEXT, ActualNudge->senText, TEXT_LEN);
GetDlgItemText(hwnd, IDC_RECVTEXT, ActualNudge->recText, TEXT_LEN);
diff --git a/plugins/Nudge/src/resource.h b/plugins/Nudge/src/resource.h index e6ef117378..34b0d091fd 100644 --- a/plugins/Nudge/src/resource.h +++ b/plugins/Nudge/src/resource.h @@ -48,6 +48,7 @@ #define IDC_CHECKST4 1023
#define IDC_CHECKST5 1024
#define IDC_CHECKST6 1025
+#define IDC_CHECKST7 1026
#define IDC_POPUPTEXTCOLOR 1027
#define IDC_BGCOLOUR 1030
#define IDC_PROTOLIST 1031
|