Change fix for #1909
This commit is contained in:
@@ -33,7 +33,7 @@ class PFListPane(wx.ScrolledWindow):
|
||||
self.SetBackgroundColour(wx.SystemSettings.GetColour(wx.SYS_COLOUR_WINDOW))
|
||||
|
||||
self.SetVirtualSize((1, 1))
|
||||
self.SetScrollRate(15, 15)
|
||||
self.SetScrollRate(0, 1)
|
||||
|
||||
self.Bind(wx.EVT_SCROLLWIN_LINEUP, self.MScrollUp)
|
||||
self.Bind(wx.EVT_SCROLLWIN_LINEDOWN, self.MScrollDown)
|
||||
@@ -151,6 +151,11 @@ class PFListPane(wx.ScrolledWindow):
|
||||
self._wList[i].Refresh()
|
||||
self.itemsHeight = max(self.itemsHeight, iheight - 1)
|
||||
|
||||
# This is needed as under GTK wx does not emit scroll up/scroll down
|
||||
# events, see issue #1909 for more info
|
||||
if 'wxGTK' in wx.PlatformInfo:
|
||||
self.SetScrollRate(0, self.itemsHeight)
|
||||
|
||||
def RemoveWidget(self, child):
|
||||
child.Destroy()
|
||||
self._wList.remove(child)
|
||||
|
||||
Reference in New Issue
Block a user