mirror of
https://github.com/johndoe6345789/SDL3CPlusPlus.git
synced 2026-04-24 13:44:58 +00:00
ROADMAP.md
This commit is contained in:
26
src/services/impl/workflow_frame_audio_step.cpp
Normal file
26
src/services/impl/workflow_frame_audio_step.cpp
Normal file
@@ -0,0 +1,26 @@
|
||||
#include "workflow_frame_audio_step.hpp"
|
||||
|
||||
#include <stdexcept>
|
||||
|
||||
namespace sdl3cpp::services::impl {
|
||||
|
||||
WorkflowFrameAudioStep::WorkflowFrameAudioStep(std::shared_ptr<IAudioService> audioService,
|
||||
std::shared_ptr<ILogger> logger)
|
||||
: audioService_(std::move(audioService)),
|
||||
logger_(std::move(logger)) {}
|
||||
|
||||
std::string WorkflowFrameAudioStep::GetPluginId() const {
|
||||
return "frame.audio";
|
||||
}
|
||||
|
||||
void WorkflowFrameAudioStep::Execute(const WorkflowStepDefinition&, WorkflowContext&) {
|
||||
if (!audioService_) {
|
||||
throw std::runtime_error("frame.audio requires an IAudioService");
|
||||
}
|
||||
audioService_->Update();
|
||||
if (logger_) {
|
||||
logger_->Trace("WorkflowFrameAudioStep", "Execute", "", "Audio updated");
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace sdl3cpp::services::impl
|
||||
24
src/services/impl/workflow_frame_gui_step.hpp
Normal file
24
src/services/impl/workflow_frame_gui_step.hpp
Normal file
@@ -0,0 +1,24 @@
|
||||
#pragma once
|
||||
|
||||
#include "../interfaces/i_workflow_step.hpp"
|
||||
#include "../interfaces/i_logger.hpp"
|
||||
#include "../interfaces/i_input_service.hpp"
|
||||
|
||||
#include <memory>
|
||||
|
||||
namespace sdl3cpp::services::impl {
|
||||
|
||||
class WorkflowFrameGuiStep final : public IWorkflowStep {
|
||||
public:
|
||||
WorkflowFrameGuiStep(std::shared_ptr<IInputService> inputService,
|
||||
std::shared_ptr<ILogger> logger);
|
||||
|
||||
std::string GetPluginId() const override;
|
||||
void Execute(const WorkflowStepDefinition& step, WorkflowContext& context) override;
|
||||
|
||||
private:
|
||||
std::shared_ptr<IInputService> inputService_;
|
||||
std::shared_ptr<ILogger> logger_;
|
||||
};
|
||||
|
||||
} // namespace sdl3cpp::services::impl
|
||||
Reference in New Issue
Block a user