aboutsummaryrefslogtreecommitdiffstats
path: root/bindings/cxx/include/pugl/pugl.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'bindings/cxx/include/pugl/pugl.hpp')
-rw-r--r--bindings/cxx/include/pugl/pugl.hpp11
1 files changed, 9 insertions, 2 deletions
diff --git a/bindings/cxx/include/pugl/pugl.hpp b/bindings/cxx/include/pugl/pugl.hpp
index dd7389e..9e391fa 100644
--- a/bindings/cxx/include/pugl/pugl.hpp
+++ b/bindings/cxx/include/pugl/pugl.hpp
@@ -281,14 +281,21 @@ public:
~World() = default;
- explicit World(WorldType type, WorldFlags flags)
+ World(WorldType type, WorldFlag flag)
+ : Wrapper{puglNewWorld(static_cast<PuglWorldType>(type),
+ static_cast<PuglWorldFlags>(flag))}
+ {
+ PUGL_CHECK_CONSTRUCTION(cobj(), "Failed to create pugl::World");
+ }
+
+ World(WorldType type, WorldFlags flags)
: Wrapper{puglNewWorld(static_cast<PuglWorldType>(type), flags)}
{
PUGL_CHECK_CONSTRUCTION(cobj(), "Failed to create pugl::World");
}
explicit World(WorldType type)
- : World{type, {}}
+ : World{type, WorldFlags{}}
{}
/// @copydoc puglGetNativeWorld