チェンジセット 1515
- コミット日時:
- 2008/10/05 02:47:20 (5 年前)
- ファイル:
-
- as3/gunyarapaint/trunk/gunyarapaint/src/gplogplayer.mxml (更新) (3 diffs)
- as3/gunyarapaint/trunk/gunyarapaint/src/gunyarapaint.mxml (更新) (1 diff)
- as3/gunyarapaint/trunk/gunyarapaint/src/org/libspark/gunyarapaint/entities/GPLayerArray.as (更新) (5 diffs)
- as3/gunyarapaint/trunk/gunyarapaint/src/org/libspark/gunyarapaint/entities/GPLogger.as (更新) (5 diffs)
凡例:
- 変更無し
- 追加
- 削除
- 更新
- コピー
- 移動
as3/gunyarapaint/trunk/gunyarapaint/src/gplogplayer.mxml
r1505 r1515 34 34 /*** debug ***/ 35 35 private var debugOekakiId:uint = 0; // 0でデバッグしない 36 private var debugOekakiRefId:uint = 0; 36 37 private var debugCheckPngUrl:String; 37 38 private var debugCheckPng:ByteArray; … … 117 118 118 119 if (baseImg && !baseImgInfo) { 119 baseImgInfo = {'width': baseImg.width, 'height': baseImg.height };120 baseImgInfo = {'width': baseImg.width, 'height': baseImg.height, 'undoBufferSize': 16}; 120 121 } 121 // ●● changeImageCallbackを指定するように 122 _logger = GPLogger.createFromByteArray(oelog, false, null, null); 122 _logger = GPLogger.createFromByteArray(oelog, false, baseImg, baseImgInfo); 123 123 124 124 canvas.removeAllChildren(); … … 163 163 ]]> 164 164 </mx:Script> 165 <mx:Label x="313" y="11" text="ver.2008100 402"/>165 <mx:Label x="313" y="11" text="ver.2008100502"/> 166 166 </mx:Application> as3/gunyarapaint/trunk/gunyarapaint/src/gunyarapaint.mxml
r1505 r1515 12 12 </mx:Script> 13 13 <mx:Canvas id="toolCanvas" x="0" y="0" width="685" height="102"> 14 <mx:Label id="versionLabel" x="238" y="9" text="ver.2008100 402"/>14 <mx:Label id="versionLabel" x="238" y="9" text="ver.2008100502"/> 15 15 <mx:Label x="28" y="7" text="名前"/> 16 16 <mx:TextInput id="fromTextInput" x="55" y="3" maxChars="32" fontSize="14" focusThickness="0"/> as3/gunyarapaint/trunk/gunyarapaint/src/org/libspark/gunyarapaint/entities/GPLayerArray.as
r1503 r1515 73 73 } 74 74 } 75 76 public function get dataForUndoBuffer():Object {77 var a:Array = new Array();78 for (var i:uint = 0; i < _a.length; i++) {79 a[i] = _a[i].clone();80 }81 // loggerは11インスタンスしかない82 return new GPLayerArray(_logger, a, _targetIndex, _width, _height);83 }84 75 85 76 public function set dataFromUndoBuffer(data:Object):void { … … 263 254 for (i = 0; i < _a.length; i++) { 264 255 _view.removeChild(_a[i].bitmap); 265 } 256 } 266 257 _a = new Array(); 267 258 for (i = 0; i < obj.layers.length; i++) { … … 332 323 return _view; 333 324 } 325 326 334 327 // 描画用レイヤを一時的に挿入・削除する。 335 328 public function insertDrawLayer(s:Shape, p:GPPen):void { … … 346 339 _a[_targetIndex].blendMode = flash.display.BlendMode.NORMAL; 347 340 _a[_targetIndex].alpha = 1; 348 /*341 /* 349 342 s.blendMode = p.blendMode; 350 343 s.alpha = p.alpha; 351 */344 */ 352 345 _targetSprite.addChild(_a[_targetIndex].bitmap); 353 346 _targetSprite.addChild(s); 354 _view.addChildAt(_targetSprite, _targetIndex); 347 _view.addChildAt(_targetSprite, _targetIndex); 355 348 } 356 349 public function removeDrawLayer(s:Shape):void { … … 375 368 return 0xffffff; 376 369 } 377 } 370 } 371 public function get length():uint { 372 return _a.length; 373 } 378 374 } 379 375 } as3/gunyarapaint/trunk/gunyarapaint/src/org/libspark/gunyarapaint/entities/GPLogger.as
r1503 r1515 126 126 case '0.0.4:': 127 127 case '0.0.5:': 128 case '0.0.6:': 128 129 break; 129 130 default: … … 143 144 var log:ByteArray = new ByteArray(); 144 145 log.endian = flash.utils.Endian.BIG_ENDIAN; 145 log.writeUTFBytes('GUNYARA_PAINT:0.0. 5:');146 log.writeUTFBytes('GUNYARA_PAINT:0.0.6:'); 146 147 log.writeShort(width); 147 148 log.writeShort(height); … … 291 292 _playCompleteCallback(); 292 293 break; 294 } 295 if (_layerArray.view.numChildren != _layerArray.length) { 296 // check logic 293 297 } 294 298 } … … 793 797 } 794 798 _pen.floodFill(); 799 invokeRemoveDrawLayer(); 795 800 trace('FLOOD_FILL'); 796 801 } … … 904 909 trace('LAYER_CHANGE_VISIBLE target:' + target + ' value:' + visible); 905 910 906 // UndoRedoには反映しない911 pushUndoBuffer(); 907 912 invokeLayerChange(); 908 913 }

