Gary Talent 5c9ab7ae08
Some checks failed
Build / build (push) Has been cancelled
Merge commit 'a4a00c99d05441f5db491e06186039f817cb5c81'
2025-05-17 17:48:31 -05:00

43 lines
1.0 KiB
C++

/*
* Copyright 2016 - 2025 Gary Talent (gary@drinkingtea.net). All rights reserved.
*/
#pragma once
#include <turbine/clipboard.hpp>
#include <turbine/context.hpp>
#include <turbine/gfx.hpp>
#include <turbine/turbine.hpp>
namespace turbine {
class Context {
public:
UpdateHandler updateHandler = [](Context&) -> int {return -1;};
keel::Context keelCtx;
KeyEventHandler keyEventHandler = nullptr;
ox::AnyPtr applicationData;
// GLFW impl data ////////////////////////////////////////////////////////
TimeMs mandatoryRefreshPeriodEnd{};
ox::UPtr<BaseClipboardObject> clipboard;
struct GLFWwindow *window = nullptr;
int refreshWithinMs = 0;
ox::Vector<gl::Drawer*, 5> drawers;
TimeMs startTime = 0;
uint64_t wakeupTime = 0;
uint64_t keysDown = 0;
uint64_t prevFpsCheckTime = 0;
uint64_t draws = 0;
bool running{};
ShutdownHandler shutdownHandler{};
Context() noexcept = default;
Context(Context const&other) noexcept = delete;
Context(Context const&&other) noexcept = delete;
};
}