From 1a22ce3c0422385121927b8385760501c530ac24 Mon Sep 17 00:00:00 2001 From: Eric Dill Date: Wed, 23 Mar 2016 11:43:44 -0400 Subject: [PATCH] MNT: Call close() up the inheritance chain --- pyqtgraph/widgets/GraphicsView.py | 3 ++- pyqtgraph/widgets/PlotWidget.py | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/pyqtgraph/widgets/GraphicsView.py b/pyqtgraph/widgets/GraphicsView.py index 06015e44..efde07a4 100644 --- a/pyqtgraph/widgets/GraphicsView.py +++ b/pyqtgraph/widgets/GraphicsView.py @@ -165,7 +165,8 @@ class GraphicsView(QtGui.QGraphicsView): self.sceneObj = None self.closed = True self.setViewport(None) - + super(GraphicsView, self).close() + def useOpenGL(self, b=True): if b: if not HAVE_OPENGL: diff --git a/pyqtgraph/widgets/PlotWidget.py b/pyqtgraph/widgets/PlotWidget.py index e27bce60..964307ae 100644 --- a/pyqtgraph/widgets/PlotWidget.py +++ b/pyqtgraph/widgets/PlotWidget.py @@ -69,7 +69,7 @@ class PlotWidget(GraphicsView): #self.scene().clear() #self.mPlotItem.close() self.setParent(None) - GraphicsView.close(self) + super(PlotWidget, self).close() def __getattr__(self, attr): ## implicitly wrap methods from plotItem if hasattr(self.plotItem, attr):