BsEditorApplication.h 880 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. #pragma once
  2. #include "BsEditorPrerequisites.h"
  3. #include "CmModule.h"
  4. namespace BansheeEditor
  5. {
  6. enum class RenderSystemPlugin
  7. {
  8. DX11,
  9. DX9,
  10. OpenGL
  11. };
  12. class BS_ED_EXPORT EditorApplication : public CM::Module<EditorApplication>
  13. {
  14. public:
  15. EditorApplication(RenderSystemPlugin renderSystemPlugin);
  16. ~EditorApplication();
  17. void runMainLoop();
  18. bool isProjectLoaded() const;
  19. const CM::WString& getActiveProjectPath() const;
  20. private:
  21. static const CM::WString WIDGET_LAYOUT_PATH;
  22. RenderSystemPlugin mActiveRSPlugin;
  23. static const CM::String& getLibraryNameForRenderSystem(RenderSystemPlugin plugin);
  24. void update();
  25. EditorWidgetLayoutPtr loadWidgetLayout();
  26. void saveWidgetLayout(const EditorWidgetLayoutPtr& layout);
  27. static void closeModalWindow(CM::RenderWindowPtr window, CM::HSceneObject sceneObject);
  28. };
  29. }