added type information to tweenjs-test.ts and loadHandler method of soundjs-test.ts.

This commit is contained in:
s_kimura
2013-11-28 12:19:00 +09:00
parent 5f6f23fd76
commit a41a87730a
2 changed files with 2 additions and 3 deletions
+1 -1
View File
@@ -5,7 +5,7 @@
// Feature set example:
createjs.Sound.addEventListener("fileload", createjs.proxy(this.loadHandler, this));
createjs.Sound.registerSound("path/to/mySound.mp3|path/to/mySound.ogg", "sound");
function loadHandler(event):void {
function loadHandler(event:Object):void {
// This is fired for each sound that is registered.
var instance: createjs.SoundInstance = createjs.Sound.play("sound"); // play using id. Could also use full sourcepath or event.src.
instance.addEventListener("complete", createjs.proxy(this.handleComplete, this));
+1 -2
View File
@@ -2,12 +2,11 @@
///<reference path="../easeljs/easeljs.d.ts"/>
var target: createjs.DisplayObject = new createjs.DisplayObject();
var Tween: createjs.Tween = createjs.Tween;
// source : http://www.createjs.com/Docs/TweenJS/modules/TweenJS.html
// Chainable modules :
target.alpha = 1;
Tween.get(target).wait(500, false).to({ alpha: 0, visible: false }, 1000).call(onComplete);
createjs.Tween.get(target).wait(500, false).to({ alpha: 0, visible: false }, 1000).call(onComplete);
function onComplete() {
//Tween complete
}