Fix JS AssetsManagerTest and Improve scheduler wrapper (#16605)

* Fix tests for v3.12 web

* Improve scheduler wrapper

* Update web engine ref
This commit is contained in:
pandamicro 2016-09-26 14:44:32 +08:00 committed by minggo
parent 59574f95e0
commit 466053b740
4 changed files with 12 additions and 5 deletions

View File

@ -1271,8 +1271,12 @@ void JSScheduleWrapper::scheduleFunc(float dt)
{
JS::HandleValueArray args = JS::HandleValueArray::fromMarkedLocation(1, &data);
JS::RootedValue retval(cx);
JS::RootedObject target(cx, getJSCallbackThis().toObjectOrNull());
JS_CallFunctionValue(cx, target, callback, args, &retval);
JS::RootedValue targetVal(cx, getJSCallbackThis());
if (!targetVal.isNullOrUndefined())
{
JS::RootedObject target(cx, targetVal.toObjectOrNull());
JS_CallFunctionValue(cx, target, callback, args, &retval);
}
}
}
}

View File

@ -199,7 +199,7 @@ var AssetsManagerLoaderScene = TestScene.extend({
layer.addChild(this._fileLoadingBar);
this._am = new jsb.AssetsManager(manifestPath, storagePath);
// this._am.retain();
this._am.retain();
if (!this._am.getLocalManifest().isLoaded())
{

View File

@ -3,10 +3,13 @@ html {
}
body, canvas, div {
display: block;
outline: none;
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
-moz-user-select: none;
-webkit-user-select: none;
-ms-user-select: none;
-khtml-user-select: none;
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}
}

2
web

@ -1 +1 @@
Subproject commit cff01472af3f1203e4422ee84615e8fb3de9f9c5
Subproject commit e10208255f9eae2c25db5e04e395f4258406dbcd