3
0

SharedPreviewerFactory.h 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839
  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. #pragma once
  9. #include <AzCore/Memory/SystemAllocator.h>
  10. #include <AzToolsFramework/AssetBrowser/Previewer/PreviewerFactory.h>
  11. AZ_PUSH_DISABLE_WARNING(4251 4800, "-Wunknown-warning-option") // disable warnings spawned by QT
  12. #include <QString>
  13. AZ_POP_DISABLE_WARNING
  14. namespace AZ
  15. {
  16. namespace LyIntegration
  17. {
  18. class SharedPreviewerFactory final : public AzToolsFramework::AssetBrowser::PreviewerFactory
  19. {
  20. public:
  21. AZ_CLASS_ALLOCATOR(SharedPreviewerFactory, AZ::SystemAllocator);
  22. SharedPreviewerFactory() = default;
  23. ~SharedPreviewerFactory() = default;
  24. // AzToolsFramework::AssetBrowser::PreviewerFactory overrides...
  25. AzToolsFramework::AssetBrowser::Previewer* CreatePreviewer(QWidget* parent = nullptr) const override;
  26. bool IsEntrySupported(const AzToolsFramework::AssetBrowser::AssetBrowserEntry* entry) const override;
  27. const QString& GetName() const override;
  28. private:
  29. QString m_name = "SharedPreviewer";
  30. };
  31. } // namespace LyIntegration
  32. } // namespace AZ