Browse Source

try to fix player in IE11

Maxim Sokhatsky 10 years ago
parent
commit
01547ebf61

+ 7 - 7
apps/web/priv/static/app/Kakaranet-Scene.svg

@@ -88,7 +88,7 @@
                 <path d="M130.399,-0.41 L85.075,-0.41 L9.835,-0.41 L4.197,-0.41 C1.988,-0.41 0.197,1.381 0.197,3.59 L0.197,31.923 C0.197,34.132 1.988,35.923 4.197,35.923 L10.195,35.923 L84.716,35.923 L130.4,35.923 C132.609,35.923 134.4,34.132 134.4,31.923 L134.4,3.59 C134.399,1.381 132.608,-0.41 130.399,-0.41 L130.399,-0.41 L130.399,-0.41 Z" id="Shape" fill="#3B5998" sketch:type="MSShapeGroup"></path>
                 <path d="M119.525,10.542 L123.24,10.542 L123.24,5.668 L119.136,5.668 C115.722,5.668 113.337,8.44 113.337,12.537 L113.337,15.571 L108.384,15.571 L108.384,20.52 L113.337,20.52 L113.337,35.977 L118.287,35.977 L118.287,20.521 L123.238,20.521 L123.238,15.572 L118.287,15.572 L118.287,11.587 C118.289,10.775 119.1,10.542 119.525,10.542" id="Shape" fill="#FFFFFF" sketch:type="MSShapeGroup"></path>
                 <text id="Login-Text" fill="#FFFFFF" sketch:type="MSTextLayer" font-family="Exo 2" font-size="17" font-weight="normal" sketch:alignment="middle">
-                    <tspan x="34.0305" y="24">Login</tspan>
+                    <tspan x="31.0305" y="24">Login</tspan>
                 </text>
             </g>
             <g id="Online-Users" transform="translate(19.000000, 13.000000)">
@@ -128,13 +128,13 @@
             <rect id="Back-5" fill="#D6E8EA" sketch:type="MSShapeGroup" x="1" y="453" width="1070" height="150.848271"></rect>
             <path d="M2,660 L2,600.976 L851.979,600.976 L1072,600.976 L1072,660 L2,660 Z M452,617.976 L452,647.976 L500,647.976 L500,617.976 L452,617.976 Z" id="Back-4" fill="#A8CACC" sketch:type="MSShapeGroup"></path>
             <g id="Player-Center" transform="translate(445.000000, 90.000000)">
-                <g id="Name" transform="translate(42.000000, 0.000000)">
+                <g id="Player-Center-Display" transform="translate(42.000000, 0.000000)">
                     <rect id="Player-Center-Pad" fill="#517ECE" sketch:type="MSShapeGroup" x="0" y="0" width="145" height="38" rx="8"></rect>
                     <text id="Player-Center-Name" fill="#FFFFFF" sketch:type="MSTextLayer" font-family="Exo 2" font-size="24" font-weight="normal" sketch:alignment="middle">
                         <tspan x="29.732" y="26.7344">Mustafa</tspan>
                     </text>
                 </g>
-                <g id="Timer">
+                <g id="Player-Center-Timer">
                     <path d="M5.558,38 C2.492,38 0,35.504 0,32.436 L0,5.564 C0,2.496 2.492,0 5.558,0 L32.439,0 C35.505,0 38,2.496 38,5.564 L38,32.436 C38,35.504 35.505,38 32.439,38 L5.558,38 L5.558,38 Z" id="Timer-Pad" fill="#517ECE" sketch:type="MSShapeGroup"></path>
                     <rect id="progress" fill="#5CBF6F" sketch:type="MSShapeGroup" x="2" y="2" width="34" height="33" rx="3"></rect>
                     <text id="value" fill="#FFFFFF" sketch:type="MSTextLayer" font-family="Exo 2" font-size="20.7143027" font-weight="normal">
@@ -143,13 +143,13 @@
                 </g>
             </g>
             <g id="Player-Right" transform="translate(633.000000, 150.000000)">
-                <g id="Name" transform="translate(42.000000, 0.000000)">
+                <g id="Player-Right-Display" transform="translate(42.000000, 0.000000)">
                     <rect id="Player-Right-Pad" fill="#517ECE" sketch:type="MSShapeGroup" x="0" y="0" width="145" height="38" rx="8"></rect>
                     <text id="Player-Right-Name" fill="#FFFFFF" sketch:type="MSTextLayer" font-family="Exo 2" font-size="24" font-weight="normal" sketch:alignment="middle">
                         <tspan x="43.436" y="28.7344">Alina</tspan>
                     </text>
                 </g>
-                <g id="Timer">
+                <g id="Player-Right-Timer">
                     <path d="M5.558,38 C2.492,38 0,35.504 0,32.436 L0,5.564 C0,2.496 2.492,0 5.558,0 L32.439,0 C35.505,0 38,2.496 38,5.564 L38,32.436 C38,35.504 35.505,38 32.439,38 L5.558,38 L5.558,38 Z" id="Timer-Pad" fill="#517ECE" sketch:type="MSShapeGroup"></path>
                     <rect id="progress" fill="#5CBF6F" sketch:type="MSShapeGroup" x="2" y="2" width="34" height="33" rx="3"></rect>
                     <text id="value" fill="#FFFFFF" sketch:type="MSTextLayer" font-family="Exo 2" font-size="20.7143027" font-weight="normal">
@@ -158,13 +158,13 @@
                 </g>
             </g>
             <g id="Player-Left" transform="translate(229.000000, 150.000000)">
