Skip to content

Commit b36388a

Browse files
committed
Okay, it does not work in Qt4 version either.
Traceback (most recent call last): File "/home/Hin-Tak/my-git/skia-python-examples/glwidget_abouttobedestroyed.py", line 38, in <module> main() ~~~~^^ File "/home/Hin-Tak/my-git/skia-python-examples/glwidget_abouttobedestroyed.py", line 33, in main window = MainWindow() File "/home/Hin-Tak/my-git/skia-python-examples/glwidget_abouttobedestroyed.py", line 29, in __init__ self.setCentralWidget(MyOpenGLWidget(self)) ~~~~~~~~~~~~~~^^^^^^ File "/home/Hin-Tak/my-git/skia-python-examples/glwidget_abouttobedestroyed.py", line 10, in __init__ self.aboutToBeDestroyed.connect(self.cleanupGL) ^^^^^^^^^^^^^^^^^^^^^^^ AttributeError: 'MyOpenGLWidget' object has no attribute 'aboutToBeDestroyed'
1 parent 42aff4c commit b36388a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

glwidget_abouttobedestroyed.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
from PyQt5.QtWidgets import QApplication, QMainWindow
2-
from PyQt5.QtOpenGL import QGLWidget
3-
from PyQt5.QtCore import pyqtSlot
1+
from PyQt4.QtGui import QApplication, QMainWindow
2+
from PyQt4.QtOpenGL import QGLWidget
3+
from PyQt4.QtCore import pyqtSlot
44
import sys
55

66
class MyOpenGLWidget(QGLWidget):

0 commit comments

Comments
 (0)