summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorJoseph Donofry <joedonofry@gmail.com>2020-10-28 20:47:39 -0400
committerJoseph Donofry <joedonofry@gmail.com>2020-10-28 20:47:39 -0400
commit0a004b87dec0debb388f22d080a9362ff58f4a97 (patch)
tree18445e4283c1cc55c002d9f233ee1d60fedc903a /src
parentMake back button bigger as it is hard to tap with your thumb (diff)
downloadnheko-0a004b87dec0debb388f22d080a9362ff58f4a97.tar.xz
Fix clipboard image pasting crash on macos
Diffstat (limited to 'src')
-rw-r--r--src/TextInputWidget.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/TextInputWidget.cpp b/src/TextInputWidget.cpp

index 13a7c6d0..c75c6c89 100644 --- a/src/TextInputWidget.cpp +++ b/src/TextInputWidget.cpp
@@ -370,7 +370,7 @@ FilteredTextEdit::insertFromMimeData(const QMimeData *source) const auto audio = formats.filter("audio/", Qt::CaseInsensitive); const auto video = formats.filter("video/", Qt::CaseInsensitive); - if (source->hasImage()) { + if (!image.empty() && source->hasImage()) { QImage img = qvariant_cast<QImage>(source->imageData()); previewDialog_.setPreview(img, image.front()); } else if (!audio.empty()) {