Last Comment Bug 336726 - XUL: Non-relevant controls should not be shown
: XUL: Non-relevant controls should not be shown
Status: RESOLVED FIXED
: fixed1.8.0.5, fixed1.8.1
Product: Core Graveyard
Classification: Graveyard
Component: XForms (show other bugs)
: Trunk
: All All
: -- normal (vote)
: ---
Assigned To: alexander :surkov
: Stephen Pride
Mentors:
http://www.w3.org/TR/xforms/
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2006-05-05 05:16 PDT by Allan Beaufour
Modified: 2016-07-15 14:46 PDT (History)
3 users (show)
See Also:
QA Whiteboard:
Iteration: ---
Points: ---


Attachments
Testcase (691 bytes, application/vnd.mozilla.xul+xml)
2006-05-05 05:16 PDT, Allan Beaufour
no flags Details
patch (471 bytes, patch)
2006-05-05 20:12 PDT, alexander :surkov
allan: review-
Details | Diff | Splinter Review
patch2 (1.31 KB, patch)
2006-05-10 01:29 PDT, alexander :surkov
allan: review+
bugs: review+
Details | Diff | Splinter Review

Description Allan Beaufour 2006-05-05 05:16:20 PDT
Controls bound to non-relevant nodes should not be shown per default (like for XHTML).
Comment 1 Allan Beaufour 2006-05-05 05:16:49 PDT
Created attachment 220912 [details]
Testcase
Comment 2 alexander :surkov 2006-05-05 20:12:18 PDT
Created attachment 221041 [details] [diff] [review]
patch

It's pretty simple patch but I don't like a lot !important flag. The problem is style for :disabled is applied before other styles. !important solves the problem but is it right?
Comment 3 Allan Beaufour 2006-05-09 04:59:57 PDT
Comment on attachment 221041 [details] [diff] [review]
patch

(In reply to comment #2)
> Created an attachment (id=221041) [edit]
> patch
> 
> It's pretty simple patch but I don't like a lot !important flag. The problem is
> style for :disabled is applied before other styles. !important solves the
> problem but is it right?

No, because then it cannot be overriden by the form author.
Comment 4 alexander :surkov 2006-05-10 01:29:05 PDT
(In reply to comment #3)
> (From update of attachment 221041 [details] [diff] [review] [edit])
> (In reply to comment #2)
> > Created an attachment (id=221041) [edit]
> > patch
> > 
> > It's pretty simple patch but I don't like a lot !important flag. The problem is
> > style for :disabled is applied before other styles. !important solves the
> > problem but is it right?
> 
> No, because then it cannot be overriden by the form author.
> 

Not quite, it can override by using '!important' flag :)

How about the such approach?
Comment 5 alexander :surkov 2006-05-10 01:29:30 PDT
Created attachment 221560 [details] [diff] [review]
patch2
Comment 6 Allan Beaufour 2006-05-10 01:47:09 PDT
(In reply to comment #4)
> (In reply to comment #3)
> > (From update of attachment 221041 [details] [diff] [review] [edit] [edit])
> > (In reply to comment #2)
> > > Created an attachment (id=221041) [edit]
> > > patch
> > > 
> > > It's pretty simple patch but I don't like a lot !important flag. The problem is
> > > style for :disabled is applied before other styles. !important solves the
> > > problem but is it right?
> > 
> > No, because then it cannot be overriden by the form author.
> > 
> 
> Not quite, it can override by using '!important' flag :)

No, because I tbelieve that our agent style sheet is a "user stylesheet":
"Both author and user style sheets may contain "!important" declarations, and user "!important" rules override author "!important" rules."
[http://www.w3.org/TR/REC-CSS2/cascade.html#important-rules]
Comment 7 Allan Beaufour 2006-05-11 08:27:12 PDT
Comment on attachment 221560 [details] [diff] [review]
patch2

I'm not sure I like the approach, but it's css styling. Off we go :)

r=me
Comment 8 Allan Beaufour 2006-05-12 01:15:38 PDT
Fixed on trunk

Note You need to log in before you can comment on or make changes to this bug.