From 3c87f1f1fd3b7a58d29e343641d35bb1382cfac8 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Tue, 21 Jan 2025 18:13:15 -0500 Subject: Use a consistent naming scheme for parent functions These could be combined into a hint-like general get/set mechanism, but currently there's only two window relationships and no immediate plans to add more, so that feels a bit over-engineered. So, just rename for consistency with puglSetTransientParent(). --- bindings/cpp/include/pugl/pugl.hpp | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) (limited to 'bindings/cpp/include/pugl/pugl.hpp') diff --git a/bindings/cpp/include/pugl/pugl.hpp b/bindings/cpp/include/pugl/pugl.hpp index e374efc..5a97079 100644 --- a/bindings/cpp/include/pugl/pugl.hpp +++ b/bindings/cpp/include/pugl/pugl.hpp @@ -558,18 +558,27 @@ public: @{ */ - /// @copydoc puglSetParentWindow - Status setParentWindow(NativeView parent) noexcept + /// @copydoc puglSetParent + Status setParent(NativeView parent) noexcept { - return static_cast(puglSetParentWindow(cobj(), parent)); + return static_cast(puglSetParent(cobj(), parent)); } + /// @copydoc puglGetParent + NativeView parent() const noexcept { return puglGetParent(cobj()); } + /// @copydoc puglSetTransientParent Status setTransientParent(NativeView parent) noexcept { return static_cast(puglSetTransientParent(cobj(), parent)); } + /// @copydoc puglGetTransientParent + NativeView transientParent() const noexcept + { + return puglGetTransientParent(cobj()); + } + /// @copydoc puglRealize Status realize() noexcept { return static_cast(puglRealize(cobj())); } -- cgit v1.2.1