[mapguide-commits] r8316 - in branches/2.6/MgDev: . Web/src/mapviewernet Web/src/viewerfiles

svn_mapguide at osgeo.org svn_mapguide at osgeo.org
Fri Aug 1 09:52:13 PDT 2014


Author: jng
Date: 2014-08-01 09:52:13 -0700 (Fri, 01 Aug 2014)
New Revision: 8316

Modified:
   branches/2.6/MgDev/
   branches/2.6/MgDev/Web/src/mapviewernet/mapframe.aspx
   branches/2.6/MgDev/Web/src/viewerfiles/
   branches/2.6/MgDev/Web/src/viewerfiles/ajaxmappane.templ
   branches/2.6/MgDev/Web/src/viewerfiles/browserdetect.js
Log:
Merged revision(s) 8313 from trunk/MgDev:
#2474: Ajax viewer: support IE10. Submit on behalf of Andy Zhang.

Some functionalities of Ajax viewer don't work well in IE10. The main reason is that element.Text is replaced by element.TextContent? in IE10. We need to change our code accordingly. 
........



Property changes on: branches/2.6/MgDev
___________________________________________________________________
Modified: svn:mergeinfo
   - /branches/2.4/MgDev:6749-6756,6777-6783,6785-6787,6789,6791-6794,6796-6801,6954-6962,6986-7006
/sandbox/jng/createruntimemap:7486-7555
/sandbox/rfc94:5099-5163
/trunk/MgDev:8209-8210,8230
   + /branches/2.4/MgDev:6749-6756,6777-6783,6785-6787,6789,6791-6794,6796-6801,6954-6962,6986-7006
/sandbox/jng/createruntimemap:7486-7555
/sandbox/rfc94:5099-5163
/trunk/MgDev:8209-8210,8230,8313

Modified: branches/2.6/MgDev/Web/src/mapviewernet/mapframe.aspx
===================================================================
--- branches/2.6/MgDev/Web/src/mapviewernet/mapframe.aspx	2014-08-01 15:07:44 UTC (rev 8315)
+++ branches/2.6/MgDev/Web/src/mapviewernet/mapframe.aspx	2014-08-01 16:52:13 UTC (rev 8316)
@@ -47,7 +47,7 @@
     MgLocalizer.SetLocalizedFilesPath(Request.ServerVariables["APPL_PHYSICAL_PATH"] + "..\\localized\\");
 
     infoWidth = showLegend = showProperties = 0;
-    hlTgt = hlTgtName = locale = mapDefinition = sessionId = type = "";
+    hlTgt = hlTgtName = locale = mapDefinition = sessionId = "";
 
     GetRequestParameters();
     String mapRequest = "";


Property changes on: branches/2.6/MgDev/Web/src/viewerfiles
___________________________________________________________________
Modified: svn:mergeinfo
   - /branches/2.4/MgDev/Web/src/viewerfiles:6738-6741,6749-6756,6777-6783,6785-6787,6789,6791-6794,6796-6801,6954-6962,6986-7006
/sandbox/adsk/2.2gp/Web/src/viewerfiles:5392
/sandbox/jng/createruntimemap/Web/src/viewerfiles:7486-7555
   + /branches/2.4/MgDev/Web/src/viewerfiles:6738-6741,6749-6756,6777-6783,6785-6787,6789,6791-6794,6796-6801,6954-6962,6986-7006
/sandbox/adsk/2.2gp/Web/src/viewerfiles:5392
/sandbox/jng/createruntimemap/Web/src/viewerfiles:7486-7555
/trunk/MgDev/Web/src/viewerfiles:8313

Modified: branches/2.6/MgDev/Web/src/viewerfiles/ajaxmappane.templ
===================================================================
--- branches/2.6/MgDev/Web/src/viewerfiles/ajaxmappane.templ	2014-08-01 15:07:44 UTC (rev 8315)
+++ branches/2.6/MgDev/Web/src/viewerfiles/ajaxmappane.templ	2014-08-01 16:52:13 UTC (rev 8316)
@@ -3165,8 +3165,8 @@
             var cntEls = xmlIn.getElementsByTagName("Content");
             var bDataUriSupport = (msie8plus || !msie);
             if (bDataUriSupport && mtEls.length == 1 && cntEls.length == 1) {
-                var mt = msie ? mtEls[0].text : mtEls[0].textContent;
-                var cnt = msie ? cntEls[0].text : cntEls[0].textContent;
+                var mt = (msie && !msie10plus) ? mtEls[0].text : mtEls[0].textContent;
+                var cnt = (msie && !msie10plus) ? cntEls[0].text : cntEls[0].textContent;
                 var dataUri = "data:" + mt + ";base64," + cnt;
                 PutSelectionImageUrl(++ selMapId, dataUri);
             } else {
@@ -4206,7 +4206,7 @@
             var feat = { values: [] };
             var featEl = featEls[j];
             var bounds = featEl.getElementsByTagName("Bounds")[0];
-            var bbox = (msie ? bounds.text : bounds.textContent).split(" ");
+            var bbox = ((msie && !msie10plus) ? bounds.text : bounds.textContent).split(" ");
             feat.zoom = { minx: parseFloat(bbox[0]), miny: parseFloat(bbox[1]), maxx: parseFloat(bbox[2]), maxy: parseFloat(bbox[3]) };
             
             var propEls = featEl.getElementsByTagName("Property");
@@ -4215,10 +4215,10 @@
                 var nameEl = propEls[k].getElementsByTagName("Name")[0];
                 var valueEl = propEls[k].getElementsByTagName("Value");
                 //Name,Value
-                var name = msie ? nameEl.text : nameEl.textContent;
+                var name = (msie && !msie10plus) ? nameEl.text : nameEl.textContent;
                 var value = null;
                 if (valueEl.length == 1)
-                    value = msie ? valueEl[0].text : valueEl[0].textContent;
+                    value = (msie && !msie10plus) ? valueEl[0].text : valueEl[0].textContent;
                 feat.values.push({ name: name, value: value });
             }
             featuresByLayer[layerName].push(feat);

Modified: branches/2.6/MgDev/Web/src/viewerfiles/browserdetect.js
===================================================================
--- branches/2.6/MgDev/Web/src/viewerfiles/browserdetect.js	2014-08-01 15:07:44 UTC (rev 8315)
+++ branches/2.6/MgDev/Web/src/viewerfiles/browserdetect.js	2014-08-01 16:52:13 UTC (rev 8316)
@@ -29,6 +29,7 @@
 var msie7plus = false;
 var msie8plus = false;
 var msie6minus = false;
+var msie10plus = false;
 if(msieIndex != -1)
 {
     msie = true;
@@ -39,11 +40,17 @@
         msie7plus = true;
         msie8plus = false;
     }
-    else if (parseFloat(msieVersion) >= 8)
+    else if (parseFloat(msieVersion) >= 8 &&(parseFloat(msieVersion)) < 10)
     {
         msie7plus = true;
         msie8plus = true;
     }
+    else if (parseFloat(msieVersion) >= 10)
+    {
+        msie7plus = true;
+        msie8plus = true;
+        msie10plus = true;
+    }
     else
     {
         msie6minus = true;



More information about the mapguide-commits mailing list