Repository navigation
Expand file tree
/
Copy pathROS2ScriptIntegrationEditorSystemComponent.cpp
More file actions
66 lines (52 loc) · 2.53 KB
/
Copy pathROS2ScriptIntegrationEditorSystemComponent.cpp
File metadata and controls
66 lines (52 loc) · 2.53 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
#include "ROS2ScriptIntegrationEditorSystemComponent.h"
#include <AzCore/Serialization/SerializeContext.h>
#include <ROS2ScriptIntegration/ROS2ScriptIntegrationTypeIds.h>
namespace ROS2ScriptIntegration
{
AZ_COMPONENT_IMPL(
ROS2ScriptIntegrationEditorSystemComponent,
"ROS2ScriptIntegrationEditorSystemComponent",
ROS2ScriptIntegrationEditorSystemComponentTypeId,
BaseSystemComponent);
void ROS2ScriptIntegrationEditorSystemComponent::Reflect(AZ::ReflectContext* context)
{
if (auto serializeContext = azrtti_cast<AZ::SerializeContext*>(context))
{
serializeContext->Class<ROS2ScriptIntegrationEditorSystemComponent, ROS2ScriptIntegrationSystemComponent>()->Version(0);
}
}
ROS2ScriptIntegrationEditorSystemComponent::ROS2ScriptIntegrationEditorSystemComponent() = default;
ROS2ScriptIntegrationEditorSystemComponent::~ROS2ScriptIntegrationEditorSystemComponent() = default;
void ROS2ScriptIntegrationEditorSystemComponent::GetProvidedServices(AZ::ComponentDescriptor::DependencyArrayType& provided)
{
BaseSystemComponent::GetProvidedServices(provided);
provided.push_back(AZ_CRC_CE("ROS2ScriptIntegrationEditorService"));
}
void ROS2ScriptIntegrationEditorSystemComponent::GetIncompatibleServices(AZ::ComponentDescriptor::DependencyArrayType& incompatible)
{
BaseSystemComponent::GetIncompatibleServices(incompatible);
incompatible.push_back(AZ_CRC_CE("ROS2ScriptIntegrationEditorService"));
}
void ROS2ScriptIntegrationEditorSystemComponent::GetRequiredServices(
[[maybe_unused]] AZ::ComponentDescriptor::DependencyArrayType& required)
{
BaseSystemComponent::GetRequiredServices(required);
required.push_back(AZ_CRC_CE("PublisherEditorService"));
required.push_back(AZ_CRC_CE("SubscriberEditorService"));
}
void ROS2ScriptIntegrationEditorSystemComponent::GetDependentServices(
[[maybe_unused]] AZ::ComponentDescriptor::DependencyArrayType& dependent)
{
BaseSystemComponent::GetDependentServices(dependent);
}
void ROS2ScriptIntegrationEditorSystemComponent::Activate()
{
ROS2ScriptIntegrationSystemComponent::Activate();
AzToolsFramework::EditorEvents::Bus::Handler::BusConnect();
}
void ROS2ScriptIntegrationEditorSystemComponent::Deactivate()
{
AzToolsFramework::EditorEvents::Bus::Handler::BusDisconnect();
ROS2ScriptIntegrationSystemComponent::Deactivate();
}
} // namespace ROS2ScriptIntegration