summaryrefslogtreecommitdiff
path: root/plugins/BuddyExpectator/src
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2019-03-08 15:29:44 +0300
committerGeorge Hazan <ghazan@miranda.im>2019-03-08 15:29:44 +0300
commit99962115431435cf17dfae4d3b7c8d7d55d824bf (patch)
tree1c80a533f5d3d4ba9d3b894a9a38b9167fe3047e /plugins/BuddyExpectator/src
parenta23186175cff579d5aeb231372e87b0b852bdb38 (diff)
life is too short to remember whether this structure is zeroed or not
Diffstat (limited to 'plugins/BuddyExpectator/src')
-rw-r--r--plugins/BuddyExpectator/src/BuddyExpectator.cpp8
-rw-r--r--plugins/BuddyExpectator/src/options.cpp3
2 files changed, 4 insertions, 7 deletions
diff --git a/plugins/BuddyExpectator/src/BuddyExpectator.cpp b/plugins/BuddyExpectator/src/BuddyExpectator.cpp
index 46acde4e81..2f4226e18a 100644
--- a/plugins/BuddyExpectator/src/BuddyExpectator.cpp
+++ b/plugins/BuddyExpectator/src/BuddyExpectator.cpp
@@ -224,7 +224,7 @@ bool isContactGoneFor(MCONTACT hContact, int days)
if (options.hideInactive)
if (daysSinceMessage >= options.iSilencePeriod)
if (!db_get_b(hContact, "CList", "Hidden", 0) && !g_plugin.getByte(hContact, "NeverHide", 0)) {
- POPUPDATAW ppd = { 0 };
+ POPUPDATAW ppd;
ppd.lchContact = hContact;
ppd.lchIcon = IcoLib_GetIcon("enabled_icon");
@@ -259,7 +259,7 @@ void ReturnNotify(MCONTACT hContact, wchar_t *message)
if (options.iShowPopup > 0) {
// Display Popup
- POPUPDATAW ppd = { 0 };
+ POPUPDATAW ppd;
ppd.lchContact = hContact;
ppd.lchIcon = hIcon;
wcsncpy(ppd.lpwzContactName, Clist_GetContactDisplayName(hContact), MAX_CONTACTNAME);
@@ -296,7 +296,7 @@ void GoneNotify(MCONTACT hContact, wchar_t *message)
if (options.iShowPopup2 > 0) {
// Display Popup
- POPUPDATAW ppd = { 0 };
+ POPUPDATAW ppd;
ppd.lchContact = hContact;
ppd.lchIcon = hIcon;
wcsncpy(ppd.lpwzContactName, Clist_GetContactDisplayName(hContact), MAX_CONTACTNAME);
@@ -477,7 +477,7 @@ int SettingChanged(WPARAM hContact, LPARAM lParam)
if (prevStatus == ID_STATUS_OFFLINE) {
if (g_plugin.getByte(hContact, "MissYou", 0)) {
// Display Popup
- POPUPDATAW ppd = { 0 };
+ POPUPDATAW ppd;
ppd.lchContact = hContact;
ppd.lchIcon = IcoLib_GetIcon("enabled_icon");
wcsncpy(ppd.lpwzContactName, Clist_GetContactDisplayName(hContact), MAX_CONTACTNAME);
diff --git a/plugins/BuddyExpectator/src/options.cpp b/plugins/BuddyExpectator/src/options.cpp
index 96e2dd0856..a95abc0a5c 100644
--- a/plugins/BuddyExpectator/src/options.cpp
+++ b/plugins/BuddyExpectator/src/options.cpp
@@ -311,7 +311,6 @@ static INT_PTR CALLBACK PopupOptionsFrameProc(HWND hwndDlg, UINT uMsg, WPARAM wP
case WM_COMMAND:
if (LOWORD(wParam) == IDC_PREVIEW) {
POPUPDATAW ppd;
- memset(&ppd, 0, sizeof(ppd));
//iPopupDelay
options.iPopupDelay = GetDlgItemInt(hwndDlg, IDC_EDIT_POPUPDELAY, nullptr, FALSE);
@@ -340,12 +339,10 @@ static INT_PTR CALLBACK PopupOptionsFrameProc(HWND hwndDlg, UINT uMsg, WPARAM wP
}
ppd.PluginData = nullptr;
ppd.iSeconds = options.iPopupDelay;
-
PUAddPopupW(&ppd, APF_NO_HISTORY);
wcsncpy(ppd.lpwzText, TranslateT("You awaited this contact!"), MAX_SECONDLINE);
ppd.lchIcon = IcoLib_GetIcon("enabled_icon");
-
PUAddPopupW(&ppd, APF_NO_HISTORY);
}
else {