bitmap->SetHeight(bm.bmHeight);
bitmap->SetDepth(bm.bmBitsPixel);
+ // use 0xc0c0c0 as transparent colour by default
+ bitmap->SetMask(new wxMask(*bitmap, *wxLIGHT_GREY));
+
return true;
}
wxDIB dib(name);
- return dib.IsOk() && bitmap->CopyFromDIB(dib);
+ bool ok = dib.IsOk() && bitmap->CopyFromDIB(dib);
+ return ok;
#else
WXHBITMAP hBitmap = (WXHBITMAP)wxLoadBMP(name);
if(hBitmap) {