Fix full -c block

This commit is contained in:
lupoDharkael
2018-02-28 14:46:53 +01:00
parent 95e5b0eb64
commit fff5888152

View File

@@ -75,12 +75,13 @@ void FlameshotDBusAdapter::fullScreen(
Q_EMIT captureFailed(id);
return;
}
if(toClipboard) {
ResourceExporter().captureToClipboard(p);
}
// This needs to be done first in order to prevent a severe block
if(!path.isEmpty()) {
ResourceExporter().captureToFile(p, path);
}
if(toClipboard) {
ResourceExporter().captureToClipboard(p);
}
QByteArray byteArray;
QBuffer buffer(&byteArray);
p.save(&buffer, "PNG");