forked from qt-creator/qt-creator
CMake: Set the build directory change after Browse
As an user I expect when I select Browse for the build directory
that after the directory has been chosen it will be taken into
consideration.
Amends 1d600101ee
Fixes: QTCREATORBUG-27407
Change-Id: I331b6095c176f57ca8e4c73c0b378a11ce3d6dbc
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
@@ -1088,13 +1088,15 @@ void StringAspect::addToLayout(LayoutBuilder &builder)
|
|||||||
useMacroExpander(d->m_pathChooserDisplay->lineEdit());
|
useMacroExpander(d->m_pathChooserDisplay->lineEdit());
|
||||||
if (isAutoApply()) {
|
if (isAutoApply()) {
|
||||||
if (d->m_autoApplyOnEditingFinished) {
|
if (d->m_autoApplyOnEditingFinished) {
|
||||||
connect(d->m_pathChooserDisplay, &PathChooser::editingFinished, this, [this] {
|
const auto setPathChooserValue = [this] {
|
||||||
if (d->m_blockAutoApply)
|
if (d->m_blockAutoApply)
|
||||||
return;
|
return;
|
||||||
d->m_blockAutoApply = true;
|
d->m_blockAutoApply = true;
|
||||||
setValue(d->m_pathChooserDisplay->filePath().toString());
|
setValue(d->m_pathChooserDisplay->filePath().toString());
|
||||||
d->m_blockAutoApply = false;
|
d->m_blockAutoApply = false;
|
||||||
});
|
};
|
||||||
|
connect(d->m_pathChooserDisplay, &PathChooser::editingFinished, this, setPathChooserValue);
|
||||||
|
connect(d->m_pathChooserDisplay, &PathChooser::browsingFinished, this, setPathChooserValue);
|
||||||
} else {
|
} else {
|
||||||
connect(d->m_pathChooserDisplay, &PathChooser::pathChanged,
|
connect(d->m_pathChooserDisplay, &PathChooser::pathChanged,
|
||||||
this, [this](const QString &path) {
|
this, [this](const QString &path) {
|
||||||
|
Reference in New Issue
Block a user