mirror of
https://github.com/Nheko-Reborn/nheko.git
synced 2024-10-30 17:40:47 +03:00
Try to improve thumbnailing on macOS
This commit is contained in:
parent
30ba387076
commit
447a3d4cb9
1 changed files with 5 additions and 1 deletions
|
@ -879,7 +879,11 @@ MediaUpload::MediaUpload(std::unique_ptr<QIODevice> source_,
|
|||
}
|
||||
nhlog::ui()->debug("Duration changed {}", duration);
|
||||
});
|
||||
mediaPlayer->setMedia(QMediaContent(originalFilename_), source.get());
|
||||
|
||||
auto originalFile = qobject_cast<QFile *>(source.get());
|
||||
|
||||
mediaPlayer->setMedia(
|
||||
QMediaContent(originalFile ? originalFile->fileName() : originalFilename_), source.get());
|
||||
|
||||
mediaPlayer->play();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue