Reactos

[SHELL32] Add line bar to About dialog for consistence

Addendum to f9d2931. CORE-15215

authored by

Stanislav Motylkov and committed by
Hermès BÉLUSCA - MAÏTO
cc99d3ad ea2ca8fa

+16 -5
+1
dll/win32/shell32/bitmap_res.rc
··· 1 1 IDB_REACTOS BITMAP "res/bitmaps/reactos.bmp" 2 + IDB_LINEBAR BITMAP "res/bitmaps/line.bmp" 2 3 3 4 IDB_SHELL_IEXPLORE_LG BITMAP "res/bitmaps/204.bmp" 4 5 IDB_SHELL_IEXPLORE_LG_HOT BITMAP "res/bitmaps/205.bmp"
dll/win32/shell32/res/bitmaps/line.bmp

This is a binary file and will not be displayed.

+1
dll/win32/shell32/shresdef.h
··· 27 27 28 28 /* Bitmaps */ 29 29 #define IDB_REACTOS 131 30 + #define IDB_LINEBAR 138 30 31 #define IDB_SHELL_IEXPLORE_LG 204 31 32 #define IDB_SHELL_IEXPLORE_LG_HOT 205 32 33 #define IDB_SHELL_IEXPLORE_SM 206
+14 -5
dll/win32/shell32/wine/shell32_main.c
··· 1132 1132 static INT_PTR CALLBACK AboutDlgProc( HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam ) 1133 1133 { 1134 1134 static DWORD cxLogoBmp; 1135 - static DWORD cyLogoBmp; 1136 - static HBITMAP hLogoBmp; 1135 + static DWORD cyLogoBmp, cyLineBmp; 1136 + static HBITMAP hLogoBmp, hLineBmp; 1137 1137 static HWND hWndAuthors; 1138 1138 1139 1139 switch(msg) ··· 1153 1153 1154 1154 // Preload the ROS bitmap 1155 1155 hLogoBmp = (HBITMAP)LoadImage(shell32_hInstance, MAKEINTRESOURCE(IDB_REACTOS), IMAGE_BITMAP, 0, 0, LR_DEFAULTCOLOR); 1156 + hLineBmp = (HBITMAP)LoadImage(shell32_hInstance, MAKEINTRESOURCE(IDB_LINEBAR), IMAGE_BITMAP, 0, 0, LR_DEFAULTCOLOR); 1156 1157 1157 - if(hLogoBmp) 1158 + if(hLogoBmp && hLineBmp) 1158 1159 { 1159 1160 BITMAP bmpLogo; 1160 1161 ··· 1162 1163 1163 1164 cxLogoBmp = bmpLogo.bmWidth; 1164 1165 cyLogoBmp = bmpLogo.bmHeight; 1166 + 1167 + GetObject( hLineBmp, sizeof(BITMAP), &bmpLogo ); 1168 + cyLineBmp = bmpLogo.bmHeight; 1165 1169 } 1166 1170 1167 1171 // Set App-specific stuff (icon, app name, szOtherStuff string) ··· 1258 1262 1259 1263 case WM_PAINT: 1260 1264 { 1261 - if(hLogoBmp) 1265 + if(hLogoBmp && hLineBmp) 1262 1266 { 1263 1267 PAINTSTRUCT ps; 1264 1268 HDC hdc; 1265 1269 HDC hdcMem; 1270 + HGDIOBJ hOldObj; 1266 1271 1267 1272 hdc = BeginPaint(hWnd, &ps); 1268 1273 hdcMem = CreateCompatibleDC(hdc); 1269 1274 1270 1275 if(hdcMem) 1271 1276 { 1272 - SelectObject(hdcMem, hLogoBmp); 1277 + hOldObj = SelectObject(hdcMem, hLogoBmp); 1273 1278 BitBlt(hdc, 0, 0, cxLogoBmp, cyLogoBmp, hdcMem, 0, 0, SRCCOPY); 1274 1279 1280 + SelectObject(hdcMem, hLineBmp); 1281 + BitBlt(hdc, 0, cyLogoBmp, cxLogoBmp, cyLineBmp, hdcMem, 0, 0, SRCCOPY); 1282 + 1283 + SelectObject(hdcMem, hOldObj); 1275 1284 DeleteDC(hdcMem); 1276 1285 } 1277 1286