Skip to content

Commit

Permalink
Fix ImGuiContextScope
Browse files Browse the repository at this point in the history
  • Loading branch information
doyaGu committed Jul 4, 2024
1 parent 7803dc1 commit 97dd83a
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions include/BML/Bui.h
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,16 @@ namespace Bui {
ImGui::SetCurrentContext(GetImGuiContext());
}

ImGuiContextScope(const ImGuiContextScope &rhs) = delete;
ImGuiContextScope(ImGuiContextScope &&rhs) noexcept = delete;

~ImGuiContextScope() {
ImGui::SetCurrentContext(m_ImGuiContext);
}

ImGuiContextScope &operator=(const ImGuiContextScope &rhs) = delete;
ImGuiContextScope &operator=(ImGuiContextScope &&rhs) noexcept = delete;

private:
ImGuiContext *m_ImGuiContext;
};
Expand Down

0 comments on commit 97dd83a

Please sign in to comment.