ScreenDefs.h 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  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/std/containers/unordered_map.h>
  10. #include <AzCore/std/string/string.h>
  11. #include <QHash>
  12. namespace O3DE::ProjectManager
  13. {
  14. enum class ProjectManagerScreen
  15. {
  16. Invalid = -1,
  17. Empty,
  18. CreateProject,
  19. NewProjectSettings,
  20. GemCatalog,
  21. ProjectGemCatalog,
  22. Projects,
  23. UpdateProject,
  24. UpdateProjectSettings,
  25. Engine,
  26. EngineSettings,
  27. GemRepos,
  28. GemsGemRepos,
  29. CreateGem,
  30. EditGem
  31. };
  32. static QHash<QString, ProjectManagerScreen> s_ProjectManagerStringNames = {
  33. { "Empty", ProjectManagerScreen::Empty},
  34. { "CreateProject", ProjectManagerScreen::CreateProject},
  35. { "NewProjectSettings", ProjectManagerScreen::NewProjectSettings},
  36. { "GemCatalog", ProjectManagerScreen::GemCatalog},
  37. { "ProjectGemCatalog", ProjectManagerScreen::ProjectGemCatalog},
  38. { "Projects", ProjectManagerScreen::Projects},
  39. { "UpdateProject", ProjectManagerScreen::UpdateProject},
  40. { "UpdateProjectSettings", ProjectManagerScreen::UpdateProjectSettings},
  41. { "Engine", ProjectManagerScreen::Engine},
  42. { "EngineSettings", ProjectManagerScreen::EngineSettings},
  43. { "GemRepos", ProjectManagerScreen::GemRepos},
  44. { "GemsGemRepos", ProjectManagerScreen::GemsGemRepos},
  45. { "CreateGem", ProjectManagerScreen::CreateGem },
  46. { "EditGem", ProjectManagerScreen::EditGem }
  47. };
  48. // need to define qHash for ProjectManagerScreen when using scoped enums
  49. inline uint qHash(ProjectManagerScreen key, uint seed)
  50. {
  51. return ::qHash(static_cast<uint>(key), seed);
  52. }
  53. } // namespace O3DE::ProjectManager