diff --git a/source/frontend/StarShadersMenu.cpp b/source/frontend/StarShadersMenu.cpp new file mode 100644 index 0000000..4e15b66 --- /dev/null +++ b/source/frontend/StarShadersMenu.cpp @@ -0,0 +1,22 @@ +#include "StarShadersMenu.hpp" + +namespace Star { + +ShadersMenu::ShadersMenu(Json const& config, UniverseClientPtr client) : BaseScriptPane(config) { + m_client = std::move(client); +} + +void ShadersMenu::show() { + BaseScriptPane::show(); +} + +void ShadersMenu::displayed() { + m_script.setLuaRoot(m_client->luaRoot()); + BaseScriptPane::displayed(); +} + +void ShadersMenu::dismissed() { + BaseScriptPane::dismissed(); +} + +} diff --git a/source/frontend/StarShadersMenu.hpp b/source/frontend/StarShadersMenu.hpp new file mode 100644 index 0000000..9b24b0d --- /dev/null +++ b/source/frontend/StarShadersMenu.hpp @@ -0,0 +1,22 @@ +#pragma once + +#include "StarBaseScriptPane.hpp" +#include "StarUniverseClient.hpp" + +namespace Star { + +STAR_CLASS(ShadersMenu); + +class ShadersMenu : public BaseScriptPane { +public: + ShadersMenu(Json const& config, UniverseClientPtr client); + + virtual void show() override; + void displayed() override; + void dismissed() override; + +private: + UniverseClientPtr m_client; +}; + +}