summaryrefslogtreecommitdiff
path: root/plugins/NewXstatusNotify/src
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2019-03-06 16:15:45 +0300
committerGeorge Hazan <ghazan@miranda.im>2019-03-06 16:15:55 +0300
commitf580be3d9dcccb14831d6bed9e7dfca600f5b6f8 (patch)
tree468913d477b9d2a9fb430df9a886d24a8cf41887 /plugins/NewXstatusNotify/src
parent827dbce0a554ccc313fd0b14b45bd57dffeead95 (diff)
popups:
- internal implementation details & all service declarations moved to m_popup_int.h; - all service calls removed and replaced with function calls; - direct access to popup serttings replaced with Popup_Enable / Popup_Enabled;
Diffstat (limited to 'plugins/NewXstatusNotify/src')
-rw-r--r--plugins/NewXstatusNotify/src/main.cpp14
1 files changed, 4 insertions, 10 deletions
diff --git a/plugins/NewXstatusNotify/src/main.cpp b/plugins/NewXstatusNotify/src/main.cpp
index cd52dde535..c2bfa62a6e 100644
--- a/plugins/NewXstatusNotify/src/main.cpp
+++ b/plugins/NewXstatusNotify/src/main.cpp
@@ -816,21 +816,15 @@ int StatusModeChanged(WPARAM wParam, LPARAM lParam)
BYTE hlpDisablePopup = g_plugin.getByte(szSetting, 0);
if (hlpDisablePopup != opt.PopupAutoDisabled) {
- BYTE hlpPopupStatus = (BYTE)CallService(MS_POPUP_QUERY, PUQS_GETSTATUS, 0);
+ bool hlpPopupStatus = Popup_Enabled();
opt.PopupAutoDisabled = hlpDisablePopup;
if (hlpDisablePopup) {
g_plugin.setByte("OldPopupStatus", hlpPopupStatus);
- CallService(MS_POPUP_QUERY, PUQS_DISABLEPOPUPS, 0);
- }
- else {
- if (hlpPopupStatus == FALSE) {
- if (g_plugin.getByte("OldPopupStatus", TRUE) == TRUE)
- CallService(MS_POPUP_QUERY, PUQS_ENABLEPOPUPS, 0);
- else
- CallService(MS_POPUP_QUERY, PUQS_DISABLEPOPUPS, 0);
- }
+ Popup_Enable(false);
}
+ else if (!hlpPopupStatus)
+ Popup_Enable(g_plugin.getByte("OldPopupStatus", true));
}
}