EditorSystemComponent.cpp 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. /*
  2. * Copyright (c) Contributors to the Open 3D Engine Project.
  3. * For complete copyright and license terms please see the LICENSE at the root of this distribution.
  4. *
  5. * SPDX-License-Identifier: Apache-2.0 OR MIT
  6. *
  7. */
  8. #include <Editor/EditorSystemComponent.h>
  9. #include <AzToolsFramework/API/ToolsApplicationAPI.h>
  10. #include <Editor/PropertyTypes.h>
  11. namespace NvCloth
  12. {
  13. void EditorSystemComponent::Reflect(AZ::ReflectContext* context)
  14. {
  15. if (auto serializeContext = azrtti_cast<AZ::SerializeContext*>(context))
  16. {
  17. serializeContext->Class<EditorSystemComponent, AZ::Component>()
  18. ->Version(0);
  19. }
  20. }
  21. void EditorSystemComponent::GetProvidedServices(AZ::ComponentDescriptor::DependencyArrayType& provided)
  22. {
  23. provided.push_back(AZ_CRC_CE("NvClothEditorService"));
  24. }
  25. void EditorSystemComponent::GetIncompatibleServices(AZ::ComponentDescriptor::DependencyArrayType& incompatible)
  26. {
  27. incompatible.push_back(AZ_CRC_CE("NvClothEditorService"));
  28. }
  29. void EditorSystemComponent::GetRequiredServices(AZ::ComponentDescriptor::DependencyArrayType& required)
  30. {
  31. required.push_back(AZ_CRC_CE("NvClothService"));
  32. }
  33. void EditorSystemComponent::Activate()
  34. {
  35. m_propertyHandlers = Editor::RegisterPropertyTypes();
  36. }
  37. void EditorSystemComponent::Deactivate()
  38. {
  39. Editor::UnregisterPropertyTypes(m_propertyHandlers);
  40. }
  41. } // namespace NvCloth