From a12836148d65b7c09fe84cf0fc636fc70e3fa73b Mon Sep 17 00:00:00 2001 From: Jordan Eldredge Date: Thu, 26 Jul 2018 08:00:45 -0700 Subject: [PATCH] Fix skins with region.txt If the positioning is sub-pixel, the clip-path can get off a bit --- js/components/WindowManager.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/js/components/WindowManager.js b/js/components/WindowManager.js index 3f6b8b90..4ea4fa40 100644 --- a/js/components/WindowManager.js +++ b/js/components/WindowManager.js @@ -69,8 +69,8 @@ class WindowManager extends React.Component { const boxWidth = bounding.right - bounding.left; const move = { - x: offsetLeft + (width - boxWidth) / 2, - y: offsetTop + (height - boxHeight) / 2 + x: Math.ceil(offsetLeft + (width - boxWidth) / 2), + y: Math.ceil(offsetTop + (height - boxHeight) / 2) }; const newPositions = this.props.windowsInfo.reduce(