aboutsummaryrefslogtreecommitdiffstats
path: root/pugl
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2019-08-04 11:02:04 +0200
committerDavid Robillard <d@drobilla.net>2019-09-03 08:34:39 +0200
commit7d72d835097ea87d53b0e439ac759ef956ed0432 (patch)
treec89813d49164d202d6e1d87cda564b0ea841cafa /pugl
parent9b2bbb1cb49e7e301d48138f86c40def6775c2fe (diff)
downloadpugl-7d72d835097ea87d53b0e439ac759ef956ed0432.tar.gz
pugl-7d72d835097ea87d53b0e439ac759ef956ed0432.tar.bz2
pugl-7d72d835097ea87d53b0e439ac759ef956ed0432.zip
Windows: Fix configured size of child views
Diffstat (limited to 'pugl')
-rw-r--r--pugl/detail/win.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/pugl/detail/win.c b/pugl/detail/win.c
index 483ee43..486c5e3 100644
--- a/pugl/detail/win.c
+++ b/pugl/detail/win.c
@@ -407,6 +407,11 @@ handleConfigure(PuglView* view, PuglEvent* event)
{
RECT rect;
GetClientRect(view->impl->hwnd, &rect);
+ MapWindowPoints(view->impl->hwnd,
+ view->parent ? (HWND)view->parent : HWND_DESKTOP,
+ (LPPOINT)&rect,
+ 2);
+
view->frame.x = rect.left;
view->frame.y = rect.top;
view->frame.width = rect.right - rect.left;