From a7c24ca48995cf2bf436156302f96b91bf135409 Mon Sep 17 00:00:00 2001 From: Goraf <22941576+Goraf@users.noreply.github.com> Date: Mon, 13 Nov 2017 15:03:31 +0100 Subject: Code modernize ... * replace 0/NULL with nullptr [using clang-tidy] --- plugins/MirandaG15/src/LCDFramework/CLCDTextObject.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'plugins/MirandaG15/src/LCDFramework/CLCDTextObject.cpp') diff --git a/plugins/MirandaG15/src/LCDFramework/CLCDTextObject.cpp b/plugins/MirandaG15/src/LCDFramework/CLCDTextObject.cpp index 236cefc71b..01026cf43d 100644 --- a/plugins/MirandaG15/src/LCDFramework/CLCDTextObject.cpp +++ b/plugins/MirandaG15/src/LCDFramework/CLCDTextObject.cpp @@ -6,7 +6,7 @@ //************************************************************************ // constructor //************************************************************************ -CLCDTextObject::CLCDTextObject() : m_bWordWrap(false), m_hFont(NULL), m_iFontHeight(0) +CLCDTextObject::CLCDTextObject() : m_bWordWrap(false), m_hFont(nullptr), m_iFontHeight(0) { // Initialize DRAWTEXTPARAMS memset(&m_dtp, 0, sizeof(DRAWTEXTPARAMS)); @@ -32,7 +32,7 @@ CLCDTextObject::~CLCDTextObject() bool CLCDTextObject::Initialize() { m_hFont = (HFONT) GetStockObject(DEFAULT_GUI_FONT); - if(NULL != m_hFont) + if(nullptr != m_hFont) { SetFontFaceName(L"Small Fonts"); SetFontPointSize(6); @@ -72,7 +72,7 @@ bool CLCDTextObject::SetFont(LOGFONT& lf) if (m_hFont) { DeleteObject(m_hFont); - m_hFont = NULL; + m_hFont = nullptr; } m_hFont = CreateFontIndirect(&lf); @@ -81,7 +81,7 @@ bool CLCDTextObject::SetFont(LOGFONT& lf) return false; // Calculate the font's height - HDC hDC = CreateCompatibleDC(NULL); + HDC hDC = CreateCompatibleDC(nullptr); SelectObject(hDC, m_hFont); TEXTMETRIC tmFontInfo; -- cgit v1.2.3