Changeset 7299
- Timestamp:
- 05/31/08 13:11:24 (3 months ago)
- Files:
-
- trunk/openlayers/lib/OpenLayers/Util.js (modified) (1 diff)
- trunk/openlayers/tests/Util.html (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/openlayers/lib/OpenLayers/Util.js
r7014 r7299 428 428 429 429 if (OpenLayers.Util.alphaHack()) { 430 431 div.style.display = "inline-block"; 430 if(div.style.display != "none") { 431 div.style.display = "inline-block"; 432 } 432 433 if (sizing == null) { 433 434 sizing = "scale"; trunk/openlayers/tests/Util.html
r6724 r7299 401 401 402 402 function test_Util_modifyAlphaImageDiv(t) { 403 t.plan( 19);403 t.plan( 20 ); 404 404 405 405 var imageDiv = OpenLayers.Util.createAlphaImageDiv(); … … 461 461 if (OpenLayers.Util.alphaHack()) { 462 462 463 t.eq(imageDiv.style.display, "inline-block", "imageDiv.style.display set correctly");464 465 463 var filter = "progid:DXImageTransform.Microsoft" + 466 464 ".AlphaImageLoader(src='" + img + "', " + … … 476 474 t.ok(true, "image filter value not set (not in IE)"); 477 475 } 476 477 var imageDiv = OpenLayers.Util.createAlphaImageDiv(); 478 var display = "none"; 479 imageDiv.style.display = display; 480 OpenLayers.Util.modifyAlphaImageDiv(imageDiv, id, xy, sz, img, position, border, sizing, opacity); 481 t.eq(imageDiv.style.display, display, "imageDiv.style.display set correctly, if 'none'"); 482 483 var imageDiv = OpenLayers.Util.createAlphaImageDiv(); 484 var display = "block"; 485 imageDiv.style.display = display; 486 OpenLayers.Util.modifyAlphaImageDiv(imageDiv, id, xy, sz, img, position, border, sizing, opacity); 487 t.eq(imageDiv.style.display, "inline-block", "imageDiv.style.display set correctly, if not 'none'"); 488 489 478 490 479 491 var imageDiv = OpenLayers.Util.createAlphaImageDiv(id, xy, sz, img, position, border, "scale", opacity);
