diff options
author | Goraf <22941576+Goraf@users.noreply.github.com> | 2017-11-13 15:03:31 +0100 |
---|---|---|
committer | Goraf <22941576+Goraf@users.noreply.github.com> | 2017-11-13 15:07:33 +0100 |
commit | a7c24ca48995cf2bf436156302f96b91bf135409 (patch) | |
tree | 953835509ff1b778833e78fd7b74b05e05e77c84 /plugins/Sessions/Src/Utils.cpp | |
parent | 591ec17b1c99db7f120c22ca9fb20ae05fe78325 (diff) |
Code modernize ...
* replace 0/NULL with nullptr [using clang-tidy]
Diffstat (limited to 'plugins/Sessions/Src/Utils.cpp')
-rw-r--r-- | plugins/Sessions/Src/Utils.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/plugins/Sessions/Src/Utils.cpp b/plugins/Sessions/Src/Utils.cpp index c0f2e5ea90..98f731bd2f 100644 --- a/plugins/Sessions/Src/Utils.cpp +++ b/plugins/Sessions/Src/Utils.cpp @@ -225,7 +225,7 @@ void SetInSessionOrder(MCONTACT hContact, int mode, int count, unsigned int orde BOOL ResaveSettings(char *szName, int iFirst, int iLimit, wchar_t *szBuffer)
{
for (int i = iFirst; i < iLimit; i++) {
- if (szBuffer == NULL)
+ if (szBuffer == nullptr)
break;
char szNameBuf[256];
@@ -238,7 +238,7 @@ BOOL ResaveSettings(char *szName, int iFirst, int iLimit, wchar_t *szBuffer) BYTE marked = IsMarkedUserDefSession(i);
MarkUserDefSession(i, (BYTE)((i == iFirst) ? IsMarkedUserDefSession(iFirst - 1) : marked));
- if (ptszTemp == NULL) // read failed
+ if (ptszTemp == nullptr) // read failed
return 0;
szBuffer = ptszTemp;
@@ -350,7 +350,7 @@ void OffsetWindow(HWND parent, HWND hwnd, int dx, int dy) rc.top = pt.y;
OffsetRect(&rc, dx, dy);
- SetWindowPos(hwnd, NULL, rc.left, rc.top, 0, 0, SWP_NOZORDER | SWP_NOSIZE);
+ SetWindowPos(hwnd, nullptr, rc.left, rc.top, 0, 0, SWP_NOZORDER | SWP_NOSIZE);
}
int CheckContactVisibility(MCONTACT hContact)
@@ -398,5 +398,5 @@ void LoadPosition(HWND hWnd, char *wndName) int x = db_get_dw(0, MODNAME, buffer, ((GetSystemMetrics(SM_CXSCREEN)) / 2) - 130);
mir_snprintf(buffer, "%sPosY", wndName);
int y = db_get_dw(0, MODNAME, buffer, ((GetSystemMetrics(SM_CYSCREEN)) / 2) - 80);
- SetWindowPos(hWnd, NULL, x, y, 0, 0, SWP_NOZORDER | SWP_NOOWNERZORDER | SWP_NOSIZE);
+ SetWindowPos(hWnd, nullptr, x, y, 0, 0, SWP_NOZORDER | SWP_NOOWNERZORDER | SWP_NOSIZE);
}
|