summaryrefslogtreecommitdiff
path: root/plugins/Popup/src/avatars_gif.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/Popup/src/avatars_gif.cpp
parent591ec17b1c99db7f120c22ca9fb20ae05fe78325 (diff)
Code modernize ...
* replace 0/NULL with nullptr [using clang-tidy]
Diffstat (limited to 'plugins/Popup/src/avatars_gif.cpp')
-rw-r--r--plugins/Popup/src/avatars_gif.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/plugins/Popup/src/avatars_gif.cpp b/plugins/Popup/src/avatars_gif.cpp
index 5b8cbac17c..3e8c257cc4 100644
--- a/plugins/Popup/src/avatars_gif.cpp
+++ b/plugins/Popup/src/avatars_gif.cpp
@@ -30,8 +30,8 @@ GifAvatar::GifAvatar(MCONTACT hContact) : PopupAvatar()
bIsValid = true;
GDIPlus_GetGIFSize(av->szFilename, &this->width, &this->height);
- hBitmap = NULL;
- frameDelays = NULL;
+ hBitmap = nullptr;
+ frameDelays = nullptr;
frameCount = 0;
frameSize.cx = frameSize.cy = 0;
@@ -44,7 +44,7 @@ GifAvatar::~GifAvatar()
{
if (frameDelays) {
mir_free(frameDelays);
- frameDelays = NULL;
+ frameDelays = nullptr;
}
if (hBitmap) DeleteObject(hBitmap);
}
@@ -65,7 +65,7 @@ void GifAvatar::draw(MyBitmap *bmp, int x, int y, int w, int h, POPUPOPTIONS *op
cachedHeight = h;
if (frameDelays) {
mir_free(frameDelays);
- frameDelays = NULL;
+ frameDelays = nullptr;
}
if (hBitmap) DeleteObject(hBitmap);
GDIPlus_ExtractAnimatedGIF(av->szFilename, w, h, hBitmap, frameDelays, frameCount, frameSize);
@@ -113,7 +113,7 @@ void GifAvatar::draw(MyBitmap *bmp, int x, int y, int w, int h, POPUPOPTIONS *op
bmp->restoreAlpha(x, y, w, h);
}
DeleteObject(rgn);
- SelectClipRgn(bmp->getDC(), NULL);
+ SelectClipRgn(bmp->getDC(), nullptr);
DeleteDC(hdcTmp);
activeFrame = (activeFrame + 1) % frameCount;