]> git.saurik.com Git - wxWidgets.git/blobdiff - samples/image/image.cpp
WinCE compilation fixes
[wxWidgets.git] / samples / image / image.cpp
index ee7ad0de60c7761bac2a347a26675ce2e2d91664..159f7fe26b450386455258542cdeae303eb4928b 100644 (file)
@@ -155,14 +155,14 @@ public:
                                                 wxT(""),
                                                 wxT(""),
                                                 (const wxChar *)NULL,
-                                            wxT("BMP files (*.bmp)|*.bmp|")
-                                            wxT("PNG files (*.png)|*.png|")
-                                            wxT("JPEG files (*.jpg)|*.jpg|")
-                                            wxT("GIF files (*.gif)|*.gif|")
-                                            wxT("TIFF files (*.tif)|*.tif|")
-                                            wxT("PCX files (*.pcx)|*.pcx|")
-                                            wxT("ICO files (*.ico)|*.ico|")
-                                            wxT("CUR files (*.cur)|*.cur"),
+                                                wxT("BMP files (*.bmp)|*.bmp|")
+                                                wxT("PNG files (*.png)|*.png|")
+                                                wxT("JPEG files (*.jpg)|*.jpg|")
+                                                wxT("GIF files (*.gif)|*.gif|")
+                                                wxT("TIFF files (*.tif)|*.tif|")
+                                                wxT("PCX files (*.pcx)|*.pcx|")
+                                                wxT("ICO files (*.ico)|*.ico|")
+                                                wxT("CUR files (*.cur)|*.cur"),
                                                 wxSAVE,
                                                 this);
 
@@ -216,7 +216,7 @@ public:
                         cmap[i] = (unsigned char)i;
                     image.SetPalette(wxPalette(256, cmap, cmap, cmap));
 
-                    delete cmap;
+                    delete[] cmap;
                 }
             }
         }
@@ -697,7 +697,7 @@ void MyCanvas::OnPaint( wxPaintEvent &WXUNUSED(event) )
     dc.DrawText( _T("PNM handler"), 30, 1285 );
     if (my_horse_pnm && my_horse_pnm->Ok())
         dc.DrawBitmap( *my_horse_pnm, 30, 1300 );
-    
+
     dc.DrawText( _T("PNM handler (ascii grey)"), 280, 1285 );
     if (my_horse_asciigrey_pnm && my_horse_asciigrey_pnm->Ok())
         dc.DrawBitmap( *my_horse_asciigrey_pnm, 280, 1300 );
@@ -898,10 +898,10 @@ void MyCanvas::CreateAntiAliasedBitmap()
 
 enum
 {
-    ID_QUIT  = 108,
-    ID_ABOUT,
-    ID_NEW,
-    ID_SHOWRAW
+    ID_QUIT  = wxID_EXIT,
+    ID_ABOUT = wxID_ABOUT,
+    ID_NEW = 100,
+    ID_SHOWRAW = 101
 };
 
 IMPLEMENT_DYNAMIC_CLASS( MyFrame, wxFrame )