ensure that the shortcut destination exists
Signed-off-by: Trial97 <alexandru.tripon97@gmail.com>
This commit is contained in:
parent
828acef7e9
commit
166207753c
@ -921,6 +921,10 @@ bool createShortcut(QString destination, QString target, QStringList args, QStri
|
|||||||
if (destination.isEmpty()) {
|
if (destination.isEmpty()) {
|
||||||
destination = PathCombine(getDesktopDir(), RemoveInvalidFilenameChars(name));
|
destination = PathCombine(getDesktopDir(), RemoveInvalidFilenameChars(name));
|
||||||
}
|
}
|
||||||
|
if (!ensureFilePathExists(destination)) {
|
||||||
|
qWarning() << "Destination path can't be created!";
|
||||||
|
return false;
|
||||||
|
}
|
||||||
#if defined(Q_OS_MACOS)
|
#if defined(Q_OS_MACOS)
|
||||||
// Create the Application
|
// Create the Application
|
||||||
QDir applicationDirectory =
|
QDir applicationDirectory =
|
||||||
|
Loading…
Reference in New Issue
Block a user