Closed
Bug 1364115
Opened 8 years ago
Closed 8 years ago
Allow -moz-stack-sizing to work in a single direction only
Categories
(Core :: XUL, defect)
Core
XUL
Tracking
()
RESOLVED
FIXED
mozilla55
Tracking | Status | |
---|---|---|
firefox55 | --- | fixed |
People
(Reporter: Paolo, Assigned: enndeakin)
References
Details
(Keywords: dev-doc-needed)
Attachments
(1 file)
Allowing -moz-stack-sizing to work in a single direction only will simplify the layout of panelmultiview.
I'm carrying over Neil's patch from bug 1293242 and adding tests.
Reporter | ||
Updated•8 years ago
|
Comment hidden (mozreview-request) |
Reporter | ||
Comment 2•8 years ago
|
||
At first (very quick) glance I think this mostly looks good, with the caveats that:
(1) you should be adding new values to layout/style/test/property_database.js
(2) at this point in the stylo project, new properties need to be implemented in both the Gecko and Servo style systems so that they work in both. A bunch of people on #layout or #servo could provide advice.
Flags: needinfo?(paolo.mozmail)
Reporter | ||
Comment 4•8 years ago
|
||
(In reply to David Baron :dbaron: ⌚️UTC-7 from comment #3)
> (2) at this point in the stylo project, new properties need to be
> implemented in both the Gecko and Servo style systems so that they work in
> both. A bunch of people on #layout or #servo could provide advice.
Is this true of properties used in XUL layout too?
Flags: needinfo?(paolo.mozmail) → needinfo?(dbaron)
Comment hidden (mozreview-request) |
Reporter | ||
Comment 6•8 years ago
|
||
When running layout/style/test locally some seemingly unrelated tests failed, so let's see what automation says about the property_database.js changes:
https://treeherder.mozilla.org/#/jobs?repo=try&revision=9426f58c5115e827cc0ab167b048e542d8b463e0
Reporter | ||
Comment 7•8 years ago
|
||
Ah, I've seen "error: no field `mStretchStack` on type `gecko_bindings::structs::root::nsStyleXUL`" in the tryserver build.
Flags: needinfo?(dbaron) → needinfo?(paolo.mozmail)
Comment hidden (mozreview-request) |
Reporter | ||
Comment 9•8 years ago
|
||
I guess this is all there is to do as the property is only parsed and not implemented in Stylo, let me know if there is anything else to do, or if I should ask review to someone else for the Stylo parts. If I understand correctly, once this is reviewed in Bugzilla it needs a special landing process.
https://treeherder.mozilla.org/#/jobs?repo=try&revision=39d3f87ffadf42aceae4d38689a5ac0258acd713
Flags: needinfo?(paolo.mozmail) → needinfo?(dbaron)
Reporter | ||
Comment 10•8 years ago
|
||
There is a devtools test to fix, but Stylo builds and passes tests.
Comment 11•8 years ago
|
||
mozreview-review |
Comment on attachment 8866842 [details]
Bug 1364115 - Allow -moz-stack-sizing to work in a single direction only.
https://reviewboard.mozilla.org/r/138434/#review142278
r=dbaron with the following comments, but you should ask someone else (SimonSapin? Manish?) to review the stylo bits.
::: layout/style/nsStyleConsts.h:233
(Diff revision 3)
> // stack-sizing
> #define NS_STYLE_STACK_SIZING_IGNORE 0
> #define NS_STYLE_STACK_SIZING_STRETCH_TO_FIT 1
> +#define NS_STYLE_STACK_SIZING_IGNORE_HORIZONTAL 2
> +#define NS_STYLE_STACK_SIZING_IGNORE_VERTICAL 3
These should be removed now that you have an enum instead. You'll need to switch to the enum values in a few other places as well.
::: layout/xul/nsStackLayout.cpp:68
(Diff revision 3)
> {
> nsSize prefSize (0, 0);
>
> nsIFrame* child = nsBox::GetChildXULBox(aBox);
> while (child) {
> - if (child->StyleXUL()->mStretchStack) {
> + if (child->StyleXUL()->mStackSizing != StyleStackSizing::Ignore) {
In all 4 of these functions, please use:
auto stackSizing = child->StyleXUL()->mStackSizing;
so you don't call StyleXUL() three times (in each function) when you could call it once.
Attachment #8866842 -
Flags: review?(dbaron) → review+
Adding dev-doc-needed to document the new ignore-horizontal and ignore-vertical values of this property.
(And yes, see above, somebody else should review the stylo bits.)
Flags: needinfo?(dbaron)
Keywords: dev-doc-needed
Comment hidden (mozreview-request) |
Reporter | ||
Comment 14•8 years ago
|
||
Comment 15•8 years ago
|
||
mozreview-review |
Comment on attachment 8866842 [details]
Bug 1364115 - Allow -moz-stack-sizing to work in a single direction only.
https://reviewboard.mozilla.org/r/138434/#review142614
Attachment #8866842 -
Flags: review+
Comment 16•8 years ago
|
||
mozreview-review |
Comment on attachment 8866842 [details]
Bug 1364115 - Allow -moz-stack-sizing to work in a single direction only.
https://reviewboard.mozilla.org/r/138434/#review143004
Deferring to Manish’s review.
Attachment #8866842 -
Flags: review?(simon.sapin)
Comment hidden (mozreview-request) |
Reporter | ||
Comment 18•8 years ago
|
||
Comment 19•8 years ago
|
||
Pushed by manishearth@gmail.com:
https://hg.mozilla.org/integration/autoland/rev/c1ca4c3d5273
Allow -moz-stack-sizing to work in a single direction only. r=dbaron,manishearth
Comment 20•8 years ago
|
||
bugherder |
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
status-firefox55:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla55
You need to log in
before you can comment on or make changes to this bug.
Description
•