forked from qt-creator/qt-creator
CMake: Show build directory when asking if it should be used
When changing the build directory to a new or empty directory, we ask if the build directory should be changed and the project be configured there. Mention the new directory in the dialog. Change-Id: Ie4d7e9b132e6e90004e4d498b2182562375e7441 Reviewed-by: Cristian Adam <cristian.adam@qt.io>
This commit is contained in:
@@ -852,10 +852,12 @@ CMakeBuildConfiguration::CMakeBuildConfiguration(Target *target, Id id)
|
|||||||
return newDir;
|
return newDir;
|
||||||
|
|
||||||
if (QDir(oldDir).exists("CMakeCache.txt") && !QDir(newDir).exists("CMakeCache.txt")) {
|
if (QDir(oldDir).exists("CMakeCache.txt") && !QDir(newDir).exists("CMakeCache.txt")) {
|
||||||
if (QMessageBox::information(Core::ICore::dialogParent(),
|
if (QMessageBox::information(
|
||||||
|
Core::ICore::dialogParent(),
|
||||||
tr("Changing Build Directory"),
|
tr("Changing Build Directory"),
|
||||||
tr("Change the build directory and start with a "
|
tr("Change the build directory to \"%1\" and start with a "
|
||||||
"basic CMake configuration?"),
|
"basic CMake configuration?")
|
||||||
|
.arg(newDir),
|
||||||
QMessageBox::Ok,
|
QMessageBox::Ok,
|
||||||
QMessageBox::Cancel)
|
QMessageBox::Cancel)
|
||||||
== QMessageBox::Ok) {
|
== QMessageBox::Ok) {
|
||||||
|
|||||||
Reference in New Issue
Block a user