summaryrefslogtreecommitdiff
path: root/plugins/TabSRMM/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/TabSRMM/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/TabSRMM/src')
-rw-r--r--plugins/TabSRMM/src/chat_tools.cpp2
-rw-r--r--plugins/TabSRMM/src/msgs.cpp2
-rw-r--r--plugins/TabSRMM/src/typingnotify.cpp5
3 files changed, 4 insertions, 5 deletions
diff --git a/plugins/TabSRMM/src/chat_tools.cpp b/plugins/TabSRMM/src/chat_tools.cpp
index cb22e44284..937c460af7 100644
--- a/plugins/TabSRMM/src/chat_tools.cpp
+++ b/plugins/TabSRMM/src/chat_tools.cpp
@@ -124,7 +124,7 @@ int ShowPopup(MCONTACT hContact, SESSION_INFO *si, HICON hIcon, char* pszProtoNa
pd.PluginWindowProc = PopupDlgProc;
pd.PluginData = si;
- return PUAddPopupW(&pd);
+ return (int)PUAddPopupW(&pd);
}
BOOL DoPopup(SESSION_INFO *si, GCEVENT *gce)
diff --git a/plugins/TabSRMM/src/msgs.cpp b/plugins/TabSRMM/src/msgs.cpp
index 694f823531..75e826a44e 100644
--- a/plugins/TabSRMM/src/msgs.cpp
+++ b/plugins/TabSRMM/src/msgs.cpp
@@ -248,7 +248,7 @@ void CTabBaseDlg::NotifyDeliveryFailure() const
if (M.GetByte("adv_noErrorPopups", 0))
return;
- if (CallService(MS_POPUP_QUERY, PUQS_GETSTATUS, 0) != 1)
+ if (!Popup_Enabled())
return;
POPUPDATAW ppd = { 0 };
diff --git a/plugins/TabSRMM/src/typingnotify.cpp b/plugins/TabSRMM/src/typingnotify.cpp
index f65d1f8965..353d45f7cb 100644
--- a/plugins/TabSRMM/src/typingnotify.cpp
+++ b/plugins/TabSRMM/src/typingnotify.cpp
@@ -96,8 +96,7 @@ void TN_TypingMessage(MCONTACT hContact, int iMode)
}
int notyping;
- POPUPDATAW_V2 ppd = { 0 };
- ppd.cbSize = sizeof(ppd);
+ POPUPDATAW ppd = { 0 };
if (iMode == PROTOTYPE_CONTACTTYPING_OFF) {
if (StopDisabled)
@@ -164,7 +163,7 @@ void TN_TypingMessage(MCONTACT hContact, int iMode)
ppd.lchIcon = PluginConfig.g_buttonBarIcons[ICON_DEFAULT_TYPING];
ppd.lchContact = hContact;
ppd.PluginWindowProc = PopupDlgProc;
- PUAddPopupW(&ppd, APF_NEWDATA);
+ PUAddPopupW(&ppd);
}
static INT_PTR CALLBACK DlgProcOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam)