Change the fix again to not go into recursion problems on windows
This commit is contained in:
@@ -288,7 +288,7 @@ class ProjectedView(d.Display):
|
||||
if fitID is None:
|
||||
return
|
||||
|
||||
if self.getColumn(self.ScreenToClient(event.Position)) == self.getColIndex(State):
|
||||
if self.getColumn(self.screenToClientFixed(event.Position)) == self.getColIndex(State):
|
||||
return
|
||||
|
||||
sel = self.GetFirstSelected()
|
||||
|
||||
@@ -620,7 +620,7 @@ class FittingView(d.Display):
|
||||
event.Skip()
|
||||
|
||||
def spawnMenu(self, event):
|
||||
if self.activeFitID is None or self.getColumn(self.ScreenToClient(event.Position)) == self.getColIndex(State):
|
||||
if self.activeFitID is None or self.getColumn(self.screenToClientFixed(event.Position)) == self.getColIndex(State):
|
||||
return
|
||||
|
||||
sMkt = Market.getInstance()
|
||||
|
||||
@@ -275,11 +275,11 @@ class Display(wx.ListCtrl):
|
||||
def getRowByAbs(self, pointAbs):
|
||||
if pointAbs == wx.Point(-1, -1):
|
||||
return -1
|
||||
pointRel = self.ScreenToClient(pointAbs)
|
||||
pointRel = self.screenToClientFixed(pointAbs)
|
||||
row, flags = self.HitTest(pointRel)
|
||||
return row
|
||||
|
||||
def ScreenToClient(self, ptScreen):
|
||||
def screenToClientFixed(self, ptScreen):
|
||||
"""
|
||||
Wx' ScreenToClient implementation seems to not consider header row height when
|
||||
converting to screen position: https://github.com/wxWidgets/Phoenix/issues/1213
|
||||
|
||||
Reference in New Issue
Block a user