]> git.saurik.com Git - wxWidgets.git/blobdiff - src/motif/dcscreen.cpp
added an error message if a bitmap can't be addedto the image list
[wxWidgets.git] / src / motif / dcscreen.cpp
index 2f5d52453b63eac07782c27101e69d63100f211f..cdb5ed5dd43cc547c67dafbe609c991998987e67 100644 (file)
@@ -66,7 +66,8 @@ bool wxScreenDC::StartDrawingOnTop(wxWindow* window)
   wxRect rect;
   int x, y, width, height;
   window->GetPosition(& x, & y);
-  window->ClientToScreen(& x, & y);
+  if (window->GetParent())
+      window->GetParent()->ClientToScreen(& x, & y);
   window->GetSize(& width, & height);
   rect.x = x; rect.y = y;
   rect.width = width; rect.height = height;