Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 7b3c56b

Browse files
committed
Patch by Mike Droettboom, tracker 1745408, fix mem leak in wx
https://sourceforge.net/tracker/index.php?func=detail&aid=1745408&group_id=80706&atid=560722 svn path=/trunk/matplotlib/; revision=3441
1 parent 32ed2ca commit 7b3c56b

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

lib/matplotlib/backends/backend_wx.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1357,6 +1357,8 @@ def Destroy(self, *args, **kwargs):
13571357
wx.Frame.Destroy(self, *args, **kwargs)
13581358
if self.toolbar is not None:
13591359
self.toolbar.Destroy()
1360+
wxapp.Yield()
1361+
return True
13601362

13611363
class FigureManagerWx(FigureManagerBase):
13621364
"""
@@ -1397,7 +1399,6 @@ def showfig(*args):
13971399
def destroy(self, *args):
13981400
DEBUG_MSG("destroy()", 1, self)
13991401
self.frame.Destroy()
1400-
self.canvas.Destroy()
14011402
#if self.tb is not None: self.tb.Destroy()
14021403
import wx
14031404
#wx.GetApp().ProcessIdle()

0 commit comments

Comments
 (0)