チェンジセット 1975
- コミット日時:
- 2008/12/09 01:49:55 (4 年前)
- ファイル:
-
- as3/Slides/trunk/src (更新) (1 prop)
- as3/Slides/trunk/src/LogConfig.as (追加)
- as3/Slides/trunk/src/log.as (更新) (1 diff)
- as3/Slides/trunk/src/uranodai/display/Document.as (更新) (2 diffs)
- as3/Slides/trunk/src/uranodai/display/ExMovieClip.as (更新) (2 diffs)
- as3/Slides/trunk/src/uranodai/display/ExSprite.as (更新) (2 diffs)
- as3/Slides/trunk/src/uranodai/display/ExSpriteHelper.as (更新) (2 diffs)
- as3/Slides/trunk/src/uranodai/logging (削除)
- as3/Slides/trunk/src/uranodai/slides/Slides.as (更新) (3 diffs)
- as3/Slides/trunk/src/uranodai/slides/plugin/ScalePlugin.as (更新) (1 diff)
- as3/Slides/trunk/src/uranodai/slides/scene/ListScene.as (更新) (4 diffs)
- as3/Slides/trunk/src/uranodai/slides/scene/MainScene.as (更新) (7 diffs)
凡例:
- 変更無し
- 追加
- 削除
- 更新
- コピー
- 移動
as3/Slides/trunk/src
- 属性の設定値: svn:ignore (変更前)
Main.as
caurina
sketchbook
fl
jp
com
(変更後)
Main.as
caurina
sketchbook
fl
jp
com
- 属性の設定値: svn:ignore (変更前)
as3/Slides/trunk/src/log.as
r801 r1975 1 1 package 2 2 { 3 import uranodai.display.Document; 4 import uranodai.logging.Out; 5 6 public function log(obj:Object, origin:*=null):void 3 public function log(... args):void 7 4 { 8 Out.log(obj, origin); 5 if (LogConfig.enabled) 6 { 7 trace(args.join(" ")); 8 } 9 9 } 10 10 } as3/Slides/trunk/src/uranodai/display/Document.as
r1015 r1975 29 29 public var onResize:Function; 30 30 31 32 31 private static var _stage:Stage; 33 32 private static var _instance:Document; … … 43 42 return _stage; 44 43 } 45 46 44 47 45 public function Document() as3/Slides/trunk/src/uranodai/display/ExMovieClip.as
r980 r1975 4 4 import flash.events.Event; 5 5 6 import uranodai.logging.Out; 7 6 8 7 public dynamic class ExMovieClip extends MovieClip 9 8 { … … 25 24 override public function dispatchEvent(event:Event):Boolean 26 25 { 27 Out.log(event.type, owner); 26 28 27 //trace(this.toString+"::"+event.type); 29 28 return super.dispatchEvent(event); as3/Slides/trunk/src/uranodai/display/ExSprite.as
r801 r1975 4 4 import flash.events.Event; 5 5 6 import uranodai.logging.Out; 6 7 7 8 8 public dynamic class ExSprite extends Sprite … … 20 20 override public function dispatchEvent(event:Event):Boolean 21 21 { 22 Out.log(event.type, owner); 22 23 23 //trace(this.toString+"::"+event.type); 24 24 return super.dispatchEvent(event); as3/Slides/trunk/src/uranodai/display/ExSpriteHelper.as
r980 r1975 8 8 9 9 import uranodai.external.tweener.Transition; 10 import uranodai.logging.Out; 11 10 12 11 public class ExSpriteHelper extends SpriteHelper 13 12 { … … 19 18 public function dispatchEvent(func:Function, data:Object=null, eventName:String="", origin:*=null):void 20 19 { 21 if(eventName!="") Out.log([eventName, data], origin);22 20 if (func != null) { 23 21 if (data == null) func(); as3/Slides/trunk/src/uranodai/slides/Slides.as
r980 r1975 1 1 package uranodai.slides { 2 import com.voidelement.flagment.Flagment;3 4 2 import flash.display.MovieClip; 5 3 6 4 import jp.progression.Progression; 5 import jp.progression.core.debug.Verbose; 7 6 8 7 import uranodai.display.Document; 9 8 import uranodai.display.RectSprite; 10 import uranodai.logging.Out;11 9 import uranodai.slides.scene.MainScene; 12 10 … … 38 36 Config.height = stage.stageHeight; 39 37 40 Out.enabled = false;38 LogConfig.enabled = false; 41 39 42 40 log("Hello Slides!"); … … 56 54 addChild(bg = new RectSprite(2000,2000, 0xEFEFEF)); 57 55 58 //Progression.verbose.enabled = true;56 Verbose.enabled = false; 59 57 60 58 main = MainScene(prog.root); as3/Slides/trunk/src/uranodai/slides/plugin/ScalePlugin.as
r1025 r1975 36 36 buttonMode = true; 37 37 38 var prog:Progression = Progression.getInstanceById("index");38 //var prog:Progression = Progression.getInstanceById("index"); 39 39 //h = new SpriteHelper(prog.container); 40 40 as3/Slides/trunk/src/uranodai/slides/scene/ListScene.as
r980 r1975 1 1 package uranodai.slides.scene { 2 2 3 import com.voidelement.flagment.Flagment;4 5 3 import jp.progression.commands.AddChild; 4 import jp.progression.commands.DoTweener; 6 5 import jp.progression.commands.RemoveChild; 6 import jp.progression.commands.Trace; 7 import jp.progression.scenes.SceneId; 7 8 import jp.progression.scenes.SceneObject; 8 9 … … 28 29 { 29 30 addCommand( 30 new AddChild(progression.container, ListView.instance, true).before(null, function():void{ 31 ListView.instance.selectOn(index, false); 32 }).after(null,function():void{ 31 32 new AddChild(progression.container, ListView.instance) 33 .before(function():void 34 { 33 35 ListView.instance.selectOn(index, false); 34 36 }) 37 .after(function():void 38 { 39 ListView.instance.selectOn(index, false); 40 //ListView.instance.alpha = 0; 41 }) 42 //new DoTweener(ListView.instance, {alpha:1, time:0.6}) 35 43 ) 36 44 … … 40 48 { 41 49 addCommand( 42 new RemoveChild(progression.container, ListView.instance, true).after(null,function():void{ 43 }) 44 ) 50 51 new RemoveChild(progression.container, ListView.instance) 52 ); 53 54 45 55 } 46 56 … … 54 64 } 55 65 Document.instance.onKeyDownEnter = function():void{ 56 progression.goto(progression.current.parent.parent.sceneId+"/"+ListView.instance.now.toString()); 66 67 //progression.goto(progression.current.parent.parent.sceneId+"/"+ListView.instance.now.toString()); 68 progression.goto(new SceneId(progression.current.parent.parent.sceneId+"/"+ListView.instance.now.toString())); 57 69 } 58 70 } as3/Slides/trunk/src/uranodai/slides/scene/MainScene.as
r980 r1975 2 2 import flash.display.Bitmap; 3 3 import flash.display.BitmapData; 4 import flash.display.FrameLabel;5 4 import flash.display.MovieClip; 6 import flash.display.Scene;7 5 8 6 import jp.progression.commands.AddChildAt; 7 import jp.progression.commands.DoTweener; 8 import jp.progression.commands.Goto; 9 9 import jp.progression.commands.RemoveChild; 10 10 import jp.progression.scenes.SceneObject; … … 21 21 * @author Default 22 22 */ 23 public class MainScene extends SceneObject {24 23 public class MainScene extends SceneObject 24 { 25 25 public var main:MovieClip 26 26 … … 35 35 public var maskView:RectSprite; 36 36 37 public function MainScene(name:String) { 38 super(name); 37 private var _start:SceneObject; 38 private var _goal:SceneObject; 39 40 public function MainScene() { 41 39 42 _instance = this; 40 43 } … … 72 75 var scene:SceneObject = new SceneObject(index.toString()); 73 76 initScene(scene, index); 74 scene.add Child(new ListScene("list", index));77 scene.addScene(new ListScene("list", index)); 75 78 76 79 var bitmapData:BitmapData = new BitmapData(_stage.stageWidth, _stage.stageHeight); … … 94 97 ListView.instance.update(pages); 95 98 96 if(progression.current.children.length>0){ 97 progression.goto((progression.current.children[0] as SceneObject).sceneId); 98 } 99 log(progression) 100 101 log(SceneObject(scenes[0]).sceneId); 102 103 log(scenes[scenes.length-1]) 104 105 _start = scenes[0]; 106 _goal = scenes[scenes.length-1]; 107 108 progression.goto(_start.sceneId); 109 110 //log("***********", progression.firstSceneId) 111 112 if(scenes.length>0){ 113 new Goto((scenes[0] as SceneObject).sceneId).execute(); 114 } 99 115 }else{ 100 116 main.gotoAndStop(index); 101 117 } 102 118 103 /*104 var t:Scene = MovieClip(main.getChildAt(0)).scenes[0]105 trace(t.numFrames)106 for each(var lablel:FrameLabel in t.labels){107 trace(lablel.frame+":"+lablel.name);108 }*/109 110 119 } 111 120 112 121 private var helper:SpriteHelper; 113 122 123 private var _loaded:Boolean = false; 124 114 125 private function initScene(scene:SceneObject, i:int):void 115 126 { 127 116 128 scene.onLoad = function():void 117 129 { 130 118 131 main.gotoAndStop(int(scene.name)); 119 scene.addCommand( 120 new AddChildAt(progression.container, main, 1, false, true) 121 ); 132 133 if(!_loaded) 134 { 135 scene.addCommand( 136 new AddChildAt(progression.container, main, 1) 137 ); 138 _loaded = true; 139 } 140 else{ 141 scene.addCommand( 142 new AddChildAt(progression.container, main, 1), 143 new DoTweener(main, {alpha:1, time:0.5, transition:"easeOutCubic"}) 144 ); 145 } 146 147 148 122 149 123 150 pluginsView.addSceneOnLoadAction(scene); 151 124 152 } 125 153 scene.onUnload = function():void 126 154 { 155 127 156 scene.addCommand( 128 new RemoveChild(progression.container, main, true) 157 new DoTweener(main, {alpha:0, time:0.5, transition:"linear"}), 158 new RemoveChild(progression.container, main) 129 159 ); 130 160 131 161 pluginsView.addSceneOnUnLoadAction(scene); 162 132 163 } 133 164 scene.onInit = function():void 134 165 { 135 /* 136 scene.extra.list = []; 137 scene.extra.helper = new SpriteHelper(now); 138 scene.extra.index = 0; 139 */ 166 scene.sceneInfo.data.list = []; 167 scene.sceneInfo.data.helper = new SpriteHelper(now); 168 scene.sceneInfo.data.index = 0; 169 140 170 141 171 Document.instance.onKeyDownRight = function():void{ 142 172 if (now.currentFrame < now.totalFrames) { 173 143 174 now.play(); 144 /*175 145 176 var helper:SpriteHelper = new SpriteHelper(now); 146 177 var n:int = now.currentFrame; … … 150 181 n = now.currentFrame; 151 182 if(n == p){ 152 //trace(">>>"+n);153 183 helper.onEnterFrame = null; 154 scene.extra.index++;155 if(scene.extra.index >= scene.extra.list.length){156 scene.extra.list.push(n);157 }158 trace(scene.extra.list);159 160 184 } 161 185 p = n; 162 } */186 } 163 187 }else{ 164 progression.goto(progression.current.next.sceneId); 188 189 if(progression.current.next != null) 190 { 191 progression.goto(progression.current.next.sceneId); 192 } 193 else 194 { 195 progression.goto(_start.sceneId) 196 } 165 197 } 166 198 } 167 199 Document.instance.onKeyDownLeft = function():void{ 168 progression.goto(progression.current.previous.sceneId); 169 /* 170 if(now.currentFrame > 1){ 171 scene.extra.index--; 172 now.gotoAndPlay(scene.extra.list[scene.extra.index]); 173 }else{ 200 201 if(progression.current.previous != null) 202 { 174 203 progression.goto(progression.current.previous.sceneId); 175 }*/ 204 } 205 else 206 { 207 progression.goto(_goal.sceneId) 208 } 176 209 177 210 } 178 211 179 212 Document.instance.onKeyDownEnter = function():void{ 180 if(progression.current.children.length>0){ 181 progression.goto(progression.current.children[0].sceneId); 213 log(progression.current.scenes[0].sceneId); 214 215 if(progression.current.scenes.length>0){ 216 progression.goto(progression.current.scenes[0].sceneId); 182 217 } 183 218 } … … 185 220 Document.instance.onKeyDownDown = function():void 186 221 { 187 if(now.totalFrames>1 ){222 if(now.totalFrames>1 && now.currentFrame>1){ 188 223 now.gotoAndPlay(1); 189 224 } 190 225 } 191 226 192 /* 193 if (now.currentFrame < now.totalFrames) { 194 scene.extra.list.push(now.currentFrame); 195 }*/ 196 197 } 198 199 addChild(scene); 227 } 228 229 addScene(scene); 200 230 } 201 231

