Skip to content

Commit

Permalink
Merge pull request #6 from irwir/updates
Browse files Browse the repository at this point in the history
Prefer default initialization.
  • Loading branch information
ppescher committed Jan 3, 2018
2 parents 27561e2 + 29db089 commit 4b518d9
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
3 changes: 1 addition & 2 deletions ResizableLib/ResizableComboLBox.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,7 @@ void CResizableComboLBox::InitializeControl()
m_sizeAfterSizing.cy += GetSystemMetrics(SM_CYHSCROLL);

// apply size constraints
WINDOWPOS wp;
ZeroMemory(&wp, sizeof(wp));
WINDOWPOS wp = {};
wp.cx = m_sizeAfterSizing.cx;
wp.cy = m_sizeAfterSizing.cy;
ApplyLimitsToPos(&wp);
Expand Down
5 changes: 1 addition & 4 deletions ResizableLib/ResizableSheetEx.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -406,7 +406,6 @@ BOOL CResizableSheetEx::OnEraseBkgnd(CDC* pDC)
if (m_psh.dwFlags & PSH_STRETCHWATERMARK)
{
BITMAP bmp;
ZeroMemory(&bmp, sizeof(bmp));
if (pHdr->GetBitmap(&bmp))
{
CDC dc;
Expand All @@ -429,9 +428,7 @@ BOOL CResizableSheetEx::OnEraseBkgnd(CDC* pDC)
pDC->FillSolidRect(&rect, ::GetSysColor(COLOR_WINDOW));
}
// get system font
NONCLIENTMETRICS ncm;
ZeroMemory(&ncm, sizeof(ncm));
ncm.cbSize = sizeof(NONCLIENTMETRICS);
NONCLIENTMETRICS ncm = {sizeof(NONCLIENTMETRICS)};
SystemParametersInfo(SPI_GETNONCLIENTMETRICS, 0, &ncm, 0);
// create fonts, with bold variant
CFont fontTitle, fontSubTitle;
Expand Down

0 comments on commit 4b518d9

Please sign in to comment.