]> git.saurik.com Git - wxWidgets.git/blobdiff - src/univ/scrolbar.cpp
reverted wxMGL-specific code (didn't mean to commit this...)
[wxWidgets.git] / src / univ / scrolbar.cpp
index e2f146b7d42f1d7e270f74545f21c7c65c47fde1..464681e6453fa9801ea676af6bc63fac175796cc 100644 (file)
@@ -164,6 +164,24 @@ wxScrollBar::~wxScrollBar()
 {
 }
 
+bool wxScrollBar::AcceptsFocus() const
+{
+    if (!wxWindow::AcceptsFocus()) return FALSE;
+    
+    wxWindow *parent = (wxWindow*) GetParent();
+    
+    if (parent)
+    {
+        if ((parent->GetScrollbar( wxHORIZONTAL ) == this) ||
+            (parent->GetScrollbar( wxVERTICAL ) == this))
+        {
+            return FALSE;
+        }
+    }
+    
+    return TRUE;
+}
+
 // ----------------------------------------------------------------------------
 // scrollbar API
 // ----------------------------------------------------------------------------