浏览代码

Tweak the position of the immersive viewport

customisations
alemart 1年前
父节点
当前提交
2ce01af236
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2
    2
      src/core/viewport.ts

+ 2
- 2
src/core/viewport.ts 查看文件

@@ -879,8 +879,8 @@ export class ImmersiveViewport extends ResizableViewport
879 879
                 viewportHeight = (viewportWidth / viewportAspectRatio) | 0;
880 880
             }
881 881
 
882
-            container.style.left = `calc(50% - ${viewportWidth >>> 1}px)`;
883
-            container.style.top = `calc(50% - ${viewportHeight >>> 1}px)`;
882
+            container.style.left = `calc(50% - ${(viewportWidth+1) >>> 1}px)`;
883
+            container.style.top = `calc(50% - ${(viewportHeight+1) >>> 1}px)`;
884 884
             container.style.width = viewportWidth + 'px';
885 885
             container.style.height = viewportHeight + 'px';
886 886
         }

正在加载...
取消
保存