From 425c2c26511feb0726fd587d9d04c044b746370e Mon Sep 17 00:00:00 2001 From: ckcz123 Date: Tue, 2 Jun 2020 20:28:12 +0800 Subject: [PATCH] =?UTF-8?q?=E7=A7=BB=E9=99=A4html=E4=B8=AD=E7=9A=84size?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- index.html | 20 ++++++++++---------- libs/core.js | 5 +++++ 2 files changed, 15 insertions(+), 10 deletions(-) diff --git a/index.html b/index.html index 818a381e..e6c2633d 100644 --- a/index.html +++ b/index.html @@ -166,16 +166,16 @@
- - - - - - - - - - 此浏览器不支持HTML5 + + + + + + + + + + 此浏览器不支持HTML5
diff --git a/libs/core.js b/libs/core.js index bb01d112..148d537b 100644 --- a/libs/core.js +++ b/libs/core.js @@ -226,6 +226,11 @@ core.prototype.init = function (coreData, callback) { this._init_others(); this._initPlugins(); + // 初始化画布 + for (var name in core.canvas) { + core.canvas[name].canvas.width = core.canvas[name].canvas.height = core.__PIXELS__; + } + core.loader._load(function () { core.extensions._load(function () { core._afterLoadResources(callback);