Not approved.
You should use LzColorUtils.colorfrominternal and alphafrominternal rather than
hard-coding the tests. I would say the logic should be more like:
if (!this.capabilities.rgba) {
switch (LzColorUtils.alphafrominternal(c)) {
case 0:
c = null;
break;
default:
if ($debug) {
Debug.warn("Alpha color %s not supported: check capabilities.",
LzColorUtils.rgbafrominternal(c));
}
// fall through
case 1:
c = LzColorUtils.colorfrominternal(c);
break;
}
}
On 2010-11-29, at 20:03, Max Carlson wrote:
> Change maxcarlson-20101129-JGB by [email protected] on 2010-11-29
> 16:59:35 PST
> in /Users/maxcarlson/openlaszlo/trunk-clean
> for http://svn.openlaszlo.org/openlaszlo/trunk
>
> Summary: Explicitly handle transparent color values from the compiler,
> correctly strip alpha from colors when rgba isn't supported
>
> Bugs Fixed: LPP-9547 - Got IE browser error "Invalid property value " at
> LFCdhtml.js
>
> Technical Reviewer: ptw
> QA Reviewer: yfeng
>
> Details: The summary sez it all...
>
> Tests: See LPP-9547
>
> Files:
> M WEB-INF/lps/lfc/kernel/dhtml/LzSprite.js
>
> Changeset:
> http://svn.openlaszlo.org/openlaszlo/patches/maxcarlson-20101129-JGB.tar