From b70fcd96591935722060cabebd2b4be9208259aa Mon Sep 17 00:00:00 2001 From: DarkPhoenix Date: Wed, 24 Apr 2019 11:46:20 +0300 Subject: [PATCH] Change ScreenToClient fix --- gui/display.py | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/gui/display.py b/gui/display.py index c6c4acd69..f009bd251 100644 --- a/gui/display.py +++ b/gui/display.py @@ -287,12 +287,7 @@ class Display(wx.ListCtrl): """ if ptScreen == wx.Point(-1, -1): return wx.Point(-1, -1) - for window in self.GetChildren(): - if window.GetName() == 'panel': - ptCorrection = window.GetPosition() - ptScreen = ptScreen - ptCorrection - break - ptClient = wx.ListCtrl.ScreenToClient(self, ptScreen) + ptClient = self.GetMainWindow().ScreenToClient(ptScreen) return ptClient def getSelectedRows(self):