]> git.saurik.com Git - wxWidgets.git/blobdiff - src/x11/window.cpp
added missing headers to fix compilation without PCH
[wxWidgets.git] / src / x11 / window.cpp
index a83a67877cfed6d59a209b3a5cd59d3ef6307401..270bb56364edd3b9b512ff163ecc49db3f5d25d5 100644 (file)
@@ -251,7 +251,17 @@ void wxWindowX11::SetFocus()
     Window xwindow = (Window) GetMainWindow();
     
     wxCHECK_RET( xwindow, wxT("invalid window") );
-
+    
+    wxCHECK_RET( AcceptsFocus(), wxT("set focus on window that doesn't accept the focus") );
+    
+#if 0
+    if (GetName() == "scrollBar")
+    {
+        char *crash = NULL;
+        *crash = 0;
+    }
+#endif
+    
     if (wxWindowIsVisible(xwindow))
     {
         XSetInputFocus( wxGlobalDisplay(), xwindow, RevertToParent, CurrentTime );