diff options
author | hjk <hjk@qt.io> | 2022-09-02 11:49:36 +0200 |
---|---|---|
committer | Christian Stenger <christian.stenger@qt.io> | 2022-09-06 05:01:51 +0000 |
commit | 1567d2498034a492fa72b1fd660b41f46d165408 (patch) | |
tree | 9c92aac6ca21d424cd928ae5240136cc45e02f16 /src/plugins/projectexplorer | |
parent | b0defb65c2e8fdad3888379a411999dc2f23e73e (diff) | |
download | qt-creator-1567d2498034a492fa72b1fd660b41f46d165408.tar.gz |
Utils: Replace PathChooser::{fileP,p}athChanged signals
... by a new PathChooser::textChanged signal.
They were both emitted in reaction to the underlying line edit's
textChanged() signal.
Use 'textChanged()' as name to mimic/match the Qt side. This also
makes it more clear on the user code side, when this happens.
Some textChanged() consumers should probably use editingFinished()
instead, but that's left for later changes.
Change-Id: Ib07347f616cbf1c5d09bc2f8671ca860d185d1f9
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Diffstat (limited to 'src/plugins/projectexplorer')
4 files changed, 4 insertions, 4 deletions
diff --git a/src/plugins/projectexplorer/devicesupport/sshsettingspage.cpp b/src/plugins/projectexplorer/devicesupport/sshsettingspage.cpp index a6b30eddc7..0b6e100141 100644 --- a/src/plugins/projectexplorer/devicesupport/sshsettingspage.cpp +++ b/src/plugins/projectexplorer/devicesupport/sshsettingspage.cpp @@ -135,7 +135,7 @@ void SshSettingsWidget::setupPathChooser(PathChooser &chooser, const FilePath &i { chooser.setExpectedKind(PathChooser::ExistingCommand); chooser.setFilePath(initialPath); - connect(&chooser, &PathChooser::filePathChanged, [&changedFlag] { changedFlag = true; }); + connect(&chooser, &PathChooser::textChanged, [&changedFlag] { changedFlag = true; }); } void SshSettingsWidget::updateCheckboxEnabled() diff --git a/src/plugins/projectexplorer/jsonwizard/jsonfieldpage.cpp b/src/plugins/projectexplorer/jsonwizard/jsonfieldpage.cpp index 29da1acf35..67b8da4ce5 100644 --- a/src/plugins/projectexplorer/jsonwizard/jsonfieldpage.cpp +++ b/src/plugins/projectexplorer/jsonwizard/jsonfieldpage.cpp @@ -834,7 +834,7 @@ QWidget *PathChooserField::createWidget(const QString &displayName, JsonFieldPag auto w = new PathChooser; if (!m_historyId.isEmpty()) w->setHistoryCompleter(m_historyId); - QObject::connect(w, &PathChooser::filePathChanged, [this, w] { + QObject::connect(w, &PathChooser::textChanged, [this, w] { if (w->filePath() != m_path) setHasUserChanges(); }); diff --git a/src/plugins/projectexplorer/kitinformation.cpp b/src/plugins/projectexplorer/kitinformation.cpp index 66e13bb4f5..b5b9f47bc8 100644 --- a/src/plugins/projectexplorer/kitinformation.cpp +++ b/src/plugins/projectexplorer/kitinformation.cpp @@ -58,7 +58,7 @@ public: m_chooser->setExpectedKind(PathChooser::ExistingDirectory); m_chooser->setHistoryCompleter(QLatin1String("PE.SysRoot.History")); m_chooser->setFilePath(SysRootKitAspect::sysRoot(k)); - connect(m_chooser, &PathChooser::filePathChanged, + connect(m_chooser, &PathChooser::textChanged, this, &SysRootKitAspectWidget::pathWasChanged); } diff --git a/src/plugins/projectexplorer/runconfigurationaspects.cpp b/src/plugins/projectexplorer/runconfigurationaspects.cpp index 16bd230664..ea701ae498 100644 --- a/src/plugins/projectexplorer/runconfigurationaspects.cpp +++ b/src/plugins/projectexplorer/runconfigurationaspects.cpp @@ -172,7 +172,7 @@ void WorkingDirectoryAspect::addToLayout(LayoutBuilder &builder) m_chooser->setPromptDialogTitle(tr("Select Working Directory")); m_chooser->setBaseDirectory(m_defaultWorkingDirectory); m_chooser->setFilePath(m_workingDirectory.isEmpty() ? m_defaultWorkingDirectory : m_workingDirectory); - connect(m_chooser.data(), &PathChooser::filePathChanged, this, [this] { + connect(m_chooser.data(), &PathChooser::textChanged, this, [this] { m_workingDirectory = m_chooser->rawFilePath(); m_resetButton->setEnabled(m_workingDirectory != m_defaultWorkingDirectory); }); |