チェンジセット 1624
- コミット日時:
- 2008/10/15 17:40:06 (3 年前)
- ファイル:
-
- ruby/jsplash/trunk/client2/demo_20081001.xml (更新) (1 diff)
- ruby/jsplash/trunk/client2/esanta.xml (更新) (1 diff)
- ruby/jsplash/trunk/client2/esanta/movie1.js (更新) (1 diff)
- ruby/jsplash/trunk/client2/index.xml (更新) (1 diff)
- ruby/jsplash/trunk/client2/jsplash/null.cur (追加)
- ruby/jsplash/trunk/client2/jsplash/null.gif (追加)
- ruby/jsplash/trunk/client2/jsplash/objects.js (更新) (6 diffs)
- ruby/jsplash/trunk/client2/jsplash/player.js (更新) (3 diffs)
- ruby/jsplash/trunk/client2/jsplash/swfglobal.js (更新) (1 diff)
- ruby/jsplash/trunk/client2/rocket_demo.xml (更新) (1 diff)
凡例:
- 変更無し
- 追加
- 削除
- 更新
- コピー
- 移動
ruby/jsplash/trunk/client2/demo_20081001.xml
r1619 r1624 56 56 <p id="statusout"> </p> 57 57 <p>playing on javascript with JSplash</p> 58 <p id="sout">starting <em>JSplash Player 0.4.1 2</em>...<br />-------------------------------------<br /></p>58 <p id="sout">starting <em>JSplash Player 0.4.13</em>...<br />-------------------------------------<br /></p> 59 59 <svg id="svgrt" xmlns="http://www.w3.org/2000/svg" style="width: 100px; height: 100px;"> 60 60 </svg> ruby/jsplash/trunk/client2/esanta.xml
r1622 r1624 70 70 <div id="progbar"><div> </div></div> 71 71 <p id="statusout"> </p> 72 <p id="sout"><em>JSplash Player</em> 0.4.1 2<br /></p>72 <p id="sout"><em>JSplash Player</em> 0.4.13<br /></p> 73 73 <svg id="svgrt" xmlns="http://www.w3.org/2000/svg" style="width: 100px; height: 100px;"> 74 74 </svg> ruby/jsplash/trunk/client2/esanta/movie1.js
r1622 r1624 1 1 JSplash.load_swf( { 2 header: {frameRate: 20, frames: 1, width: 12800, height: 9600},2 header: {frameRate: 20, frames: 1, width: 9600, height: 10800}, 3 3 exports: {'mc_dot':4,'mc_line':1,'__Packages.Spring':63,'__Packages.Node':65,'__Packages.Muscle':64}, 4 4 taglist: [ ruby/jsplash/trunk/client2/index.xml
r1619 r1624 54 54 <div id="progbar"><div> </div></div> 55 55 <p id="statusout"> </p> 56 <p id="sout"><em>JSplash Player</em> 0.4.1 2<br />-------------------------------------<br /></p>56 <p id="sout"><em>JSplash Player</em> 0.4.13<br />-------------------------------------<br /></p> 57 57 <svg id="svgrt" xmlns="http://www.w3.org/2000/svg" style="width: 100px; height: 100px;"> 58 58 </svg> ruby/jsplash/trunk/client2/jsplash/objects.js
r1619 r1624 48 48 this.dynamic = false; 49 49 this.dynDepthBase = null; 50 this.bboxCache = {w:null, h:null}; 50 51 51 52 this.mousePos = {x:0, y:0}; … … 193 194 194 195 }, 196 197 invalidateBBox: function() { 198 for (o = this;;o = o.parent) { 199 o.bboxCache.w = null; 200 if (o.is_stage) break; 201 } 202 }, 195 203 196 204 placeObject: function(depth, oid, iname, clip_depth, replace_flg, inherit_transform, inherit_color_transform) { 197 205 this.clipMap[depth] = clip_depth || this.clipMap[depth]; 206 this.invalidateBBox(); 198 207 199 208 if (this.context.reachedFrame > this.context.frameC) { … … 202 211 if (this.depthMap[depth] != po) 203 212 { 204 if (this.depthMap[depth] && this.depthMap[depth].klass.classId == 4) console.log(depth);205 213 this.removeObject(depth); 206 214 } … … 352 360 353 361 removeObject: function(depth, to_replace) { 362 this.invalidateBBox(); 354 363 var o = this.pickPlacedObjectAt(depth); 355 364 … … 749 758 var T = this.pxTransform; 750 759 760 this.checkSizeChange(P); 751 761 if (P._x != T.mx || P._y != T.my || 752 762 P._xscale != T.sx || P._yscale != T.sy || … … 809 819 if (JSplash._bbox_implemented) { 810 820 try { 811 var b = this.g.getBBox(); 812 P._width = b.width; 813 P._height = b.height; 821 if (this.bboxCache.w == null) 822 { 823 var bx = this.g.getBBox(); 824 this.bboxCache.w = bx.width; 825 this.bboxCache.h = bx.height; 826 } 827 828 var b = this.bboxCache; 829 P._width = b.w; 830 P._height = b.h; 814 831 } catch(e) { 815 832 console.warn("This browser does not support SVG bounding box completely."); 833 JSplash._bbox_implemented = false; 834 } 835 } 836 }, 837 838 checkSizeChange: function(P) { 839 if (JSplash._bbox_implemented) { 840 try { 841 842 var T = this.pxTransform; 843 844 if (this.bboxCache.w == null) 845 { 846 var bx = this.g.getBBox(); 847 this.bboxCache.w = bx.width; 848 this.bboxCache.h = bx.height; 849 } 850 851 var b = this.bboxCache; 852 853 var d, o; 854 855 d = P._width - b.w; 856 if (d<-0.01 || d > 0.01) { 857 o = b.w; 858 if (o < -.1 || o > .1) 859 P._xscale = (P._width / o) * 100.0; 860 } 861 862 d = P._height - b.h; 863 if (d<-0.01 || d > 0.01) { 864 o = b.h; 865 if (o < -.1 || o > .1) 866 P._yscale = (P._height / o) * 100.0; 867 } 868 869 } catch(e) { 870 console.warn("This browser does not support SVG bounding box completely: "+e); 816 871 JSplash._bbox_implemented = false; 817 872 } ruby/jsplash/trunk/client2/jsplash/player.js
r1619 r1624 19 19 this.executor.frameRate = swf.frameRate; 20 20 this.svg = svg; 21 this.bodyElement = document.getElementsByTagName("body")[0]; 21 22 JSplash.createFillDef(svg); 22 23 … … 39 40 svg.addEventListener("mousemove", this.onTopMouseMove.bind(this, svg), false); 40 41 svg.addEventListener("mousedown", this.onTopMouseDown.bind(this), false); 41 document.getElementsByTagName("body")[0].addEventListener("mouseup", this.onGlobalMouseUp.bind(this), false);42 this.bodyElement.addEventListener("mouseup", this.onGlobalMouseUp.bind(this), false); 42 43 43 44 JSplash.SWFGlobals.setup(this); 44 45 this.preprocessShapes(0); 46 }, 47 48 hideCursor: function() { 49 Element.addClassName(this.bodyElement, "jsplash-hide-cursor"); 50 }, 51 52 showCursor: function() { 53 Element.removeClassName(this.bodyElement, "jsplash-hide-cursor"); 45 54 }, 46 55 … … 157 166 document.styleSheets[0].insertRule(":active>.jsplash-btn-down{visibility:visible;}", 0); 158 167 168 document.styleSheets[0].insertRule(".jsplash-hide-cursor .jsplash-hitarea, .jsplash-hide-cursor{cursor:url('./jsplash/null.gif'), default;}", 0); 159 169 document.styleSheets[0].insertRule(".jsplash-hitarea{opacity:0; cursor:pointer;}", 0); 160 170 ruby/jsplash/trunk/client2/jsplash/swfglobal.js
r1619 r1624 33 33 JSplash.SWFGlobals.Mouse = { 34 34 hide: function() { 35 JSplash.gPlayer.hideCursor(); 35 36 }, 36 37 37 38 show: function() { 39 JSplash.gPlayer.showCursor(); 38 40 } 39 41 } ruby/jsplash/trunk/client2/rocket_demo.xml
r1619 r1624 56 56 <p id="statusout"> </p> 57 57 <p>playing on javascript with JSplash</p> 58 <p id="sout">starting <em>JSplash Player 0.4.1 2</em>...<br />-------------------------------------<br /></p>58 <p id="sout">starting <em>JSplash Player 0.4.13</em>...<br />-------------------------------------<br /></p> 59 59 <svg id="svgrt" xmlns="http://www.w3.org/2000/svg" style="width: 100px; height: 100px;"> 60 60 </svg>

