]> git.saurik.com Git - wxWidgets.git/blobdiff - samples/controls/controls.cpp
compilation fix for recent commit
[wxWidgets.git] / samples / controls / controls.cpp
index 0b85c4d46e5088c23f0c6ee48c389692b2df9a53..8c696f260ecc9cddb7cc012406a985d58e4ad10c 100644 (file)
@@ -34,7 +34,7 @@
     #include "wx/tooltip.h"
 #endif
 
-#if defined(__WXGTK__) || defined(__WXMOTIF__) || defined(__WXMAC__)
+#if defined(__WXGTK__) || defined(__WXMOTIF__) || defined(__WXMAC__) || defined(__WXMGL__)
     #define USE_XPM
 #endif
 
@@ -943,8 +943,8 @@ void MyPanel::OnListBoxButtons( wxCommandEvent &event )
         case ID_LISTBOX_ENABLE:
             {
                 m_text->AppendText("Checkbox clicked.\n");
-                wxCheckBox *cb = (wxCheckBox*)event.GetEventObject();
 #if wxUSE_TOOLTIPS
+                wxCheckBox *cb = (wxCheckBox*)event.GetEventObject();
                 if (event.GetInt())
                     cb->SetToolTip( "Click to enable listbox" );
                 else