]> git.saurik.com Git - wxWidgets.git/blobdiff - src/motif/bitmap.cpp
Applied patch [ 662321 ] Port of wxWindows to Wine
[wxWidgets.git] / src / motif / bitmap.cpp
index fe00dc46faae2fe655e743a57c7137e10ae401bb..bace224758e891c5af9ee75f6400cabf07cf6dac 100644 (file)
@@ -211,7 +211,7 @@ bool wxBitmap::LoadFile(const wxString& filename, long type)
         if (!image.LoadFile( filename, type )) return FALSE;
         if (image.Ok()) 
         {
-            *this = image.ConvertToBitmap();
+            *this = wxBitmap(image);
             return TRUE;
         }
         else return FALSE;
@@ -242,7 +242,7 @@ bool wxBitmap::SaveFile(const wxString& filename, int type, const wxPalette *pal
     wxBitmapHandler *handler = FindHandler(type);
 
     if ( handler == NULL ) { // try wxImage
-        wxImage image( *this );
+        wxImage image = this->ConvertToImage();
         if (image.Ok()) return image.SaveFile( filename, type );
         else return FALSE;
     }