diff options
author | Goraf <goraf@miranda-ng.org> | 2016-01-30 21:56:49 +0000 |
---|---|---|
committer | Goraf <goraf@miranda-ng.org> | 2016-01-30 21:56:49 +0000 |
commit | c820fb6a8648b63e6d7d40b165ac047533dadfa3 (patch) | |
tree | e8bdc10a76a64b659ddae930561aa556faa687da /plugins/Popup/src | |
parent | 66d36547ef14644965d9a5afa46e4056716664b2 (diff) |
BITMAPINFO initialization
git-svn-id: http://svn.miranda-ng.org/main/trunk@16199 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Popup/src')
-rw-r--r-- | plugins/Popup/src/bitmap_funcs.cpp | 3 | ||||
-rw-r--r-- | plugins/Popup/src/opt_skins.cpp | 2 |
2 files changed, 2 insertions, 3 deletions
diff --git a/plugins/Popup/src/bitmap_funcs.cpp b/plugins/Popup/src/bitmap_funcs.cpp index f28dba8f28..a4f87e9c28 100644 --- a/plugins/Popup/src/bitmap_funcs.cpp +++ b/plugins/Popup/src/bitmap_funcs.cpp @@ -767,14 +767,13 @@ void MyBitmap::allocate(int w, int h) DeleteDC(dcBmp);
}
- BITMAPINFO bi;
+ BITMAPINFO bi = { 0 };
bi.bmiHeader.biSize = sizeof(bi.bmiHeader);
bi.bmiHeader.biWidth = w;
bi.bmiHeader.biHeight = -h;
bi.bmiHeader.biPlanes = 1;
bi.bmiHeader.biBitCount = 32;
bi.bmiHeader.biCompression = BI_RGB;
- bi.bmiColors[0].rgbRed = bi.bmiColors[0].rgbGreen = bi.bmiColors[0].rgbBlue = bi.bmiColors[0].rgbReserved = 0;
hBmp = (HBITMAP)CreateDIBSection(0, &bi, DIB_RGB_COLORS, (void **)&bits, 0, 0);
dcBmp = CreateCompatibleDC(0);
diff --git a/plugins/Popup/src/opt_skins.cpp b/plugins/Popup/src/opt_skins.cpp index 1fd334b1e7..70284a3f37 100644 --- a/plugins/Popup/src/opt_skins.cpp +++ b/plugins/Popup/src/opt_skins.cpp @@ -94,7 +94,7 @@ static void updatePreviewImage(HWND hwndBox) static void DrawPreview(HWND hwnd, HDC hdc)
{
- BITMAPINFO bi;
+ BITMAPINFO bi = { 0 };
bi.bmiHeader.biSize = sizeof(bi.bmiHeader);
bi.bmiHeader.biWidth = 8;
bi.bmiHeader.biHeight = -8;
|