From e8f1329a4d4b3231cdcce74ffab832b6537597c0 Mon Sep 17 00:00:00 2001 From: Nav Date: Wed, 15 Mar 2023 20:15:05 +0000 Subject: [PATCH] Tidying --- src/Insight/InsightWorker/InsightWorker.cpp | 6 +++--- src/Insight/InsightWorker/Tasks/CaptureMemorySnapshot.hpp | 2 +- .../Tasks/ConstructHexViewerTopLevelGroupItem.hpp | 2 +- src/Insight/InsightWorker/Tasks/GetTargetDescriptor.hpp | 2 +- src/Insight/InsightWorker/Tasks/GetTargetState.hpp | 2 +- src/Insight/InsightWorker/Tasks/InsightWorkerTask.hpp | 2 +- src/Insight/InsightWorker/Tasks/ReadProgramCounter.hpp | 2 +- src/Insight/InsightWorker/Tasks/ReadStackPointer.hpp | 2 +- src/Insight/InsightWorker/Tasks/ReadTargetMemory.hpp | 2 +- src/Insight/InsightWorker/Tasks/ReadTargetRegisters.hpp | 2 +- src/Insight/InsightWorker/Tasks/RefreshTargetPinStates.hpp | 2 +- src/Insight/InsightWorker/Tasks/SetTargetPinState.hpp | 2 +- src/Insight/InsightWorker/Tasks/WriteTargetRegister.hpp | 2 +- 13 files changed, 15 insertions(+), 15 deletions(-) diff --git a/src/Insight/InsightWorker/InsightWorker.cpp b/src/Insight/InsightWorker/InsightWorker.cpp index d84b3249..55b4593e 100644 --- a/src/Insight/InsightWorker/InsightWorker.cpp +++ b/src/Insight/InsightWorker/InsightWorker.cpp @@ -54,7 +54,7 @@ namespace Bloom auto& taskGroupsInExecution = InsightWorker::taskGroupsInExecution.getValue(); const auto canExecuteTask = [&taskGroupsInExecution] (const QSharedPointer& task) { - for (const auto taskGroup : task->getTaskGroups()) { + for (const auto taskGroup : task->taskGroups()) { if (taskGroupsInExecution.contains(taskGroup)) { return false; } @@ -65,7 +65,7 @@ namespace Bloom for (auto [queuedTaskId, task] : queuedTasks) { if (canExecuteTask(task)) { - const auto taskGroups = task->getTaskGroups(); + const auto taskGroups = task->taskGroups(); taskGroupsInExecution.insert(taskGroups.begin(), taskGroups.end()); queuedTasks.erase(queuedTaskId); return task; @@ -87,7 +87,7 @@ namespace Bloom const auto taskGroupsLock = InsightWorker::taskGroupsInExecution.acquireLock(); auto& taskGroupsInExecution = InsightWorker::taskGroupsInExecution.getValue(); - for (const auto& taskGroup : task->getTaskGroups()) { + for (const auto& taskGroup : task->taskGroups()) { taskGroupsInExecution.erase(taskGroup); } } diff --git a/src/Insight/InsightWorker/Tasks/CaptureMemorySnapshot.hpp b/src/Insight/InsightWorker/Tasks/CaptureMemorySnapshot.hpp index 99cc4c2a..e6ba0a50 100644 --- a/src/Insight/InsightWorker/Tasks/CaptureMemorySnapshot.hpp +++ b/src/Insight/InsightWorker/Tasks/CaptureMemorySnapshot.hpp @@ -24,7 +24,7 @@ namespace Bloom const std::optional& data ); - TaskGroups getTaskGroups() const override { + TaskGroups taskGroups() const override { return TaskGroups({ TaskGroup::USES_TARGET_CONTROLLER, }); diff --git a/src/Insight/InsightWorker/Tasks/ConstructHexViewerTopLevelGroupItem.hpp b/src/Insight/InsightWorker/Tasks/ConstructHexViewerTopLevelGroupItem.hpp index 26a3c6f6..93284ce5 100644 --- a/src/Insight/InsightWorker/Tasks/ConstructHexViewerTopLevelGroupItem.hpp +++ b/src/Insight/InsightWorker/Tasks/ConstructHexViewerTopLevelGroupItem.hpp @@ -20,7 +20,7 @@ namespace Bloom const Widgets::HexViewerSharedState& hexViewerState ); - TaskGroups getTaskGroups() const override { + TaskGroups taskGroups() const override { return TaskGroups(); }; diff --git a/src/Insight/InsightWorker/Tasks/GetTargetDescriptor.hpp b/src/Insight/InsightWorker/Tasks/GetTargetDescriptor.hpp index ee420ff9..502b014d 100644 --- a/src/Insight/InsightWorker/Tasks/GetTargetDescriptor.hpp +++ b/src/Insight/InsightWorker/Tasks/GetTargetDescriptor.hpp @@ -13,7 +13,7 @@ namespace Bloom public: GetTargetDescriptor() = default; - TaskGroups getTaskGroups() const override { + TaskGroups taskGroups() const override { return TaskGroups({ TaskGroup::USES_TARGET_CONTROLLER, }); diff --git a/src/Insight/InsightWorker/Tasks/GetTargetState.hpp b/src/Insight/InsightWorker/Tasks/GetTargetState.hpp index 814bd4b6..ebae16f5 100644 --- a/src/Insight/InsightWorker/Tasks/GetTargetState.hpp +++ b/src/Insight/InsightWorker/Tasks/GetTargetState.hpp @@ -13,7 +13,7 @@ namespace Bloom public: GetTargetState() = default; - TaskGroups getTaskGroups() const override { + TaskGroups taskGroups() const override { return TaskGroups({ TaskGroup::USES_TARGET_CONTROLLER, }); diff --git a/src/Insight/InsightWorker/Tasks/InsightWorkerTask.hpp b/src/Insight/InsightWorker/Tasks/InsightWorkerTask.hpp index 9063f6ed..f1982027 100644 --- a/src/Insight/InsightWorker/Tasks/InsightWorkerTask.hpp +++ b/src/Insight/InsightWorker/Tasks/InsightWorkerTask.hpp @@ -29,7 +29,7 @@ namespace Bloom InsightWorkerTask(); - virtual TaskGroups getTaskGroups() const { + virtual TaskGroups taskGroups() const { return TaskGroups(); }; diff --git a/src/Insight/InsightWorker/Tasks/ReadProgramCounter.hpp b/src/Insight/InsightWorker/Tasks/ReadProgramCounter.hpp index 4e9e60fe..4a590deb 100644 --- a/src/Insight/InsightWorker/Tasks/ReadProgramCounter.hpp +++ b/src/Insight/InsightWorker/Tasks/ReadProgramCounter.hpp @@ -13,7 +13,7 @@ namespace Bloom public: ReadProgramCounter() = default; - TaskGroups getTaskGroups() const override { + TaskGroups taskGroups() const override { return TaskGroups({ TaskGroup::USES_TARGET_CONTROLLER, }); diff --git a/src/Insight/InsightWorker/Tasks/ReadStackPointer.hpp b/src/Insight/InsightWorker/Tasks/ReadStackPointer.hpp index c1d3f5a9..612356fb 100644 --- a/src/Insight/InsightWorker/Tasks/ReadStackPointer.hpp +++ b/src/Insight/InsightWorker/Tasks/ReadStackPointer.hpp @@ -13,7 +13,7 @@ namespace Bloom public: ReadStackPointer() = default; - TaskGroups getTaskGroups() const override { + TaskGroups taskGroups() const override { return TaskGroups({ TaskGroup::USES_TARGET_CONTROLLER, }); diff --git a/src/Insight/InsightWorker/Tasks/ReadTargetMemory.hpp b/src/Insight/InsightWorker/Tasks/ReadTargetMemory.hpp index fce32881..bd1b48c1 100644 --- a/src/Insight/InsightWorker/Tasks/ReadTargetMemory.hpp +++ b/src/Insight/InsightWorker/Tasks/ReadTargetMemory.hpp @@ -25,7 +25,7 @@ namespace Bloom , excludedAddressRanges(excludedAddressRanges) {} - TaskGroups getTaskGroups() const override { + TaskGroups taskGroups() const override { return TaskGroups({ TaskGroup::USES_TARGET_CONTROLLER, }); diff --git a/src/Insight/InsightWorker/Tasks/ReadTargetRegisters.hpp b/src/Insight/InsightWorker/Tasks/ReadTargetRegisters.hpp index 93c27d7b..c5f58d70 100644 --- a/src/Insight/InsightWorker/Tasks/ReadTargetRegisters.hpp +++ b/src/Insight/InsightWorker/Tasks/ReadTargetRegisters.hpp @@ -14,7 +14,7 @@ namespace Bloom : descriptors(descriptors) {} - TaskGroups getTaskGroups() const override { + TaskGroups taskGroups() const override { return TaskGroups({ TaskGroup::USES_TARGET_CONTROLLER, }); diff --git a/src/Insight/InsightWorker/Tasks/RefreshTargetPinStates.hpp b/src/Insight/InsightWorker/Tasks/RefreshTargetPinStates.hpp index 2f899e86..2ec822cb 100644 --- a/src/Insight/InsightWorker/Tasks/RefreshTargetPinStates.hpp +++ b/src/Insight/InsightWorker/Tasks/RefreshTargetPinStates.hpp @@ -15,7 +15,7 @@ namespace Bloom : variantId(variantId) {} - TaskGroups getTaskGroups() const override { + TaskGroups taskGroups() const override { return TaskGroups({ TaskGroup::USES_TARGET_CONTROLLER, }); diff --git a/src/Insight/InsightWorker/Tasks/SetTargetPinState.hpp b/src/Insight/InsightWorker/Tasks/SetTargetPinState.hpp index dbf44e13..d66f4baf 100644 --- a/src/Insight/InsightWorker/Tasks/SetTargetPinState.hpp +++ b/src/Insight/InsightWorker/Tasks/SetTargetPinState.hpp @@ -15,7 +15,7 @@ namespace Bloom , pinState(pinState) {} - TaskGroups getTaskGroups() const override { + TaskGroups taskGroups() const override { return TaskGroups({ TaskGroup::USES_TARGET_CONTROLLER, }); diff --git a/src/Insight/InsightWorker/Tasks/WriteTargetRegister.hpp b/src/Insight/InsightWorker/Tasks/WriteTargetRegister.hpp index 082c3927..556c6086 100644 --- a/src/Insight/InsightWorker/Tasks/WriteTargetRegister.hpp +++ b/src/Insight/InsightWorker/Tasks/WriteTargetRegister.hpp @@ -14,7 +14,7 @@ namespace Bloom : targetRegister(targetRegister) {} - TaskGroups getTaskGroups() const override { + TaskGroups taskGroups() const override { return TaskGroups({ TaskGroup::USES_TARGET_CONTROLLER, });