diff options
| author | hjk <hjk@qt.io> | 2020-01-28 18:48:32 +0100 |
|---|---|---|
| committer | hjk <hjk@qt.io> | 2020-01-29 06:30:48 +0000 |
| commit | 2c865a771c1b9f6f2b8d32fc127ee0b29fda66c4 (patch) | |
| tree | 5ee64746a0923fdd5c4b1941cccb6739d68aef44 /src/plugins/cpptools/cppcodestylepreferences.cpp | |
| parent | e0c76647cecb13d6afd054ec6e22cc9e66df43b2 (diff) | |
| download | qt-creator-2c865a771c1b9f6f2b8d32fc127ee0b29fda66c4.tar.gz | |
TextEditor: De-noise ICodeStylePreferences setup a bit
Change-Id: I6c3fcbb6ef17c7ca5771326b1444f057cc150e3d
Reviewed-by: David Schulz <david.schulz@qt.io>
Diffstat (limited to 'src/plugins/cpptools/cppcodestylepreferences.cpp')
| -rw-r--r-- | src/plugins/cpptools/cppcodestylepreferences.cpp | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/src/plugins/cpptools/cppcodestylepreferences.cpp b/src/plugins/cpptools/cppcodestylepreferences.cpp index ea7f100a59..461af42138 100644 --- a/src/plugins/cpptools/cppcodestylepreferences.cpp +++ b/src/plugins/cpptools/cppcodestylepreferences.cpp @@ -27,11 +27,11 @@ using namespace CppTools; -static const char settingsSuffixKey[] = "CodeStyleSettings"; - CppCodeStylePreferences::CppCodeStylePreferences(QObject *parent) : ICodeStylePreferences(parent) { + setSettingsSuffix("CodeStyleSettings"); + connect(this, &CppCodeStylePreferences::currentValueChanged, this, &CppCodeStylePreferences::slotCurrentValueChanged); } @@ -89,11 +89,6 @@ void CppCodeStylePreferences::slotCurrentValueChanged(const QVariant &value) emit currentCodeStyleSettingsChanged(value.value<CppCodeStyleSettings>()); } -QString CppCodeStylePreferences::settingsSuffix() const -{ - return QLatin1String(settingsSuffixKey); -} - void CppCodeStylePreferences::toMap(const QString &prefix, QVariantMap *map) const { ICodeStylePreferences::toMap(prefix, map); |
