浏览代码

Make scroll-resizing work with auto-world size

tags/v0.1.0
Fen Dweller 6 年前
父节点
当前提交
342ac91861
共有 1 个文件被更改,包括 6 次插入0 次删除
  1. +6
    -0
      macrovision.js

+ 6
- 0
macrovision.js 查看文件

@@ -715,6 +715,7 @@ document.addEventListener("DOMContentLoaded", () => {
config.height = math.multiply(config.height, dir);
updateWorldOptions();
}
checkFitWorld();
updateSizes();
})
document.querySelector("body").appendChild(testCtx.canvas);
@@ -918,6 +919,11 @@ document.addEventListener("touchmove", (e) => {
}
}, { passive: false });

function checkFitWorld() {
if (config.autoFit) {
fitWorld();
}
}
function fitWorld() {
let max = math.unit(0, "meter");



正在加载...
取消
保存