From 92995c55538a559aa37f5847bfba4347a13fca3b Mon Sep 17 00:00:00 2001 From: dingpinglv Date: Wed, 18 Mar 2015 13:44:34 +0800 Subject: [PATCH] Fixed a bug of template that it doesn't work when it doesn't add loading.js --- frameworks/cocos2d-html5 | 2 +- templates/js-template-default/main.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/frameworks/cocos2d-html5 b/frameworks/cocos2d-html5 index 8177639af5..81c6e1cd97 160000 --- a/frameworks/cocos2d-html5 +++ b/frameworks/cocos2d-html5 @@ -1 +1 @@ -Subproject commit 8177639af56ae4916a2d5162bb07f5ed3b211f6e +Subproject commit 81c6e1cd97570663dea438dc062048574c76a537 diff --git a/templates/js-template-default/main.js b/templates/js-template-default/main.js index e6cc924b91..5ae8759b1c 100644 --- a/templates/js-template-default/main.js +++ b/templates/js-template-default/main.js @@ -48,7 +48,7 @@ */ cc.game.onStart = function(){ - if(!cc.sys.isNative) //If referenced loading.js, please remove it + if(!cc.sys.isNative && document.getElementById("cocosLoading")) //If referenced loading.js, please remove it document.body.removeChild(document.getElementById("cocosLoading")); cc.view.adjustViewPort(true);