Changeset 9432
- Timestamp:
- Nov 26, 2002, 3:41:07 PM (22 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
TabularUnified trunk/src/user32/winicon.cpp ¶
r9409 r9432 1 /* $Id: winicon.cpp,v 1.3 7 2002-11-13 14:54:58sandervl Exp $ */1 /* $Id: winicon.cpp,v 1.38 2002-11-26 14:41:07 sandervl Exp $ */ 2 2 /* 3 3 * Win32 Icon Code for OS/2 … … 1051 1051 //SvL: Must use CreateBitmap here as CreateDIBitmap converts data to 8bpp (GetObjectA info -> 8 bpp) 1052 1052 #if 1 1053 int linewidth = BITMAP_GetWidthBytes(width, 1); 1053 int linewidth; 1054 int orglinewidth; 1055 1056 linewidth = BITMAP_GetWidthBytes(width, 1); 1057 1058 //the lines in the image might be aligned differently 1059 //CreateBitmap expects them to be optimally aligned 1060 //(as calculated by BITMAP_GetWidthBytes) 1061 //(For now only applies when both masks (and/xor) aren't present) 1062 if(pInfo->bmiHeader.biSizeImage > colorsize + bwsize) { 1063 orglinewidth = (pInfo->bmiHeader.biSizeImage - colorsize)/height; 1064 } 1065 else orglinewidth = linewidth; 1054 1066 1055 1067 char *newpix = (char *)malloc(linewidth*height); … … 1069 1081 memcpy(newpix, xbits, linewidth); 1070 1082 newpix -= linewidth; 1071 xbits += linewidth;1083 xbits += orglinewidth; 1072 1084 } 1073 1085 }
Note:
See TracChangeset
for help on using the changeset viewer.