Fix OSD D-Bus assertion with Qt 6

This commit is contained in:
Jonas Kvinge 2020-08-10 23:05:07 +02:00
parent 0ce613264f
commit be966488e8
1 changed files with 1 additions and 1 deletions

View File

@ -83,7 +83,7 @@ QDBusArgument &operator<<(QDBusArgument &arg, const QImage &image) {
arg.beginStructure(); arg.beginStructure();
arg << i.width(); arg << i.width();
arg << i.height(); arg << i.height();
arg << i.bytesPerLine(); arg << static_cast<qint32>(i.bytesPerLine());
arg << i.hasAlphaChannel(); arg << i.hasAlphaChannel();
int channels = i.isGrayscale() ? 1 : (i.hasAlphaChannel() ? 4 : 3); int channels = i.isGrayscale() ? 1 : (i.hasAlphaChannel() ? 4 : 3);
arg << i.depth() / channels; arg << i.depth() / channels;