summaryrefslogtreecommitdiff
path: root/plugins/Alarms/src/alarms.cpp
diff options
context:
space:
mode:
authorGoraf <22941576+Goraf@users.noreply.github.com>2017-11-13 15:03:31 +0100
committerGoraf <22941576+Goraf@users.noreply.github.com>2017-11-13 15:07:33 +0100
commita7c24ca48995cf2bf436156302f96b91bf135409 (patch)
tree953835509ff1b778833e78fd7b74b05e05e77c84 /plugins/Alarms/src/alarms.cpp
parent591ec17b1c99db7f120c22ca9fb20ae05fe78325 (diff)
Code modernize ...
* replace 0/NULL with nullptr [using clang-tidy]
Diffstat (limited to 'plugins/Alarms/src/alarms.cpp')
-rw-r--r--plugins/Alarms/src/alarms.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/plugins/Alarms/src/alarms.cpp b/plugins/Alarms/src/alarms.cpp
index dc7de3ca63..0e3139bc50 100644
--- a/plugins/Alarms/src/alarms.cpp
+++ b/plugins/Alarms/src/alarms.cpp
@@ -78,7 +78,7 @@ void ShowPopup(MCONTACT hContact, const wchar_t *msg)
ppd.colorBack = GetSysColor(COLOR_BTNFACE);
ppd.colorText = RGB(0, 0, 0);
ppd.PluginWindowProc = PopupDlgProc;
- ppd.PluginData = 0;
+ ppd.PluginData = nullptr;
ppd.iSeconds = 3;
// Now that every field has been filled, we want to see the popup.
@@ -103,18 +103,18 @@ HBITMAP LoadBmpFromIcon(int IdRes)
rc.right = bih.biWidth;
rc.bottom = bih.biHeight;
- HDC hdc = GetDC(NULL);
+ HDC hdc = GetDC(nullptr);
HBITMAP hBmp = CreateCompatibleBitmap(hdc, bih.biWidth, bih.biHeight);
HDC hdcMem = CreateCompatibleDC(hdc);
HBITMAP hoBmp = (HBITMAP)SelectObject(hdcMem, hBmp);
HBRUSH hBkgBrush = CreateSolidBrush(GetSysColor(COLOR_3DFACE));
FillRect(hdcMem, &rc, hBkgBrush);
- DrawIconEx(hdcMem, 2, 0, hIcon, 16, 16, 0, NULL, DI_NORMAL);
+ DrawIconEx(hdcMem, 2, 0, hIcon, 16, 16, 0, nullptr, DI_NORMAL);
SelectObject(hdcMem, hoBmp);
DeleteDC(hdcMem);
- ReleaseDC(NULL, hdc);
+ ReleaseDC(nullptr, hdc);
DeleteObject(hBkgBrush);
DeleteObject(hIcon);
@@ -124,7 +124,7 @@ HBITMAP LoadBmpFromIcon(int IdRes)
static int InitTopToolbarButton(WPARAM, LPARAM)
{
- TTBButton ttb = { 0 };
+ TTBButton ttb = {};
ttb.hIconUp = LoadIcon(hInst, MAKEINTRESOURCE(IDI_TBUP));
ttb.hIconDn = LoadIcon(hInst, MAKEINTRESOURCE(IDI_TBDN));
ttb.pszService = MODULE "/NewAlarm";