From 8793484e50212d97c1b2ffff282a00e74b048916 Mon Sep 17 00:00:00 2001 From: cnouguier Date: Fri, 9 Aug 2024 14:53:45 +0200 Subject: [PATCH] wip: The layout should store the calculated sizes of the elements #925 --- core/client/components/layout/KWindow.vue | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/core/client/components/layout/KWindow.vue b/core/client/components/layout/KWindow.vue index 417777557..503e04f35 100644 --- a/core/client/components/layout/KWindow.vue +++ b/core/client/components/layout/KWindow.vue @@ -295,6 +295,7 @@ function refresh (newState, oldState) { } function setPinnedGeometry () { const size = computeResponsiveSize(currentWindow.sizePolicy.pinned) + console.log(size) let x, y if (props.placement === 'top' || props.placement === 'bottom') { x = $q.screen.width / 2 - size[0] / 2 @@ -383,7 +384,7 @@ const onResized = _.throttle((event) => { updateGeometry(currentWindow.position, newSize) if (event.isFinal) storeGeometry() } -}, 10) +}, 5) const onScreenResized = _.throttle(() => { if (currentWindow.state === 'pinned') setPinnedGeometry() else if (currentWindow.state === 'maximized') setMaximizedGeometry()