fix opacity tests in IE10 (see #948)
This commit is contained in:
+1
-2
@@ -168,8 +168,7 @@
|
|||||||
var bColor = popup.div.style.backgroundColor;
|
var bColor = popup.div.style.backgroundColor;
|
||||||
var goodColor = ( (bColor == color) || (bColor == hexColor));
|
var goodColor = ( (bColor == color) || (bColor == hexColor));
|
||||||
t.ok(goodColor, "good default popup.backgroundColor");
|
t.ok(goodColor, "good default popup.backgroundColor");
|
||||||
|
if (navigator.appName.indexOf("Microsoft") == -1 || new RegExp(/msie 10/).test(navigator.userAgent.toLowerCase())) {
|
||||||
if (navigator.appName.indexOf("Microsoft") == -1) {
|
|
||||||
t.eq(parseFloat(popup.div.style.opacity), opacity, "good default popup.opacity");
|
t.eq(parseFloat(popup.div.style.opacity), opacity, "good default popup.opacity");
|
||||||
} else {
|
} else {
|
||||||
t.eq(popup.div.style.filter, "alpha(opacity=" + opacity*100 + ")", "good default popup.opacity");
|
t.eq(popup.div.style.filter, "alpha(opacity=" + opacity*100 + ")", "good default popup.opacity");
|
||||||
|
|||||||
@@ -32,7 +32,7 @@
|
|||||||
popup.setOpacity(opacity);
|
popup.setOpacity(opacity);
|
||||||
popup.draw(new OpenLayers.Pixel(x, y));
|
popup.draw(new OpenLayers.Pixel(x, y));
|
||||||
|
|
||||||
if (navigator.appName.indexOf("Microsoft") == -1) {
|
if (navigator.appName.indexOf("Microsoft") == -1 || new RegExp(/msie 10/).test(navigator.userAgent.toLowerCase())) {
|
||||||
t.eq(parseFloat(popup.div.style.opacity), opacity, "good default popup.opacity");
|
t.eq(parseFloat(popup.div.style.opacity), opacity, "good default popup.opacity");
|
||||||
} else {
|
} else {
|
||||||
t.eq(popup.div.style.filter, "alpha(opacity=" + opacity*100 + ")", "good default popup.opacity");
|
t.eq(popup.div.style.filter, "alpha(opacity=" + opacity*100 + ")", "good default popup.opacity");
|
||||||
@@ -43,7 +43,7 @@
|
|||||||
t.ok(popup.groupDiv.parentNode.getElementsByTagName("span").length > 0, "popup.groupDiv.parentNode has SPAN children");
|
t.ok(popup.groupDiv.parentNode.getElementsByTagName("span").length > 0, "popup.groupDiv.parentNode has SPAN children");
|
||||||
|
|
||||||
var ricoCornerDiv = popup.groupDiv.parentNode.getElementsByTagName("span")[0];
|
var ricoCornerDiv = popup.groupDiv.parentNode.getElementsByTagName("span")[0];
|
||||||
if (navigator.appName.indexOf("Microsoft") == -1) {
|
if (navigator.appName.indexOf("Microsoft") == -1 || new RegExp(/msie 10/).test(navigator.userAgent.toLowerCase())) {
|
||||||
t.eq(parseFloat(ricoCornerDiv.style.opacity), opacity, "good default ricoCornerDiv.opacity");
|
t.eq(parseFloat(ricoCornerDiv.style.opacity), opacity, "good default ricoCornerDiv.opacity");
|
||||||
} else {
|
} else {
|
||||||
t.eq(ricoCornerDiv.style.filter, "alpha(opacity=" + opacity*100 + ")", "good default ricoCornerDiv.opacity");
|
t.eq(ricoCornerDiv.style.filter, "alpha(opacity=" + opacity*100 + ")", "good default ricoCornerDiv.opacity");
|
||||||
|
|||||||
Reference in New Issue
Block a user