Open Bug 1435658 Opened 6 years ago Updated 8 months ago

radio/checkbox widget don't resize to the default size from changing appearance none to its default appearance

Categories

(Core :: CSS Parsing and Computation, defect, P3)

60 Branch
defect

Tracking

()

Tracking Status
firefox60 --- unaffected

People

(Reporter: karlcow, Assigned: emilio, NeedInfo)

References

Details

(Keywords: regression)

Attachments

(2 files)

On top the reference test case. (working) 
   data:text/html,<input type="radio">
   The widget is 13x13 pixels (on macOS)


The second window. Here the steps to reproduce.

1. Start with 
   data:text/html,<input type="radio" style="-moz-appearance: none;">
2. open the devtools
3. select input
4. Change the value of "-moz-appearance" 
   from "none" 
   to   "radio"

The widget is 4x4 pixels.

It should be back to the default.

(Screenshot shows values with "!important", but this is not necessary to reproduce the issue. This is a spin-off of Bug 1434298 )


Testing other values:

Same thing with
data:text/html,<input type="checkbox" style="-moz-appearance: none;">
I can reproduce the problem on Linux too, but I get an 18x0 size
when removing the -moz-appearance:none.

However, if I start with data:text/html,<input type="radio">
and then add -moz-appearance:none in devtools and toggle that
declaration it works as expected, toggling between 18x18 and 0x0.

I'm guessing we don't re-create the frame as we should when
changing -moz-appearance between radio/checkbox and none.
I suspect this is now necessary because of bug 605985.
Blocks: 605985
Component: Layout: Form Controls → CSS Parsing and Computation
Keywords: regression
Emilio, is the C++ code still used to calculate change hints?
If so, then I think we could add something similar to this:
https://searchfox.org/mozilla-central/rev/e06af9c36a73a27864302cd2f829e6200dee8541/layout/style/nsStyleStruct.cpp#3779
Flags: needinfo?(emilio)
Yes, it is. That looks fine to me, want me to write the patch?
Flags: needinfo?(emilio)
Sure, if you feel you have the time.  Otherwise, I'll get to it eventually.
Okie dookie, shouldn't take too much time.
Assignee: nobody → emilio
Comment on attachment 8948372 [details]
Bug 1435658: Deal with appearance changes from / to none correctly.

https://reviewboard.mozilla.org/r/217838/#review223618

Thanks!
Attachment #8948372 - Flags: review?(mats) → review+
Pushed by ecoal95@gmail.com:
https://hg.mozilla.org/integration/autoland/rev/c074e2c4b2ed
Deal with appearance changes from / to none correctly. r=mats
For more fun, I can't repro them locally...
The failing test used to be intermittent (bug 1207914) so maybe that
has something to do with it?  I'd say that if the original STR in
bug 632379 can't be reproduced with this patch then we should reland
it and disable the test instead.  Clearly it's dependent on a reflow
happening/not happening which seems flaky anyway.
Hmm, so just pushed on top of something that isn't that mess of yesterday's trees.

There are a bunch of accessibility tests failing, and a couple of others, most of which are marked as intermittent...  I suspect we don't want to disable all of them, so I'll try to figure out what's up with them tomorrow, hopefully at least one repros...

  https://treeherder.mozilla.org/#/jobs?repo=try&revision=06e547ff3ef1473de47865cc7391d81e9731f9a1
Flags: needinfo?(emilio)
Any more progress on this patch?
Flags: needinfo?(emilio)
(In reply to Milan Sreckovic [:milan] from comment #13)
> Any more progress on this patch?

It's on my list of things to do, need to take time for it though.
[ Triage 2017/02/20: P3 ]
Priority: -- → P3
Will this make 60? It's a new regression in that release, it'd be good if we didn't ship it, then fix it later, since 60 is ESR.
Flags: needinfo?(bugs)
(In reply to Milan Sreckovic [:milan] from comment #16)
> Will this make 60? It's a new regression in that release

Bug 605985 was fixed in FF54, what landed in 60 to cause the new regression?
Sounds like this doesn't affect 60.  Marking as such.
Flags: needinfo?(bugs)
(I never got around to fix the tests, but Jwatt is looking at appearance and may come through these)
Jonathan, any chance that you could take a look at this while you're looking at appearance? It was mostly bogus tests IIRC.
Flags: needinfo?(emilio) → needinfo?(jwatt)
Blocks: 1483787
Severity: normal → S3

I am still able to reproduce this with 118.0b2.

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

Attachment

General

Created:
Updated:
Size: