add events for imgui

This commit is contained in:
lauchmelder 2025-01-05 20:56:24 +01:00
parent 996c583520
commit 2b0f757fcb
19 changed files with 490 additions and 24 deletions

View file

@ -1,5 +1,5 @@
#include <memory>
#include <quark.hpp>
#include "quark/imgui/ImGuiLayer.hpp"
class ExampleLayer :
public qk::Layer
@ -10,7 +10,7 @@ public:
{ }
void OnUpdate() override {
QK_TRACE("ExampleLayer::Update");
// QK_TRACE("ExampleLayer::Update");
}
void OnEvent(qk::Event& event) override {
@ -24,9 +24,10 @@ class Sandbox :
public:
Sandbox() {
PushLayer(new ExampleLayer);
PushOverlay(new qk::ImGuiLayer);
}
};
std::unique_ptr<qk::Application> qk::CreateApplication() {
return std::make_unique<Sandbox>();
qk::Application* qk::CreateApplication() {
return new Sandbox;
}