Changeset 722 for trunk/src/comctl32/propsheet.c
- Timestamp:
- Aug 28, 1999, 11:25:56 AM (26 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/comctl32/propsheet.c
r496 r722 1 /* $Id: propsheet.c,v 1. 7 1999-08-14 16:13:12 cbratschiExp $ */1 /* $Id: propsheet.c,v 1.8 1999-08-28 09:25:56 achimha Exp $ */ 2 2 /* 3 3 * Property Sheets … … 13 13 * - Unicode property sheets 14 14 */ 15 16 /* WINE 990815 level */ 15 17 16 18 /* CB: Odin problems: … … 67 69 int width; 68 70 int height; 71 HIMAGELIST hImageList; 69 72 } PropSheetInfo; 70 73 … … 159 162 psInfo->restartWindows = FALSE; 160 163 psInfo->rebootSystem = FALSE; 164 psInfo->hImageList = 0; 161 165 162 166 return TRUE; … … 277 281 // TRACE(propsheet, "Tab %d %s\n",index,debugstr_w((LPCWSTR)p)); 278 282 p += lstrlenW((LPCWSTR)p) + 1; 283 284 /* 285 * Build the image list for icons 286 */ 287 if ((dwFlags & PSP_USEHICON) || (dwFlags & PSP_USEICONID)) 288 { 289 HICON hIcon; 290 int icon_cx = GetSystemMetrics(SM_CXSMICON); 291 int icon_cy = GetSystemMetrics(SM_CYSMICON); 292 293 if (dwFlags & PSP_USEICONID) 294 hIcon = LoadImageA(lppsp->hInstance, lppsp->u2.pszIcon, IMAGE_ICON, 295 icon_cx, icon_cy, LR_DEFAULTCOLOR); 296 else 297 hIcon = lppsp->u2.hIcon; 298 299 if (psInfo->hImageList == 0) 300 psInfo->hImageList = ImageList_Create(icon_cx, icon_cy, ILC_COLOR, 1, 1); 301 302 ImageList_AddIcon(psInfo->hImageList, hIcon); 303 } 279 304 280 305 return TRUE; … … 577 602 nTabs = psInfo->ppshheader->nPages; 578 603 604 /* 605 * Set the image list for icons. 606 */ 607 if (psInfo->hImageList) 608 { 609 item.mask |= TCIF_IMAGE; 610 SendMessageA(hwndTabCtrl, TCM_SETIMAGELIST, 0, (LPARAM)psInfo->hImageList); 611 } 612 579 613 for (i = 0; i < nTabs; i++) 580 614 { 615 item.iImage = i; 616 581 617 WideCharToMultiByte(CP_ACP, 0, 582 618 (LPCWSTR)psInfo->proppage[i].pszText, … … 1193 1229 COMCTL32_Free(psInfo->proppage); 1194 1230 COMCTL32_Free(psInfo->strPropertiesFor); 1231 ImageList_Destroy(psInfo->hImageList); 1195 1232 1196 1233 GlobalFree((HGLOBAL)psInfo);
Note:
See TracChangeset
for help on using the changeset viewer.