-                <g id="Name" transform="translate(42.000000, 0.000000)">
+                <g id="Player-Left-Display" transform="translate(42.000000, 0.000000)">
                     <rect id="Player-Left-Pad" fill="#517ECE" sketch:type="MSShapeGroup" x="0" y="0" width="145" height="38" rx="8"></rect>
                     <text id="Player-Left-Name" fill="#FFFFFF" sketch:type="MSTextLayer" font-family="Exo 2" font-size="24" font-weight="normal" sketch:alignment="middle">
                         <tspan x="24.924" y="27.1759033">Gabrielo</tspan>
                     </text>
                 </g>
-                <g id="Timer">
+                <g id="Player-Left-Timer">
                     <path d="M5.558,38 C2.492,38 0,35.504 0,32.436 L0,5.564 C0,2.496 2.492,0 5.558,0 L32.439,0 C35.505,0 38,2.496 38,5.564 L38,32.436 C38,35.504 35.505,38 32.439,38 L5.558,38 L5.558,38 Z" id="Timer-Pad" fill="#517ECE" sketch:type="MSShapeGroup"></path>
                     <rect id="progress" fill="#5CBF6F" sketch:type="MSShapeGroup" x="2" y="2" width="34" height="33" rx="3"></rect>
                     <text id="value" fill="#FFFFFF" sketch:type="MSTextLayer" font-family="Exo 2" font-size="20.7143027" font-weight="normal">

+ 4 - 4
apps/web/priv/static/app/SVG.txt

@@ -17,15 +17,15 @@
     2. foreignObject TextEditors for Chat
     -------------------------------------
 
-    <foreignObject id="GameChatEditor" x="864" y="504" width="198" height="120" onmouseover="barHover(evt);" onmouseout="barHoverOut(evt);">
+    <foreignObject id="GameChatEditor" x="864" y="504" width="196" height="120" onmouseover="barHover(evt);" onmouseout="barHoverOut(evt);">
         <div xmlns:data="Chat" id="edit" contentEditable="true"
-          style="padding:4px;background-color:#FFF687;color:#3B5998;font-family:'Exo 2';font-size:16px;"
+          style="min-height:21px;padding:4px;background-color:#FFF687;color:#3B5998;font-family:'Exo 2';font-size:16px;"
         xmlns="http://www.w3.org/1999/xhtml">Write here some text.</div>
     </foreignObject>
 
-    <foreignObject id="OnlineChatEditor" x="10" y="504" width="198" height="120" onmouseover="onlineHover(evt);" onmouseout="onlineHoverOut(evt);">
+    <foreignObject id="OnlineChatEditor" x="10" y="504" width="196" height="120" onmouseover="onlineHover(evt);" onmouseout="onlineHoverOut(evt);">
         <div xmlns:data="Chat+xxx" contentEditable="true" id="onlineChatEdit"
-          style="padding:4px;background-color:#FFF687;color:#3B5998;font-family:'Exo 2';font-size:16px;"
+          style="min-height:21px;padding:4px;background-color:#FFF687;color:#3B5998;font-family:'Exo 2';font-size:16px;"
          xmlns="http://www.w3.org/1999/xhtml">Write here some text.</div>
     </foreignObject>
 

+ 9 - 0
apps/web/priv/static/app/js/bootloader.js

@@ -147,6 +147,15 @@ function PatchSVG()
     document.addEventListener('touchmove',function(e) {e.preventDefault();},false);
     $svg.attr({preserveAspectRatio:"xMidYMid meet",width:"100%",height:"100%"});
 
+    $("#Player-Left").attr({transform:""});
+    $("#Player-Left-Timer").attr({transform:"translate(214, 151)"});
+    $("#Player-Left-Display").attr({transform:"translate(256, 151)"});
+    $("#Player-Right").attr({transform:""});
+    $("#Player-Right-Timer").attr({transform:"translate(628, 161)"});
+    $("#Player-Right-Display").attr({transform:"translate(670, 161)"});
+    $("#Player-Center").attr({transform:""});
+    $("#Player-Center-Timer").attr({transform:"translate(444, 92)"});
+    $("#Player-Center-Display").attr({transform:"translate(486, 92)"});
 }
 
 function sendSawOkey()

+ 2 - 2
apps/web/priv/static/app/js/player.js

@@ -36,12 +36,12 @@ function PlayerScope(scope) {
 
             var $result = $("<g/>").html(result);
             var element = $result[0].firstChild;
-            var xform = parseTransformAttribute(element.getAttribute("transform"));
+/*            var xform = parseTransformAttribute(element.getAttribute("transform"));
             var ori   = parseTransformAttribute(this.$el[0].getAttribute("transform"));
             var shift = "translate("+(-parseFloat(ori.translate[0])+parseFloat(xform.translate[0]))+","+
                                      (-parseFloat(ori.translate[1])+parseFloat(xform.translate[1]))+")";
             element.setAttribute("transform",shift);
-            this.$el.append(element);
+*/            this.$el.append(element);
             this.unselect(); },
 
         initTimer: function() {

BIN
apps/web/priv/static/doc/Kakaranet-Scene.sketch/Data


+ 1 - 1
apps/web/priv/static/doc/Kakaranet-Scene.sketch/metadata

@@ -16,7 +16,7 @@
 		<string>ZapfDingbatsITC</string>
 	</array>
 	<key>length</key>
-	<integer>3020140</integer>
+	<integer>3020774</integer>
 	<key>version</key>
 	<integer>37</integer>
 </dict>