]> git.saurik.com Git - wxWidgets.git/blobdiff - src/mac/carbon/window.cpp
Hack to support iso8859 and other wrongly formated
[wxWidgets.git] / src / mac / carbon / window.cpp
index b8a268cd53b1b07e06602330c2374f1ffac5a7f9..2a6f6dfd9c0a602835557386e07dafa9f5e89031 100644 (file)
 #include "wx/spinctrl.h"
 #include "wx/geometry.h"
 
+#if wxUSE_LISTCTRL
+    #include "wx/listctrl.h"
+#endif
+
+#if wxUSE_TREECTRL
+    #include "wx/treectrl.h"
+#endif
+
 #if wxUSE_CARET
     #include "wx/caret.h"
 #endif
@@ -302,14 +310,17 @@ static pascal OSStatus wxMacWindowControlEventHandler( EventHandlerCallRef handl
             
         case kEventControlActivate :
         case kEventControlDeactivate :
-            if ( thisWindow->IsKindOf( CLASSINFO( wxTreeCtrl ) ) 
-                    || thisWindow->IsKindOf( CLASSINFO( wxListCtrl ) ) 
-                )
+            // FIXME: we should have a virtual function for this!
+#if wxUSE_TREECTRL
+            if ( thisWindow->IsKindOf( CLASSINFO( wxTreeCtrl ) ) )
                 thisWindow->Refresh();
-            
-            //thisWindow->MacActivateStateChanged() ;
-            break ;
 #endif
+#if wxUSE_LISTCTRL
+            if ( thisWindow->IsKindOf( CLASSINFO( wxListCtrl ) ) )
+                thisWindow->Refresh();
+#endif
+            break ;
+#endif // TARGET_API_MAC_OSX
 
         // we emulate this event under Carbon CFM
         case kEventControlSetFocusPart :