Skip to content

Commit

Permalink
Merge pull request #74 from radarhere/mingw-qt6
Browse files Browse the repository at this point in the history
Use QIODevice instead of QIODeviceBase
  • Loading branch information
hugovk committed Oct 17, 2021
2 parents d114837 + 43ceaa1 commit 033d1fc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/PIL/ImageQt.py
Expand Up @@ -34,7 +34,7 @@
for qt_version, qt_module in qt_versions:
try:
if qt_module == "PyQt6":
from PyQt6.QtCore import QBuffer, QIODevice, QIODeviceBase
from PyQt6.QtCore import QBuffer, QIODevice
from PyQt6.QtGui import QImage, QPixmap, qRgba
elif qt_module == "PySide6":
from PySide6.QtCore import QBuffer, QIODevice
Expand Down Expand Up @@ -68,7 +68,7 @@ def fromqimage(im):
buffer = QBuffer()
if qt_version == "6":
try:
qt_openmode = QIODeviceBase.OpenModeFlag
qt_openmode = QIODevice.OpenModeFlag
except AttributeError:
qt_openmode = QIODevice.OpenMode
else:
Expand Down

0 comments on commit 033d1fc

Please sign in to comment.