diff options
author | Clinton Stimpson <clinton@elemtech.com> | 2008-04-07 23:19:50 (GMT) |
---|---|---|
committer | Clinton Stimpson <clinton@elemtech.com> | 2008-04-07 23:19:50 (GMT) |
commit | 7d2bbfe84244031c25a9c71483f71fa95b1f29e8 (patch) | |
tree | 9dfd36735ae15fc70628ce1c28a976284db2ba54 /Source/QtDialog/CMakeSetupDialog.cxx | |
parent | 1829bed8b5dd4c1d3b622a14160d3a6706bcc16e (diff) | |
download | CMake-7d2bbfe84244031c25a9c71483f71fa95b1f29e8.zip CMake-7d2bbfe84244031c25a9c71483f71fa95b1f29e8.tar.gz CMake-7d2bbfe84244031c25a9c71483f71fa95b1f29e8.tar.bz2 |
BUG: Fix #6733. Always convert "\" to "/" in source & binary directory fields on Windows.
Diffstat (limited to 'Source/QtDialog/CMakeSetupDialog.cxx')
-rw-r--r-- | Source/QtDialog/CMakeSetupDialog.cxx | 19 |
1 files changed, 16 insertions, 3 deletions
diff --git a/Source/QtDialog/CMakeSetupDialog.cxx b/Source/QtDialog/CMakeSetupDialog.cxx index 7254abd..1c5e25d 100644 --- a/Source/QtDialog/CMakeSetupDialog.cxx +++ b/Source/QtDialog/CMakeSetupDialog.cxx @@ -181,7 +181,10 @@ void CMakeSetupDialog::initialize() QObject::connect(this->CMakeThread->cmakeInstance(), SIGNAL(sourceDirChanged(QString)), this, SLOT(updateSourceDirectory(QString))); - + QObject::connect(this->CMakeThread->cmakeInstance(), + SIGNAL(binaryDirChanged(QString)), + this, SLOT(updateBinaryDirectory(QString))); + QObject::connect(this->CMakeThread->cmakeInstance(), SIGNAL(progressChanged(QString, float)), this, SLOT(showProgress(QString,float))); @@ -445,7 +448,7 @@ void CMakeSetupDialog::doSourceBrowse() tr("Enter Path to Source"), this->SourceDirectory->text()); if(!dir.isEmpty()) { - this->setSourceDirectory(QDir::fromNativeSeparators(dir)); + this->setSourceDirectory(dir); } } @@ -459,13 +462,23 @@ void CMakeSetupDialog::updateSourceDirectory(const QString& dir) } } +void CMakeSetupDialog::updateBinaryDirectory(const QString& dir) +{ + if(this->BinaryDirectory->currentText() != dir) + { + this->BinaryDirectory->blockSignals(true); + this->BinaryDirectory->setEditText(dir); + this->BinaryDirectory->blockSignals(false); + } +} + void CMakeSetupDialog::doBinaryBrowse() { QString dir = QFileDialog::getExistingDirectory(this, tr("Enter Path to Build"), this->BinaryDirectory->currentText()); if(!dir.isEmpty() && dir != this->BinaryDirectory->currentText()) { - this->setBinaryDirectory(QDir::fromNativeSeparators(dir)); + this->setBinaryDirectory(dir); } } |