Bug 12345 - REGRESSION: Disabled pop-up text is not grayed out
Summary: REGRESSION: Disabled pop-up text is not grayed out
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Forms (show other bugs)
Version: 420+
Hardware: Mac OS X 10.4
: P1 Normal
Assignee: Nobody
URL: data:text/html,%3Cselect%20disabled%3...
Keywords: Regression
Depends on:
Blocks:
 
Reported: 2007-01-20 05:08 PST by mitz
Modified: 2010-03-25 00:52 PDT (History)
2 users (show)

See Also:


Attachments
Use gray for disabled pop-ups (31.29 KB, patch)
2007-01-20 07:33 PST, mitz
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description mitz 2007-01-20 05:08:43 PST
Mac-themed pop-ups that are disabled use black text for the selected item instead of gray.
Comment 1 mitz 2007-01-20 07:33:50 PST
Created attachment 12572 [details]
Use gray for disabled pop-ups

I added the casts to RGBA32 to appease the compiler, which otherwise regarded the colors as external symbols, leading to a link error. I couldn't figure out what the problem was. The following worked:
e->isEnabled() ? Color::black : 0
e->isEnabled() ? 0 : Color::darkGray
but this didn't work:
e->isEnabled() ? Color::black : Color::darkGray
Comment 2 David Kilzer (:ddkilzer) 2007-01-20 16:16:31 PST
(In reply to comment #1)
> I added the casts to RGBA32 to appease the compiler, which otherwise regarded
> the colors as external symbols, leading to a link error. I couldn't figure out
> what the problem was. The following worked:
> e->isEnabled() ? Color::black : 0
> e->isEnabled() ? 0 : Color::darkGray
> but this didn't work:
> e->isEnabled() ? Color::black : Color::darkGray

Weird.  Did you try adding parenthesis?  Sounds like a toolchain bug.
Comment 3 mitz 2007-01-20 22:31:47 PST
(In reply to comment #2)
> Weird.  Did you try adding parenthesis?

Yeah, forgot to mention it.
Comment 4 Sam Weinig 2007-01-21 15:57:05 PST
Mitz,

Is there a reason that this is not marked for a review?  Also, could you please use static_cast.
Comment 5 Darin Adler 2007-01-21 17:42:24 PST
I filed an internal Apple gcc bug report with a reduced test case:

<rdar://problem/4944665> can't compile example using initialized static const and ternary operator
Comment 6 Darin Adler 2007-01-21 17:49:30 PST
I realized that it's not really a compiler bug, so I retitled that internal bug report.
Comment 7 Darin Adler 2007-01-21 17:51:22 PST
Committed revision 19020.
Comment 8 Adam Barth 2010-03-25 00:09:36 PDT
Committed r56503: <http://trac.webkit.org/changeset/56503>
Comment 9 Adam Barth 2010-03-25 00:52:27 PDT
Committed r56508: <http://trac.webkit.org/changeset/56508>