forked from qt-creator/qt-creator
Debugger: Move dialogs settings out of the global settings namespace.
Add legacy to retrieve old values.
This commit is contained in:
@@ -932,10 +932,8 @@ public slots:
|
||||
{ return qobject_cast<DebuggerMainWindow*>
|
||||
(DebuggerUISwitcher::instance()->mainWindow()); }
|
||||
|
||||
void setConfigValue(const QString &name, const QVariant &value)
|
||||
{ settings()->setValue(name, value); }
|
||||
QVariant configValue(const QString &name) const
|
||||
{ return settings()->value(name); }
|
||||
inline void setConfigValue(const QString &name, const QVariant &value);
|
||||
inline QVariant configValue(const QString &name) const;
|
||||
|
||||
DebuggerRunControl *createDebugger(const DebuggerStartParameters &sp,
|
||||
RunConfiguration *rc = 0);
|
||||
@@ -1676,6 +1674,20 @@ bool DebuggerPluginPrivate::initialize(const QStringList &arguments, QString *er
|
||||
return true;
|
||||
}
|
||||
|
||||
void DebuggerPluginPrivate::setConfigValue(const QString &name, const QVariant &value)
|
||||
{
|
||||
settings()->setValue(_("DebugMode/") + name, value);
|
||||
}
|
||||
|
||||
QVariant DebuggerPluginPrivate::configValue(const QString &name) const
|
||||
{
|
||||
const QVariant value = settings()->value(_("DebugMode/") + name);
|
||||
if (value.isValid())
|
||||
return value;
|
||||
// Legacy (pre-2.1): Check old un-namespaced-settings.
|
||||
return settings()->value(name);
|
||||
}
|
||||
|
||||
void DebuggerPluginPrivate::onCurrentProjectChanged(Project *project)
|
||||
{
|
||||
RunConfiguration *activeRc = 0;
|
||||
|
||||
Reference in New Issue
Block a user