aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/debugger/debuggerplugin.cpp
diff options
context:
space:
mode:
authorhjk <hjk@qt.io>2020-01-08 15:54:20 +0100
committerhjk <hjk@qt.io>2020-01-09 12:45:48 +0000
commit5496d7cbde820506f9d89f1a16d3b60adb399bd4 (patch)
tree42e58c7dbbf160b84c0b86c6a0cf373378d9afd1 /src/plugins/debugger/debuggerplugin.cpp
parent25323be13d64cff7f37f51b2c8788412851661fc (diff)
Debugger: Use new IOptionPage convenience for global options
Change-Id: I42391a01027f25be638b2d1b839d3038bced5f33 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Diffstat (limited to 'src/plugins/debugger/debuggerplugin.cpp')
-rw-r--r--src/plugins/debugger/debuggerplugin.cpp13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/plugins/debugger/debuggerplugin.cpp b/src/plugins/debugger/debuggerplugin.cpp
index 6de9fb1134..882e5ecdbb 100644
--- a/src/plugins/debugger/debuggerplugin.cpp
+++ b/src/plugins/debugger/debuggerplugin.cpp
@@ -759,9 +759,10 @@ public:
Console m_console; // ensure Debugger Console is created before settings are taken into account
DebuggerSettings m_debuggerSettings;
QStringList m_arguments;
- const QSharedPointer<GlobalDebuggerOptions> m_globalDebuggerOptions;
+ GlobalDebuggerOptions m_globalDebuggerOptions;
DebuggerItemManager m_debuggerItemManager;
+
QList<IOptionsPage *> m_optionPages;
IContext m_debugModeContext;
@@ -769,6 +770,7 @@ public:
Perspective m_perspective{Constants::PRESET_PERSPECTIVE_ID, tr("Debugger")};
DebuggerKitAspect debuggerKitAspect;
+ CommonOptionsPage commonOptionsPage;
RunWorkerFactory debuggerWorkerFactory{
RunWorkerFactory::make<DebuggerRunTool>(),
@@ -784,7 +786,6 @@ public:
};
DebuggerPluginPrivate::DebuggerPluginPrivate(const QStringList &arguments)
- : m_globalDebuggerOptions(new GlobalDebuggerOptions)
{
qRegisterMetaType<ContextData>("ContextData");
qRegisterMetaType<DebuggerRunParameters>("DebuggerRunParameters");
@@ -1253,9 +1254,7 @@ DebuggerPluginPrivate::DebuggerPluginPrivate(const QStringList &arguments)
connect(EngineManager::instance(), &EngineManager::currentEngineChanged,
this, &DebuggerPluginPrivate::updatePresetState);
- m_optionPages.append(new CommonOptionsPage(m_globalDebuggerOptions));
-
- m_globalDebuggerOptions->fromSettings();
+ m_globalDebuggerOptions.fromSettings();
}
@@ -2136,9 +2135,9 @@ void openTextEditor(const QString &titlePattern0, const QString &contents)
QTC_ASSERT(editor, return);
}
-QSharedPointer<Internal::GlobalDebuggerOptions> globalDebuggerOptions()
+Internal::GlobalDebuggerOptions *globalDebuggerOptions()
{
- return dd->m_globalDebuggerOptions;
+ return &dd->m_globalDebuggerOptions;
}
///////////////////////////////////////////////////////////////////////