]> git.saurik.com Git - wxWidgets.git/commitdiff
fixed bug in wxDisplay::GetFromPoint() when Xinerama is not used (patch 813543)
authorVadim Zeitlin <vadim@wxwidgets.org>
Sat, 27 Sep 2003 13:58:10 +0000 (13:58 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Sat, 27 Sep 2003 13:58:10 +0000 (13:58 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@23967 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/unix/displayx11.cpp

index aae589676962911d83c7b6d03a6adf1e4048164c..807c20e804c4a84ef34f91cb3ef60d75ab443f12 100644 (file)
@@ -92,7 +92,16 @@ int wxDisplayBase::GetFromPoint(const wxPoint &p)
   }
   else
   {
-    return 0;
+    wxSize size = wxGetDisplaySize();
+    if (p.x >= 0 &&
+        p.x <= size.GetWidth() && 
+        p.y > 0 &&
+        p.y <= size.GetHeight())
+    {
+        return 0;
+    }
+
+    return -1
   }
 }