[OpenLayers-Users] CloudAmber drop shadow

Fred warnock fred.warnock at gmail.com
Mon Apr 28 10:00:45 EDT 2008


Good morning,

Last week Bill Bronsema and I updated to the latest version and found 
that the drop shadow was no longer part of the out-of-the-box CloudAmber 
popup.  So we made a 24 bit PNG that was close to the old style and 
tweaked the positioning and sizing numbers to handle the drop shadows.

Attached is the adjusted FramedCloud.js and 24bit PNG.

We were poking the numbers with a stick to try and figure out what the 
numbers did, and although we got it to work, I'm not sure the values are 
as neat as they could be.

Note also that we added a PNG hack so that the images would work in 
versions of IE older than 7.  The hack starts at line 274 in Framed.js:

             var imageCreator =
                 (this.isAlphaImage) ? OpenLayers.Util.createAlphaImageDiv
                                     : OpenLayers.Util.createImage;

             block.image = imageCreator(imgId,
                 null, this.imageSize, this.imageSrc,
                 "absolute", null, null, null
             );

             // apply png24 hack
             block.image.className = 'png24';

             block.div.appendChild(block.image);
             this.groupDiv.appendChild(block.div);



Specific fix is on line 284:

block.image.className = 'png24';

All the best,
Fred

-- 
___________________________________________

     Fred Warnock
     Senior Designer, Software
     DM Solutions Group Inc.
     http://www.dmsolutions.ca
-------------- next part --------------
A non-text attachment was scrubbed...
Name: FramedCloud.zip
Type: application/x-zip-compressed
Size: 1566 bytes
Desc: not available
Url : http://lists.osgeo.org/pipermail/openlayers-users/attachments/20080428/aa0609cf/FramedCloud.bin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: cloud-popup-relative-24.png
Type: image/png
Size: 12261 bytes
Desc: not available
Url : http://lists.osgeo.org/pipermail/openlayers-users/attachments/20080428/aa0609cf/cloud-popup-relative-24.png


More information about the Users mailing list