diff options
author | Eike Ziller <eike.ziller@qt.io> | 2020-06-15 11:30:34 +0200 |
---|---|---|
committer | Eike Ziller <eike.ziller@qt.io> | 2020-06-15 11:30:34 +0200 |
commit | 8b8ecfa28f85236e67417934bc6e9820e9011842 (patch) | |
tree | 952c6a0021f913509fdc8d114e0c75b29d6dd8e5 /src/plugins/android/androidsettingswidget.cpp | |
parent | 630f43c02db32f04c820a8209a346f0bea8ee274 (diff) | |
parent | 759b38e2ac293a9b5d588c36949e4e7dacd31046 (diff) |
Merge remote-tracking branch 'origin/4.12'
Conflicts:
src/plugins/cmakeprojectmanager/fileapiparser.cpp
Change-Id: I39f8c2be859be043f506bef77de9bb5b42d38165
Diffstat (limited to 'src/plugins/android/androidsettingswidget.cpp')
-rw-r--r-- | src/plugins/android/androidsettingswidget.cpp | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/src/plugins/android/androidsettingswidget.cpp b/src/plugins/android/androidsettingswidget.cpp index 52cfbd44612..c86ced4cba7 100644 --- a/src/plugins/android/androidsettingswidget.cpp +++ b/src/plugins/android/androidsettingswidget.cpp @@ -788,16 +788,16 @@ void AndroidSettingsWidget::downloadOpenSslRepo(const bool silent) qCDebug(androidsettingswidget) << "Cloning OpenSSL repo: " << gitCloneCommand.toUserOutput(); QDir openSslDir(openSslPath.toString()); - if (openSslDir.exists()) { - auto userInput = QMessageBox::information(this, openSslCloneTitle, - tr("The selected download path (%1) for OpenSSL already exists. " - "Remove and overwrite its content?") - .arg(QDir::toNativeSeparators(openSslPath.toString())), - QMessageBox::Yes | QMessageBox::No); - if (userInput == QMessageBox::Yes) - openSslDir.removeRecursively(); - else - return; + const bool isEmptyDir = openSslDir.isEmpty(QDir::AllEntries | QDir::NoDotAndDotDot + | QDir::Hidden | QDir::System); + if (openSslDir.exists() && !isEmptyDir) { + QMessageBox::information( + this, + openSslCloneTitle, + tr("The selected download path (%1) for OpenSSL already exists and the directory is " + "not empty. Select a different path or make sure it is an empty directory.") + .arg(QDir::toNativeSeparators(openSslPath.toString()))); + return; } QProgressDialog *openSslProgressDialog |