Closed
Bug 798235
Opened 13 years ago
Closed 13 years ago
"Assertion failure: aCoord.IsCoordPercentCalcUnit()" with flexbox
Categories
(Core :: Layout, defect)
Core
Layout
Tracking
()
RESOLVED
FIXED
mozilla19
People
(Reporter: jruderman, Assigned: dholbert)
References
Details
(Keywords: assertion, testcase)
Attachments
(3 files)
With
user_pref("layout.css.flexbox.enabled", true);
the testcase triggers:
Assertion failure: aCoord.IsCoordPercentCalcUnit(), at layout/base/nsLayoutUtils.h:944
| Reporter | ||
Comment 1•13 years ago
|
||
| Assignee | ||
Comment 2•13 years ago
|
||
So this is from a case where we're using "flex-basis" in place of "height" (in a vertical flexbox), and "flex-basis" happens to be set to a special keyword -- -moz-max-content -- which is supported for "width" but not for "height".
I think it makes the most sense to treat these special keywords as if they were "auto", which (for flex-basis in a vertical flexbox) means "just use the value of the 'height' property"
Assignee: nobody → dholbert
OS: Mac OS X → All
Hardware: x86_64 → All
| Assignee | ||
Comment 3•13 years ago
|
||
Here's the fix.
NOTE: After this patch, the code has this structure:
if (horizontal) {
// use flex basis for width
} else {
// comments
if (not enum) {
// use flex basis for height
}
}
That "else { ... if() {" could be collapsed to "else if () {, but I think I like it better with the "if" separated because the if-check is really just to filter out a special-case, and we're ultimately expecting to remove that check.
Happy to collapse it if you prefer, though.
Attachment #668963 -
Flags: review?(dbaron)
| Assignee | ||
Updated•13 years ago
|
Depends on: css3-flexbox
Comment on attachment 668963 [details] [diff] [review]
fix
r=dbaron
Attachment #668963 -
Flags: review?(dbaron) → review+
| Assignee | ||
Comment 5•13 years ago
|
||
Unprefixed testcase (per bug 801098), and pushed:
https://hg.mozilla.org/integration/mozilla-inbound/rev/5c67076a5a05
Flags: in-testsuite+
Comment 6•13 years ago
|
||
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla19
You need to log in
before you can comment on or make changes to this bug.
Description
•