mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-07 03:51:50 +00:00
add gui.get_active_frame, set_active_frame & update cursor lock behavior
This commit is contained in:
parent
463098aa1e
commit
8468ab184d
11 changed files with 123 additions and 50 deletions
|
|
@ -8,7 +8,10 @@ class UiDocument;
|
|||
namespace gui {
|
||||
class Frame final : public Container {
|
||||
public:
|
||||
Frame(GUI& gui, std::string outputTexture);
|
||||
struct State {
|
||||
};
|
||||
|
||||
Frame(GUI& gui, std::string id, std::string outputTexture);
|
||||
virtual ~Frame();
|
||||
|
||||
void draw(const DrawContext& pctx, const Assets& assets) override;
|
||||
|
|
@ -16,7 +19,14 @@ namespace gui {
|
|||
void updateOutput(Assets& assets);
|
||||
|
||||
const std::string& getOutputTexture() const;
|
||||
|
||||
const std::string& getFrameId() const;
|
||||
|
||||
/// @brief Frame state is controlled in gui::GUI
|
||||
State& getState();
|
||||
private:
|
||||
std::string frameId;
|
||||
State state {};
|
||||
std::unique_ptr<Framebuffer> fbo;
|
||||
std::string outputTexture;
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue