Tasks: Create a container class for category data

Reduce the number of arguments that need to be passed around.

Change-Id: I9fbfdcdf7b20f8f26e35f435bf8d65ba483e4114
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
Eike Ziller
2023-07-11 12:08:22 +02:00
parent 918978ce89
commit cd1b6a669b
15 changed files with 56 additions and 47 deletions

View File

@@ -723,7 +723,7 @@ DebuggerPluginPrivate::DebuggerPluginPrivate(const QStringList &arguments)
// Task integration.
//: Category under which Analyzer tasks are listed in Issues view
TaskHub::addCategory(ANALYZERTASK_ID, Tr::tr("Debugger"));
TaskHub::addCategory({ANALYZERTASK_ID, Tr::tr("Debugger")});
const Context debuggerNotRunning(C_DEBUGGER_NOTRUNNING);
ICore::addAdditionalContext(debuggerNotRunning);
@@ -765,8 +765,8 @@ DebuggerPluginPrivate::DebuggerPluginPrivate(const QStringList &arguments)
act->setEnabled(false);
Command *cmd = ActionManager::registerAction(act, Constants::OPEN_MEMORY_EDITOR);
TaskHub::addCategory(TASK_CATEGORY_DEBUGGER_DEBUGINFO, Tr::tr("Debug Information"));
TaskHub::addCategory(TASK_CATEGORY_DEBUGGER_RUNTIME, Tr::tr("Debugger Runtime"));
TaskHub::addCategory({TASK_CATEGORY_DEBUGGER_DEBUGINFO, Tr::tr("Debug Information")});
TaskHub::addCategory({TASK_CATEGORY_DEBUGGER_RUNTIME, Tr::tr("Debugger Runtime")});
m_debuggerSettings.readSettings();