add on detach
This commit is contained in:
@@ -11,6 +11,12 @@ namespace example
|
|||||||
hack::log()("on_attach");
|
hack::log()("on_attach");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void ui_layer::on_detach()
|
||||||
|
{
|
||||||
|
VE::DISCONNECT(this);
|
||||||
|
hack::log()("on_detach");
|
||||||
|
}
|
||||||
|
|
||||||
void ui_layer::render()
|
void ui_layer::render()
|
||||||
{
|
{
|
||||||
ImGui::SetNextWindowPos(m_pos);
|
ImGui::SetNextWindowPos(m_pos);
|
||||||
|
|||||||
@@ -11,6 +11,12 @@ namespace example
|
|||||||
hack::log()("on_attach");
|
hack::log()("on_attach");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void ui_layer_double::on_detach()
|
||||||
|
{
|
||||||
|
VE::DISCONNECT(this);
|
||||||
|
hack::log()("on_detach");
|
||||||
|
}
|
||||||
|
|
||||||
void ui_layer_double::render()
|
void ui_layer_double::render()
|
||||||
{
|
{
|
||||||
ImGui::SetNextWindowPos(ImVec2{ 10.f, 10.f });
|
ImGui::SetNextWindowPos(ImVec2{ 10.f, 10.f });
|
||||||
|
|||||||
@@ -16,6 +16,7 @@ namespace VE
|
|||||||
|
|
||||||
public:
|
public:
|
||||||
virtual void on_attach() {};
|
virtual void on_attach() {};
|
||||||
|
virtual void on_detach() {};
|
||||||
virtual void render() {};
|
virtual void render() {};
|
||||||
virtual void update() {};
|
virtual void update() {};
|
||||||
virtual void on_event(event e) {};
|
virtual void on_event(event e) {};
|
||||||
|
|||||||
@@ -6,6 +6,7 @@
|
|||||||
#define VE_OVERIDE()\
|
#define VE_OVERIDE()\
|
||||||
public:\
|
public:\
|
||||||
void on_attach() override;\
|
void on_attach() override;\
|
||||||
|
void on_detach() override;\
|
||||||
void render() override;\
|
void render() override;\
|
||||||
void update() override;\
|
void update() override;\
|
||||||
void on_event(VE::event e) override
|
void on_event(VE::event e) override
|
||||||
|
|||||||
Reference in New Issue
Block a user