We want to make sure that we only run the MSIE-specific filter tests if opacity is explicitly not supported.
This commit is contained in:
parent
73e4ef27f0
commit
8fb4d9af74
|
@ -138,14 +138,14 @@ test("css(String, Object)", function() {
|
||||||
ok( success, "Setting RGBA values does not throw Error" );
|
ok( success, "Setting RGBA values does not throw Error" );
|
||||||
});
|
});
|
||||||
|
|
||||||
if(jQuery.browser.msie) {
|
if ( !jQuery.support.opacity ) {
|
||||||
test("css(String, Object) for MSIE", function() {
|
test("css(String, Object) for MSIE", function() {
|
||||||
// for #1438, IE throws JS error when filter exists but doesn't have opacity in it
|
// for #1438, IE throws JS error when filter exists but doesn't have opacity in it
|
||||||
jQuery('#foo').css("filter", "progid:DXImageTransform.Microsoft.Chroma(color='red');");
|
jQuery('#foo').css("filter", "progid:DXImageTransform.Microsoft.Chroma(color='red');");
|
||||||
equals( jQuery('#foo').css('opacity'), '1', "Assert opacity is 1 when a different filter is set in IE, #1438" );
|
equals( jQuery('#foo').css('opacity'), '1', "Assert opacity is 1 when a different filter is set in IE, #1438" );
|
||||||
|
|
||||||
var filterVal = "progid:DXImageTransform.Microsoft.Alpha(opacity=30) progid:DXImageTransform.Microsoft.Blur(pixelradius=5)";
|
var filterVal = "progid:DXImageTransform.Microsoft.Alpha(opacity=30) progid:DXImageTransform.Microsoft.Blur(pixelradius=5)";
|
||||||
var filterVal2 = "progid:DXImageTransform.Microsoft.Alpha(opacity=100) progid:DXImageTransform.Microsoft.Blur(pixelradius=5)";
|
var filterVal2 = "progid:DXImageTransform.Microsoft.alpha(opacity=100) progid:DXImageTransform.Microsoft.Blur(pixelradius=5)";
|
||||||
var filterVal3 = "progid:DXImageTransform.Microsoft.Blur(pixelradius=5)";
|
var filterVal3 = "progid:DXImageTransform.Microsoft.Blur(pixelradius=5)";
|
||||||
jQuery('#foo').css("filter", filterVal);
|
jQuery('#foo').css("filter", filterVal);
|
||||||
equals( jQuery('#foo').css("filter"), filterVal, "css('filter', val) works" );
|
equals( jQuery('#foo').css("filter"), filterVal, "css('filter', val) works" );
|
||||||
|
|
Loading…
Reference in a new issue