aboutsummaryrefslogtreecommitdiffstats
path: root/pugl/detail
diff options
context:
space:
mode:
Diffstat (limited to 'pugl/detail')
-rw-r--r--pugl/detail/implementation.c6
-rw-r--r--pugl/detail/x11.c13
2 files changed, 13 insertions, 6 deletions
diff --git a/pugl/detail/implementation.c b/pugl/detail/implementation.c
index f971284..a64e6fd 100644
--- a/pugl/detail/implementation.c
+++ b/pugl/detail/implementation.c
@@ -143,12 +143,6 @@ puglInitWindowParent(PuglView* view, PuglNativeWindow parent)
view->parent = parent;
}
-void
-puglInitTransientFor(PuglView* view, uintptr_t parent)
-{
- view->transientParent = parent;
-}
-
int
puglInitBackend(PuglView* view, const PuglBackend* backend)
{
diff --git a/pugl/detail/x11.c b/pugl/detail/x11.c
index d7b7677..ea8367c 100644
--- a/pugl/detail/x11.c
+++ b/pugl/detail/x11.c
@@ -761,3 +761,16 @@ puglSetAspectRatio(PuglView* const view,
return PUGL_SUCCESS;
}
+
+void
+puglSetTransientFor(PuglView* view, PuglNativeWindow parent)
+{
+ Display* display = view->world->impl->display;
+
+ view->transientParent = parent;
+
+ if (view->impl->win) {
+ XSetTransientForHint(display, view->impl->win,
+ (Window)view->transientParent);
+ }
+}