Commit Graph

13249 Commits

Author SHA1 Message Date
Botond Ballo
6dbe1b9895 Bug 1321412 - Change the return type of ShouldPrerenderTransformedContent() to an enum. r=mattwoodrow
MozReview-Commit-ID: EMTdW46D8cM

--HG--
extra : rebase_source : 1ecd8fd39a1d3bc74200dbe4f53dd78eda57987e
2016-11-23 12:58:59 -05:00
Botond Ballo
8686329e65 Bug 1321412 - Feed the return value of ShouldPrerenderTransformedContent() directly into nsDisplayTransform::mAllowAsyncAnimation. r=mattwoodrow
MozReview-Commit-ID: L00D3h5PhTF

--HG--
extra : rebase_source : 9d834c4cd75ce120e743c49732a538decc05c1cf
2016-11-23 12:53:46 -05:00
Daniel Holbert
393a655d33 Bug 1319318: When resolving a video/audio frame's shrinkwrapped BSize from controls, check whether controls are orthogonal when reading its size. r=mats
MozReview-Commit-ID: 9kH7rLF66zd
2016-12-08 09:20:25 -10:00
Carsten "Tomcat" Book
7641d15135 Backed out changeset 9d41238dabf4 (bug 1319318) for unexpected pass crashtest results after merge
--HG--
extra : rebase_source : 76fe56bb5486bcdaa9924f2da1bbcf3f4bd46c6f
2016-12-09 15:30:56 +01:00
Carsten "Tomcat" Book
4434d5f7c1 merge mozilla-inbound to mozilla-central a=merge 2016-12-09 13:32:03 +01:00
Michael Layzell
c6fccac579 Bug 1299489 - Change nsTArray to use a custom iterator based on index instead of pointers to improve iterator invalidation safety of ranged for loops, r=froydnj
MozReview-Commit-ID: CahPOcRYvES
2016-12-08 15:54:45 -10:00
James Graham
19b6bc91a2 Bug 1321127 - Add temporary annotations for asserts missed by CI, r=dbaron
These asserts appeared during the window when reftest harness assert
count failures were not correctly detected by the CI system. They are
expected to be fixed in followup commits.

MozReview-Commit-ID: JoXtI4c0SSF
2016-12-08 09:53:21 -10:00
Carsten "Tomcat" Book
809fb645df Merge mozilla-central to autoland 2016-12-06 15:53:48 +01:00
Cameron McCormack
f5bb6f2dfd Bug 1322185 - Rename some StyleDisplay enum values for consistency. r=xidorn
MozReview-Commit-ID: K27LmXKWNdk
2016-12-05 21:36:28 -10:00
Xidorn Quan
c3010f1b3e Bug 1319424 - Ensure to setup line breaker before using it. r=jfkthame
MozReview-Commit-ID: EOuPLXTIBcZ

--HG--
extra : rebase_source : 166719397abf9ba8ca4e5bf9d187f2c7783981b3
2016-11-25 16:19:32 +11:00
Cameron McCormack
c7423798c3 Bug 1321284 - Part 1: Make StyleChildrenIterator skip NAC generated by root element primary frame ancestors. r=bholley
MozReview-Commit-ID: HICYWQgkE77

--HG--
extra : rebase_source : 7c5a533ada4eaa9839ca0497426f2c9c2a2d6c0b
2016-12-01 11:34:57 +08:00
Phil Ringnalda
2edc2d42db Merge m-i to m-c, a=merge
MozReview-Commit-ID: ByPMe4s1FrG
2016-12-02 22:17:31 -08:00
Tomislav Jurin
348bfffc19 Bug 1296189 - Replace NS_RUNTIMEABORT("some string literal message") with MOZ_CRASH(). r=froydnj 2016-12-02 13:46:53 -08:00
Daniel Holbert
a970d791f5 Bug 1321698 part 3: Fold nsFlexContainerFrame's old IsLegacyBox() function into its only remaining caller, nsFlexContainerFrame::Init(). r=mats
This patch is to prevent any new callers of this API, since we can now rely on
the new frame state bit (NS_STATE_FLEX_IS_LEGACY_WEBKIT_BOX) to test for this.

MozReview-Commit-ID: BONaqPC30Cn

--HG--
extra : rebase_source : 7e4bf712d6ebd23efae5495e4e6c130cd1dba8cb
2016-12-02 10:44:07 -08:00
Daniel Holbert
a720a44ada Bug 1321698 part 2: Use the new frame state bit to check for -webkit-box containers. r=mats
Note that at the callsites in nsCSSFrameConstructor.cpp, we have to also check
the frame type (since the frame state bit is in a range of bits whose meaning
differs depending on frame type).  The first change in this patch is the
addition of a convenience fucntion that checks both the frame type as well as
the frame state bit.

MozReview-Commit-ID: DEOThTX5NAO

--HG--
extra : rebase_source : 95e86eec663b3ef2e7bb86214871fcd3ea86057c
2016-12-02 10:32:31 -08:00
Daniel Holbert
f2e0c89b68 Bug 1321698 part 1: Set a frame state bit on nsFlexContainerFrame if it's emulating -webkit-box. r=mats
MozReview-Commit-ID: 5eL55atUBnT

--HG--
extra : rebase_source : c947804edfadd1b9aa3630e1f1e57484b98adb59
2016-12-02 01:02:00 -08:00
Xidorn Quan
6dc3678ea2 Bug 1321394 - Remove unnecessary loop in nsRubyBaseContainerFrame. r=dholbert
MozReview-Commit-ID: DqRD0w823Sv

--HG--
extra : rebase_source : 5d4e55c12a411e9f0c3579eca362d0b793aef445
2016-12-01 13:47:26 +11:00
Wes Kocher
d360bdebf5 Merge inbound to central, a=merge 2016-12-01 15:31:47 -08:00
Daniel Holbert
e9f3adb688 Bug 1319318: When resolving a video/audio frame's shrinkwrapped BSize from controls, check whether controls are orthogonal when reading its size. r=mats
MozReview-Commit-ID: 9kH7rLF66zd

--HG--
extra : rebase_source : fb0fde2152a6615630217d2504b97f05f69572a8
2016-12-08 09:20:25 -10:00
Ryan VanderMeulen
9bd4ab78e6 Merge m-c to inbound. a=merge 2016-12-01 09:33:46 -05:00
Daniel Holbert
f812426c42 Bug 1321387 part 6: Add #includes & forward declarations to some headers in layout/generic, to provide types used in those files. r=TYLin
Notes:
 * In CSSAlignUtils.h, I'm just adding a forward-decl for a type used there.
 * RubyUtils.h needs to #include nsIFrame.h -- a forward-declare won't
   suffice -- because it makes a nsIFrame method-call ("aFrame->GetType()").
 * ScrollSnap.h uses the "Maybe" type and a unit defined in
   nsIScrollableFrame.h; hence it needs both of those headers.

MozReview-Commit-ID: KuhJVh9RTjZ

--HG--
extra : rebase_source : 062c1abfe9a1efeb7e241f38302c140075d2ae88
2016-11-30 14:52:26 -08:00
Daniel Holbert
bf80884df5 Bug 1321387 part 5: Sort RubyUtils.h's #include list. r=TYLin
MozReview-Commit-ID: 8ReYlfPFClp

--HG--
extra : rebase_source : 02d56acfd97f8759dcabd59acd2c2fa81cee62d3
2016-11-30 14:51:51 -08:00
Daniel Holbert
10b4c0ba70 Bug 1321387 part 4: Add #includes to some .cpp files in layout/generic, to provide types/definitions used in those files. r=TYLin
These newly-included headers' types are all used directly in the affected files.

MozReview-Commit-ID: 5NEA1QhSJKN

--HG--
extra : rebase_source : 3a9244fcb2a074df1c929de800ddd6cbc1f730e8
2016-11-30 14:51:12 -08:00
Daniel Holbert
5df3673fc8 Bug 1321387 part 3: Add "mozilla::" namespace prefix to some types in header files. r=TYLin
(The only reason this isn't triggering a compile error is due to .cpp files'
"using namespace mozilla" getting haphazardly shared via unified builds.)

MozReview-Commit-ID: 1zhJueMWOav

--HG--
extra : rebase_source : d08f18573d823968f654491e61428aa70a4c217c
2016-11-30 14:50:22 -08:00
Daniel Holbert
ad5f5d35eb Bug 1321387 part 2: Add missing "using namespace" declarations to a few .cpp files in layout/generic. r=TYLin
This adds 2 "using namespace mozilla" (to provide various types),
and 2 "using namespace mozilla::gfx" (to provide mozilla::gfx::DrawTarget).

MozReview-Commit-ID: 2bXbMlr4Dbn

--HG--
extra : rebase_source : 9884419f08529469f23e3fc306ce6e4c57640f0d
2016-11-30 14:47:45 -08:00
Daniel Holbert
be6035f407 Bug 1321387 part 1: Wrap ReflowOutput impl in "namespace mozilla {}". r=TYLin
The class definition (in the header file) is already inside the namespace. But
the method implementations are not (until now), and they've only been compiling
successfully thanks to a "using namespace mozilla" that this file was picking
up from another .cpp file, via unified builds.

MozReview-Commit-ID: ImRBpAVA0en

--HG--
extra : rebase_source : 291e2777187ef9af17e17eecc5e48eb27dd111ec
2016-11-30 14:47:45 -08:00
Julian Seward
2a625e574c Bug 1316556 - Remove zeroing allocation in class nsIPresShell. r=dbaron.
--HG--
extra : rebase_source : 203c4848cf0fe321b429c78ddf71acd662755e6d
2016-12-01 09:06:50 +01:00
Ting-Yu Lin
728e7feacc Bug 1304598 Part 7 - Move BRFrame to mozilla namespace, and rename nsBRFrame.cpp to BRFrame.cpp. r=dholbert
MozReview-Commit-ID: 8IfleSWm1Af

--HG--
rename : layout/generic/nsBRFrame.cpp => layout/generic/BRFrame.cpp
extra : rebase_source : dd41317fa5990db720903fa0e9a22e424a2f56dd
2016-11-30 11:14:29 +08:00
Ting-Yu Lin
cb22e24990 Bug 1304598 Part 6 - Rename nsViewportFrame.h/cpp to ViewportFrame.h/cpp, and move exported header to mozilla/ subdir. r=dholbert
The class ViewportFrame doesn't have ns-prefix, so it's better to drop the
ns-prefix in the file names to avoid confusion.

MozReview-Commit-ID: 8Jrmfzb3tVR

--HG--
rename : layout/generic/nsViewportFrame.cpp => layout/generic/ViewportFrame.cpp
rename : layout/generic/nsViewportFrame.h => layout/generic/ViewportFrame.h
extra : rebase_source : d2c6a80275d696a2886983a4bbb46821784c7fe6
2016-11-30 11:14:29 +08:00
Ting-Yu Lin
bdd68c6c0c Bug 1304598 Part 5 - Move ViewportFrame to mozilla namespace. r=dholbert
MozReview-Commit-ID: CbQAesikfoO

--HG--
extra : rebase_source : 02d3b811561e0be9128a84daa74dae26b3791317
2016-11-30 11:14:28 +08:00
Ting-Yu Lin
4174a3a87e Bug 1304598 Part 3 - Rename nsPresShell.h/cpp to PresShell.h/cpp, and move exported header to mozilla/ subdir. r=dholbert
The class PresShell doesn't have ns-prefix, so it's better to drop ns-prefix
in the file names to avoid confusion.

MozReview-Commit-ID: IljxsF5CVjh

--HG--
rename : layout/base/nsPresShell.cpp => layout/base/PresShell.cpp
rename : layout/base/nsPresShell.h => layout/base/PresShell.h
extra : rebase_source : e73a6873f360a7223d87bd22d9854fc9603c499f
2016-11-30 11:14:28 +08:00
Ting-Yu Lin
5a4f377e61 Bug 1304598 Part 1 - Move PresShell to mozilla namespace. r=dholbert
MozReview-Commit-ID: 3nsP8Ukxfw9

--HG--
extra : rebase_source : 63d816b32e00c678e547f8950d4c2257f150b1a1
2016-11-30 11:14:27 +08:00
Hiroyuki Ikezoe
f94cef05e4 Bug 1319378 - Don't set NS_FRAME_MAY_BE_TRANSFORMED against nsIFrame that does not support transforms. r=dbaron
MozReview-Commit-ID: CuDA14ktcDL

--HG--
extra : rebase_source : 56ae5f6299391db62148ee562bc85f40b66c1d1f
2016-11-28 14:19:40 +09:00
Jeremy Chen
7e8439ba23 Bug 1320239 - use nscoord instead of nsStyleCoord for -webkit-text-stroke-width. r=heycam
MozReview-Commit-ID: 94fL7YgZqCl

--HG--
extra : rebase_source : ad651ab9270a9e19a21401b81745808cc7a8a74b
2016-11-29 20:08:08 +08:00
Carsten "Tomcat" Book
68202ee27c merge mozilla-inbound to mozilla-central a=merge 2016-11-29 16:47:18 +01:00
Thomas Wisniewski
bbec31e079 Bug 943918 - Part 2: layout for tab-size:<length> and tab-size:<number>. r=heycam 2016-11-25 00:18:11 -05:00
Ryan Hunt
4026e2a704 Bug 1303408 - Create nsDisplayLayerEventRegions for positioned elements. r=mattwoodrow
--HG--
extra : rebase_source : 080e2261084aa28151abab20adfcb2ea598c4424
extra : amend_source : b39a00efe74d8af4d4f2f7f1c5bcbcf83161e322
2016-11-23 16:24:29 -06:00
Nathan Froyd
2ebbd09068 Bug 1320752 - remove mozilla/Function.h; r=gerald
We have std::function available now, which is likely to be somewhat more
efficient.
2016-11-28 11:03:53 -05:00
Carsten "Tomcat" Book
4703a9d09f Merge mozilla-central to mozilla-inbound 2016-11-28 16:47:40 +01:00
Jeremy Chen
9dca2c80ea (no bug) minor indentation cleanup in nsTextFrameUtils.h. whitespace-only, no review, DONTBUILD
MozReview-Commit-ID: FIN0Tif6JZQ
2016-11-28 20:45:37 +08:00
Jeremy Chen
a09461846f (no bug) fix comment for nsTextFrameUtils::TransformText. comment-only, no review, DONTBUILD
MozReview-Commit-ID: Cu7zjjvOwQE
2016-11-28 20:45:37 +08:00
Julian Seward
e32070c1ac Bug 1320094 - Add missing mLoading assignments in {nsHTMLFramesetFrame,nsHTMLFramesetBorderFrame}::GetCursor. r=dbaron.
--HG--
extra : rebase_source : b339c012daab96990bf22bd5d31edc125135700d
2016-11-28 12:59:02 +01:00
Sebastian Hengst
8a78fcdecc Backed out changeset 0c5eb3fd9fb5 (bug 943918) 2016-11-28 00:39:27 +01:00
Thomas Wisniewski
813450469e Bug 943918 - Part 2: layout for tab-size:<length> and tab-size:<number>. r=heycam 2016-11-25 00:18:11 -05:00
Bobby Holley
f8c9d884fc Bug 1317016 - Basic infrastructure for RestyleHint-driven traversal. r=emilio
MozReview-Commit-ID: 7wH5XcILVmX
2016-11-25 10:06:39 -08:00
Carsten "Tomcat" Book
9dd582c3dd Merge mozilla-central to autoland 2016-11-29 11:50:17 +01:00
Ting-Yu Lin
0b68b2de7e Bug 1319672 Part 2 - Check the line direction is not changed. r=dbaron
Since the line direction affects the interpretation of float right or left,
we should check aWM has the same line direction as mWritingMode. And this
also guarantees that float added by AddFloat() has the same line direction
as when querying the available space via GetFlowArea().

MozReview-Commit-ID: FGxVFbo910g

--HG--
extra : rebase_source : 5bcf42fe88d3e03417f65565fa9252d6f1eb5acf
2016-11-23 18:10:23 +08:00
Ting-Yu Lin
50f80eb8ba Bug 1319672 Part 1 - Add document related to writing-mode in nsFloatManager. r=dbaron
MozReview-Commit-ID: 2Sr7UU6BQ9r

--HG--
extra : rebase_source : 50840b749cf045221af9680dc3538406f0936286
2016-11-23 18:07:56 +08:00
Phil Ringnalda
b280758db8 Backed out changeset 8611e9d0bdaa (bug 1319378) for Win8 reftest failures in table-overflowed-by-animation.html 2016-11-28 22:06:06 -08:00
L. David Baron
03d6962a30 Bug 1320815 - DeCOMtaminate nsIFrame::IsSelectable by returning boolean instead of nsresult. r=xidorn
MozReview-Commit-ID: EBxBcEgIvp7

--HG--
extra : rebase_source : 49e5a370df86baec014e99be56b05d451d5ee78c
2016-11-28 15:31:29 -08:00
L. David Baron
813fb8c039 Bug 1320815 - Make nsIFrame::IsSelectable non-virtual, and move implementation from nsFrame to nsIFrame. r=xidorn
MozReview-Commit-ID: HphEFug7EbQ

--HG--
extra : rebase_source : 86fe78f54940b1866ab737013658082799e09ef9
2016-11-28 15:31:29 -08:00
Xidorn Quan
ae670d64ee Bug 389283 - Choose cursor value based on selectability. r=dbaron
MozReview-Commit-ID: 2c4RcXgwz1U

--HG--
extra : rebase_source : c3525339d5d64f24c6f0667244885b8b33042072
2016-11-25 01:00:34 +11:00
Hiroyuki Ikezoe
6f58b63037 Bug 1319378 - Don't set NS_FRAME_MAY_BE_TRANSFORMED against nsIFrame that does not support transforms. r=dbaron
MozReview-Commit-ID: CuDA14ktcDL

--HG--
extra : rebase_source : f9dbd7ac8457bd0428402db3f856f0f96b1e1ecc
2016-11-28 14:19:40 +09:00
Timothy Nikkel
3468111c94 Bug 1317559. Make image layer related functions that may be called during paint ask for async image notifications. r=aosmond 2016-11-24 23:48:04 -06:00
Carsten "Tomcat" Book
61849e269d merge mozilla-inbound to mozilla-central a=merge 2016-11-24 16:41:59 +01:00
Matt Woodrow
f9af838c65 Bug 1318156 - Convert images into layers if we're forcing active layers. r=mstange 2016-11-24 18:11:30 +13:00
Matt Woodrow
f23176620b Bug 1318156 - Convert background colors into layers if we're forcing active layers. r=mstange 2016-11-24 18:11:29 +13:00
Matt Woodrow
c49650f909 Bug 1317862 - Part 4: Remove unnecessary clip. r=mstange 2016-11-24 18:11:29 +13:00
Matt Woodrow
3de8001441 Bug 1317862 - Part 3: Build TextLayers if enabled. r=mstange 2016-11-24 18:11:29 +13:00
Ting-Yu Lin
754b6c9659 Bug 1317588 Part 3 - Remove #define NS_SIDE_TOP/RIGHT/BOTTOM/LEFT. r=mats
This patch was written with the help of the following script. Also, manually
add mozilla qualifier to the enum values in nsStyleCoord.h, gfxRect.h, and
Types.h to make it build.

function rename() {
find .\
     -type f\
     ! -path "./obj*"\
     ! -path "./.git"\
     ! -path "./.hg"\
     \( -name "*.cpp" -or\
        -name "*.h" \)\
        -exec sed -i -e "s/$1/$2/g" "{}" \;
}

rename "NS_SIDE_TOP" "eSideTop"
rename "NS_SIDE_RIGHT" "eSideRight"
rename "NS_SIDE_BOTTOM" "eSideBottom"
rename "NS_SIDE_LEFT" "eSideLeft"

MozReview-Commit-ID: 9T0ORsqM6nP

--HG--
extra : rebase_source : 884ad96104c6e9cf6c8b3145d2d3a071ecccfe6a
2016-11-18 18:12:25 +08:00
Ting-Yu Lin
c9cfd878cb Bug 1317588 Part 2 - Remove mozilla::css::Side typedef. r=mats
This patch is written with the help of the following script.

function rename() {
find .\
     -type f\
     ! -path "./obj*"\
     ! -path "./.git"\
     ! -path "./.hg"\
     \( -name "*.cpp" -or\
        -name "*.h" \)\
        -exec sed -i -e "s/$1/$2/g" "{}" \;
}

rename "css::Side" "Side"

MozReview-Commit-ID: DPV6vivpPUp

--HG--
extra : rebase_source : 9c4f66dc9d2b26c89a4517fba4ff9c5db413411b
2016-11-18 16:28:38 +08:00
Ting-Yu Lin
62055a1981 Bug 1316549 Part 4 - Use logical names for ComputeEllipseLineInterceptDiff(). r=dbaron
This patch is just renames. No logic change for the function.

MozReview-Commit-ID: K7w0YL3G3gu

--HG--
extra : rebase_source : d72ecdcb4d4455f4950c8673c81fbfc7c1b4f54c
2016-11-18 13:54:09 +08:00
Ting-Yu Lin
ece375de5b Bug 1316549 Part 3 - Fix <shape-box> with border-radius in writing-mode. r=dbaron
The tests cases are designed based on the integer solution to the ellipse
equation (x/a)^2 + (y/b)^2 = 1, where x=36, y=32, a=60, b=40.

MozReview-Commit-ID: De2fXcb6ypP

--HG--
extra : rebase_source : a64f490ff41c020b84025266c0c255d93a158eea
2016-11-14 18:11:45 +08:00
Ting-Yu Lin
111246d956 Bug 1316549 Part 2 - Fix assertion failure: aRadiusY > 0 in FloatInfo::XInterceptAtY(). r=dbaron
We need to consider the case when only one of the four corner radius is
specified. The two reftests are added to test 'border-top-right-radius' and
'border-bottom-right-radius', respectively.

MozReview-Commit-ID: De2fXcb6ypP

--HG--
extra : rebase_source : 51da04a7a7d60d580b46d9ac8ed4bfd7e9666766
2016-11-14 18:11:45 +08:00
Ting-Yu Lin
c7596e7d85 Bug 1316549 Part 1 - Fix LogicalSideForLineRelativeDir() for eLineRelativeDirLeft/Right. r=jfkthame
According to the spec, 6.4. Abstract-to-Physical Mappings,
line-left/line-right are equal to inline-start/inline-end when the direction
is the same. So we should use IsBlockLTR() instead of IsLineInverted().

https://drafts.csswg.org/css-writing-modes-3/#logical-to-physical

MozReview-Commit-ID: 7onE0SuHtdj

--HG--
extra : rebase_source : df0083ed7e28469a2343a8607840585e93502b80
2016-11-17 14:10:55 +08:00
Cameron McCormack
ce08748113 Bug 1320423 - Null check cursor images to handled failed loads. r=dbaron
--HG--
extra : rebase_source : ccc18acf3ec30be54ebe2e2130d7bec55b857b16
2016-11-26 15:00:53 +08:00
Ray Lin
016b9e5609 Bug 1313285 - remove nsVideoFrame::mBorderPadding. r=dholbert
MozReview-Commit-ID: Cz5JQqWxQWH

--HG--
extra : rebase_source : 74f61a716ae75e2dbbd2e6311abb2a6d503c34fd
2016-11-25 14:03:15 +08:00
Xidorn Quan
e1ee43ee63 Bug 1223561 - Support putting <table> into fullscreen. r=dbaron
MozReview-Commit-ID: 5ohJW9U65dr

--HG--
extra : rebase_source : 6354a9d2f351a926c8dfb97fac342f634364cf57
2016-11-22 16:31:56 +11:00
Iris Hsiao
11e8b7fb2a Backed out changeset 535f8682016b (bug 1223561) for test_fullscreen-api.html timeout 2016-11-23 16:53:03 +08:00
Xidorn Quan
b283046733 Bug 1223561 - Support putting <table> into fullscreen. r=dbaron
MozReview-Commit-ID: 5ohJW9U65dr

--HG--
extra : rebase_source : 3edab41eb85239cc765d7305b1a6083397d4a158
2016-11-22 16:31:56 +11:00
Ehsan Akhgari
aca985efab Bug 1318805 - Move the code for the Web Painting module to layout/painting; r=mattwoodrow
This will help make it clearer that this code lives in a different
module for contributors.


--HG--
rename : layout/base/ActiveLayerTracker.cpp => layout/painting/ActiveLayerTracker.cpp
rename : layout/base/ActiveLayerTracker.h => layout/painting/ActiveLayerTracker.h
rename : layout/base/BorderCache.h => layout/painting/BorderCache.h
rename : layout/base/BorderConsts.h => layout/painting/BorderConsts.h
rename : layout/base/DashedCornerFinder.cpp => layout/painting/DashedCornerFinder.cpp
rename : layout/base/DashedCornerFinder.h => layout/painting/DashedCornerFinder.h
rename : layout/base/DisplayItemClip.cpp => layout/painting/DisplayItemClip.cpp
rename : layout/base/DisplayItemClip.h => layout/painting/DisplayItemClip.h
rename : layout/base/DisplayItemScrollClip.cpp => layout/painting/DisplayItemScrollClip.cpp
rename : layout/base/DisplayItemScrollClip.h => layout/painting/DisplayItemScrollClip.h
rename : layout/base/DisplayListClipState.cpp => layout/painting/DisplayListClipState.cpp
rename : layout/base/DisplayListClipState.h => layout/painting/DisplayListClipState.h
rename : layout/base/DottedCornerFinder.cpp => layout/painting/DottedCornerFinder.cpp
rename : layout/base/DottedCornerFinder.h => layout/painting/DottedCornerFinder.h
rename : layout/base/FrameLayerBuilder.cpp => layout/painting/FrameLayerBuilder.cpp
rename : layout/base/FrameLayerBuilder.h => layout/painting/FrameLayerBuilder.h
rename : layout/base/LayerState.h => layout/painting/LayerState.h
rename : layout/base/MaskLayerImageCache.cpp => layout/painting/MaskLayerImageCache.cpp
rename : layout/base/MaskLayerImageCache.h => layout/painting/MaskLayerImageCache.h
rename : layout/base/PaintTracker.cpp => layout/painting/PaintTracker.cpp
rename : layout/base/PaintTracker.h => layout/painting/PaintTracker.h
rename : layout/base/nsCSSRendering.cpp => layout/painting/nsCSSRendering.cpp
rename : layout/base/nsCSSRendering.h => layout/painting/nsCSSRendering.h
rename : layout/base/nsCSSRenderingBorders.cpp => layout/painting/nsCSSRenderingBorders.cpp
rename : layout/base/nsCSSRenderingBorders.h => layout/painting/nsCSSRenderingBorders.h
rename : layout/base/nsDisplayItemTypes.h => layout/painting/nsDisplayItemTypes.h
rename : layout/base/nsDisplayItemTypesList.h => layout/painting/nsDisplayItemTypesList.h
rename : layout/base/nsDisplayList.cpp => layout/painting/nsDisplayList.cpp
rename : layout/base/nsDisplayList.h => layout/painting/nsDisplayList.h
rename : layout/base/nsDisplayListInvalidation.cpp => layout/painting/nsDisplayListInvalidation.cpp
rename : layout/base/nsDisplayListInvalidation.h => layout/painting/nsDisplayListInvalidation.h
2016-11-21 20:01:15 -05:00
Mats Palmgren
38e563c2fe Bug 1153478 - Crashtest. 2016-11-21 00:26:37 +01:00
Nils
2a76150eef Bug 1281102 - Crashtest. 2016-11-21 00:26:37 +01:00
Mats Palmgren
a8c4f0a7da Bug 1316051 part 4 - [css-grid][css-flexbox] Use the alignment container of the table-wrapper frame also for its child frames. r=dholbert 2016-11-18 19:08:31 +01:00
Mats Palmgren
5129a5aa52 Bug 1316051 part 3 - [css-grid] Store the CB size that we give to table-wrappers on a frame property, then propagate that later (minus margins) to the inner table frame. r=dholbert 2016-11-18 19:08:31 +01:00
Ray Lin
461915d273 Bug 1271765 - Part 1: Remove XUL specific reflow code of video control. r=dholbert
MozReview-Commit-ID: KFn3ga2Uqq2

--HG--
extra : rebase_source : 41195f234bd3bb845855e08a354ce110d3f5e8b8
2016-10-12 13:41:50 +08:00
Ting-Yu Lin
55e3c801ba Bug 1271549 - Remove details and summary preference. r=bz
Bug 1259889 Part 2 [1] cannot be reverted cleanly, so I manually undo those
changes in this patch. That is, remove the ability for html.css to
invalidate dynamically since it was added specifically for details element.

Although reftest-stylo.list explicit mentions "DO NOT EDIT!", but I still
remove details pref from the file, since it doesn't harm to edit it anyway.

[1] https://hg.mozilla.org/mozilla-central/rev/30aaf3805b56

MozReview-Commit-ID: FsyTGQTxujh

--HG--
extra : rebase_source : 25e5a05a8a5a47642772da69f427631fa07e232d
2016-11-16 14:02:58 +08:00
Wes Kocher
f9e9d69899 Merge inbound to m-c a=merge CLOSED TREE 2016-11-16 17:07:26 -08:00
Botond Ballo
cdbef9ee0c Bug 1316101 - Avoid excessive clamping in StickyScrollContainer::GetScrollRanges(). r=mstange
Excessive clamping can cause incorrect behaviour in the presence of negative
margins.

MozReview-Commit-ID: AkQEqcQpAxx

--HG--
extra : rebase_source : 33cde31c15608792299a1dbef475e0fe0936270d
2016-11-14 19:01:37 -05:00
Ehsan Akhgari
eac76d9772 Bug 1310845 - Remove support for mozapp iframes; r=fabrice,jryans,baku,mcmanus
This patch removes support for mozapp iframes, leaving support for
mozbrowser iframes intact.  Some of the code has been rewritten in order
to phrase things in terms of mozbrowser only, as opposed to mozbrowser
or app.  In some places, code that was only useful with apps has been
completely removed, so that the APIs consumed can also be removed.  In
some places where the notion of appId was bleeding out of this API, now
we use NO_APP_ID.  Other notions of appId which were restricted to this
API have been removed.
2016-11-16 09:13:38 -05:00
Carsten "Tomcat" Book
3eacc680db Backed out changeset 7d1f7dd996f7 (bug 1310845) 2016-11-16 14:50:44 +01:00
Ehsan Akhgari
cb369370b3 Bug 1310845 - Remove support for mozapp iframes; r=fabrice,jryans,baku,mcmanus
This patch removes support for mozapp iframes, leaving support for
mozbrowser iframes intact.  Some of the code has been rewritten in order
to phrase things in terms of mozbrowser only, as opposed to mozbrowser
or app.  In some places, code that was only useful with apps has been
completely removed, so that the APIs consumed can also be removed.  In
some places where the notion of appId was bleeding out of this API, now
we use NO_APP_ID.  Other notions of appId which were restricted to this
API have been removed.
2016-11-15 18:31:46 -05:00
Ting-Yu Lin
7a0febcd1b Bug 1309467 Part 5 - Make flow area of <shape-box> values respect border-radius. r=dbaron
In GetFlowArea(), "Shrink our band's height if needed." computation was
moved to the end because we need to pass the unmodified |blockEnd| to
compute LineRight() and LineLeft().

Revamp OutsetBorderRadii() to allow negative margin to reduce the radius,
but not below zero. Also implement the cubic formula required by the spec.
https://drafts.csswg.org/css-shapes/#valdef-shape-box-margin-box

OutsetBorderRadii() is now tailored only for margin-box with border-radius,
so it might no longer be suitable for other scenarios.

MozReview-Commit-ID: HKxW7rp6sIA

--HG--
extra : rebase_source : d416433016304feefc9ed9dcd1c22f7f2f92e27e
2016-10-13 16:28:38 +08:00
Ting-Yu Lin
0bb55f9970 Bug 1309467 Part 4 - Implement <shape-box> values for shape-outside. r=dbaron
Per spec, float positioning and stacking is not affected by defining a float
area with a shape.
https://drafts.csswg.org/css-shapes/#relation-to-box-model-and-float-behavior

So all the call sites of GetFloatAvailableSpace() related to adding a
float are replaced by GetFloatAvailableSpaceForPlacingFloat().

<shape-box> with border-radius will be implemented in next part.

MozReview-Commit-ID: 1RXEeXDhdWo

--HG--
extra : rebase_source : 42cdb0c81b16168e4e30ee2261ceccb562e278cf
2016-10-12 16:06:25 +08:00
Ting-Yu Lin
f55545b058 Bug 1309467 Part 3 - Move FloatInfo::mRect construction into FloatInfo's constructor. r=dbaron
In later parts, we need the aMarginRect to build rect for shape box.

MozReview-Commit-ID: LtwMxbsNu3u

--HG--
extra : rebase_source : eee35663458079026b14922499b566674b2680ac
2016-10-12 14:26:26 +08:00
Ting-Yu Lin
91e0aadf9e Bug 1309467 Part 2 - Convert BandInfoType to an enum class. r=dbaron
Also exchange the order of the second argument |aBSize| and the third
argument |aBandInfo| for GetFlowArea() so that aBCoord and aBSize are
grouped together. And it'll be prettier to add ShapeInfo behind BandInfo
in later part.

MozReview-Commit-ID: cusdomjUyu

--HG--
extra : rebase_source : 8a7dca7179f1a05d380473d5d56d984bbe8aa97f
2016-10-12 13:26:17 +08:00
Ting-Yu Lin
679745ac84 Bug 1309467 Part 1 - Rename aBOffset to aBCoord in nsFloatManager::GetFlowArea(). r=dbaron
The header file and its documentation uses |aBCoord| so I change the
implementation for consistency.

MozReview-Commit-ID: 99mEUgUwcBV

--HG--
extra : rebase_source : 3ead203f6a325b26d96b2728ff28af74784effd7
2016-10-12 13:01:19 +08:00
Carsten "Tomcat" Book
5ad0e3405a Merge mozilla-central to autoland 2016-11-14 10:36:41 +01:00
Carsten "Tomcat" Book
c7a033c3e2 merge mozilla-inbound to mozilla-central a=merge 2016-11-14 10:22:06 +01:00
Ting-Yu Lin
e0ab7c2e17 Bug 1317203 - Change ReflowInputFlags to use bool : 1. r=mats
Based on bug 1294628 comment 8, I added spaces around the colon.

MozReview-Commit-ID: Dd4fvavMgmc

--HG--
extra : rebase_source : d99763461c764cc1a3c91c7c213bc8ac8c5cfbbc
2016-11-14 11:39:25 +08:00
Xidorn Quan
a4a78e1951 Bug 1267515 part 2 - Place ruby annotations outside annotations from ruby descendants. r=dholbert
MozReview-Commit-ID: Gbo43pC5jqr

--HG--
extra : rebase_source : 893fe9d419be59679febe2de07bbd495ce23e609
2016-10-26 17:40:58 +11:00
Xidorn Quan
b725f733a2 Bug 1267515 part 1 - Refactor ruby leadings into a helper RubyBlockLeadings struct. r=dholbert
MozReview-Commit-ID: IJAA9fHbCZd

--HG--
extra : rebase_source : 4166ebe1be89595f96da12e1e247cf1f0d536ddd
2016-11-10 11:10:42 +11:00
Sylvestre Ledru
3695654748 Bug 1317430 - Avoid a unnecessary copy by passing a const & in layout/ r=mstange
MozReview-Commit-ID: AmNDwwKl7RG

--HG--
extra : rebase_source : 45c06eddfd2c92959b819c614709c71b21b40e55
2016-11-15 17:30:59 +01:00
Wes Kocher
c2c5f83043 Backed out 3 changesets (bug 1271765) for win8 mochitest(5) failures a=backout
Backed out changeset 022a4a018996 (bug 1271765)
Backed out changeset 1d96f03289f8 (bug 1271765)
Backed out changeset 57317a080c99 (bug 1271765)
2016-11-15 10:50:59 -08:00
Ray Lin
234b017f7f Bug 1271765 - Part 1: Remove XUL-specific reflow code of video control. r=dholbert
MozReview-Commit-ID: KFn3ga2Uqq2

--HG--
extra : rebase_source : f660cc62ed5b2c3a361568fde22491a5aed6c9f6
2016-10-12 13:41:50 +08:00
Andi-Bogdan Postelnicu
1cdf51faec Bug 1316290 - Use C++11's override and remove already-implied virtual where applicable, in /layout. r=dholbert
MozReview-Commit-ID: IBljzyZmWW4

--HG--
extra : rebase_source : ab396c8a45116ab54da7a90335b7913d70cd91bd
2016-11-09 15:37:59 +02:00
Carsten "Tomcat" Book
cc5d30c616 Merge mozilla-central to mozilla-inbound
--HG--
extra : rebase_source : 658b3ffdfa71afff2d44129f50e50e2fbecbd06e
2016-11-11 16:43:07 +01:00
Thinker K.F. Li
338613b05c Bug 1230425 - Fix the test of transform of Combines3DTransformWithAncestors. r=mattwoodrow
--HG--
extra : rebase_source : 150571617831a4d1c67e21a3a6cd0fd6db3b522f
2016-11-10 06:00:00 -05:00
Gerald Squelart
0affeb4ab0 Bug 1316432 - Fix nsCOMPtr constructions&assignments from 0 - r=froydnj
Giving '0' (literal zero) to nsCOMPtr is now ambiguous, as both
nsCOMPtr(decltype(nullptr)) and nsCOMPtr(T*) could be used.
In any case, our coding standards mandate the use of 'nullptr' for pointers.
So I'm changing all zeroes into nullptr's where necessary.

MozReview-Commit-ID: LXiZTu87Ck6

--HG--
extra : rebase_source : f9dcc6b06e9ebf9c30a576f9319f76a51b6dc26f
2016-11-10 14:11:27 +11:00
Carsten "Tomcat" Book
4b6cab91f9 merge mozilla-inbound to mozilla-central a=merge 2016-11-10 16:59:38 +01:00
Jonathan Watt
07c5338755 Bug 1313525 - Remove the nsIPrintOptions interface. r=mstange
--HG--
rename : widget/nsIPrintOptions.idl => widget/nsIPrinterEnumerator.idl
2016-10-28 00:31:14 +01:00
Carsten "Tomcat" Book
846adaea6c merge mozilla-inbound to mozilla-central a=merge 2016-11-09 16:38:04 +01:00
Ting-Yu Lin
384e9e119b Bug 1291110 Part 4 - Use line BSize to query available space when updating nsLineLayout. r=dbaron
In nsBlockFrame::PlaceLine(), we query the float available space by
using the line's BSize(), which may cause the line to reflow again due
to available space shrunk.

The first issue lies in the second reflow. That is, we do not leverage
the line's BSize() computed in the first reflow to query the float
available space when updating the inline reflow engine in
BlockReflowInput::AddFloat(). So some tall inline elements could still
overlap the floats as in the first reflow.

To solve this, we cache current line's BSize so that it could be
used to update the inline reflow engine when redo the line.

Another issue is in nsBlockFrame::PlaceLine(). When determined whether
the available space is shrunk, we use the float manager's state *before*
placing the line. So if current line has floats, they're not considered.

To solve this, we use the current set of floats to get the float available
space for comparison, and leave the original aFloatAvailableSpace to provide
the information when redoing the line.

MozReview-Commit-ID: GqqNlphgxYS

--HG--
extra : rebase_source : e2c64ab1ac363c7a08e532dc043bee69d6455049
2016-08-22 19:42:37 +08:00
Ting-Yu Lin
8fa65e4f5d Bug 1291110 Part 3 - Enforce float available space never grow on either side. r=dbaron
This patch is based on bug 1291110 comment 29, but |aCanGrow| is preserved,
since the set of float available spaces we'll be testing in Part 4 are
difference from the one we enforced here.

MozReview-Commit-ID: LswbIaRukVR

--HG--
extra : rebase_source : 007d55fd867d052163ea5bb4222baf201fe30bcf
2016-11-08 15:20:58 +08:00
Ting-Yu Lin
76dba9d5d5 Bug 1291110 Part 2 - Rename availableSpaceHeight to availableSpaceBSize. r=dbaron
Rename to make the variable name consistent with the writing-mode
terminology used in PlaceLine().

MozReview-Commit-ID: AvhwHyHz7hV

--HG--
extra : rebase_source : bcec67d9959c1b881b4d287dbbab47dd0d6e0de9
2016-11-08 13:42:14 +08:00
Ting-Yu Lin
bb1491fb5a Bug 1291110 Part 1 - Fix log and comment related to float. r=dbaron
MozReview-Commit-ID: ICUflMUOsD2

--HG--
extra : rebase_source : ccba872d056edcfb07095f3f2995492324394ab0
2016-08-22 19:41:53 +08:00
Brad Werth
1e29a9cf1c Bug 1314080 Part 1: Rename CollectClientRects method and add a new parameter for collecting text. r=smaug
MozReview-Commit-ID: KQPky6Fh8sG

--HG--
extra : rebase_source : 33bce65c1752aeb7a2225a981f2dadf7e2ce5916
2016-11-02 13:49:43 -07:00
Phil Ringnalda
7c7dd328d1 Backed out 3 changesets (bug 1271765) for -Werror bustage
CLOSED TREE

Backed out changeset 235ea1c681db (bug 1271765)
Backed out changeset 02d34b18d76b (bug 1271765)
Backed out changeset 088113647629 (bug 1271765)
2016-11-07 18:51:18 -08:00
Brad Werth
0d9163aeec Bug 1221524 Part 3: Implement align-self:last baseline behavior in flex containers. r=dholbert
MozReview-Commit-ID: 7Qo7LPu74Ra

--HG--
extra : rebase_source : 81bccbf7bdb7c7e83198783514acba35a690d9f2
2016-11-07 09:53:14 -08:00
Brad Werth
660c37a2d7 Bug 1221524 Part 1: Map align-self:"baseline" to "flex-start" when FlexItem writing mode is orthogonal to container main axis. r=dholbert
MozReview-Commit-ID: 2IlkVDWNirG

--HG--
extra : rebase_source : 6885a5a4a4247b4cec74d6ff9ca1c463cd6b0e14
2016-10-31 14:46:52 -07:00
Ray Lin
01a64b4413 Bug 1271765 - Part 1: Remove XUL-specific reflow code of video control. r=dholbert
MozReview-Commit-ID: KFn3ga2Uqq2

--HG--
extra : rebase_source : 09c9b06d40cb199114ca6777cdc992a04fb4d6eb
2016-10-12 13:41:50 +08:00
Phil Ringnalda
a7bc94158c Merge m-i to m-c, a=merge
MozReview-Commit-ID: H4VKCYDq5cD

--HG--
rename : xpcom/tests/TestAutoRef.cpp => xpcom/tests/gtest/TestAutoRef.cpp
rename : xpcom/tests/TestCOMArray.cpp => xpcom/tests/gtest/TestCOMArray.cpp
rename : xpcom/tests/TestCOMPtr.cpp => xpcom/tests/gtest/TestCOMPtr.cpp
rename : xpcom/tests/TestCOMPtrEq.cpp => xpcom/tests/gtest/TestCOMPtrEq.cpp
rename : xpcom/tests/TestFile.cpp => xpcom/tests/gtest/TestFile.cpp
rename : xpcom/tests/TestHashtables.cpp => xpcom/tests/gtest/TestHashtables.cpp
rename : xpcom/tests/TestID.cpp => xpcom/tests/gtest/TestID.cpp
2016-11-05 13:36:25 -07:00
Sebastian Hengst
21b6a70f58 Bug 1310297 - Remove test annotations using b2g, mulet or gonk: layout/generic. r=RyanVM
MozReview-Commit-ID: 2Klhlu481mS

--HG--
extra : rebase_source : 848600cd18690e3308da370429c591200425c0cb
2016-11-05 11:29:20 +01:00
Mats Palmgren
667529f852 Bug 1314206 part 2 - [css-grid] Don't check for unconstrained inline size since it never occurs (other than by accident). r=dholbert 2016-11-05 02:57:08 +01:00
Mats Palmgren
0a5e98068a Bug 1314206 part 1 - [css-grid] Stretch the inline size when requested, unless we're measuring the shrink-wrap size. r=dholbert 2016-11-05 02:57:08 +01:00
Mats Palmgren
faf8e6f6bf Bug 1313254 part 6 - [css-grid] A few comment tweaks. rs=dholbert 2016-11-05 02:57:08 +01:00
Mats Palmgren
b1c4b6d89a Bug 1313254 part 2 - [css-align] Change "last-baseline" to "last baseline" in layout/ (scripted change). r=dholbert 2016-11-05 02:57:07 +01:00
Mats Palmgren
bb4421d329 Bug 1300369 part 12b - Make nsIFrame::ComputeISizeValue clamp the min-content size when eIClampMarginBoxMinSize is in aFlags. r=dholbert 2016-11-05 02:57:07 +01:00
Mats Palmgren
87c23dd98b Bug 1300369 part 12a - Add a ComputeSizeFlags arg to nsIFrame::ComputeISizeValue. Propagate aFlags in nsFrame::ComputeSize in its ComputeISizeValue calls (idempotent patch). r=dholbert 2016-11-05 02:57:07 +01:00
Mats Palmgren
6b1b0153ba Bug 1300369 part 11 - Move nsLayoutUtils::ComputeISizeValue to a nsIFrame method (idempotent patch). r=dholbert 2016-11-05 02:57:07 +01:00
Mats Palmgren
5bcffbffeb Bug 1300369 part 10 - Make nsFrame::ComputeSizeWithIntrinsicDimensions handle margin-box min-size clamping. r=dholbert 2016-11-05 02:57:06 +01:00
Mats Palmgren
a6089b50fc Bug 1300369 part 9 - Add a ComputeSizeFlags param to nsFrame::ComputeSizeWithIntrinsicDimensions (idempotent patch). r=dholbert 2016-11-05 02:57:06 +01:00
Mats Palmgren
ddb49488f0 Bug 1300369 part 8 - Move nsLayoutUtils::ComputeSizeWithIntrinsicDimensions to a nsFrame method (idempotent patch). r=dholbert 2016-11-05 02:57:06 +01:00
Mats Palmgren
e54d8218a4 Bug 1300369 part 7 - [css-grid] Implement margin-box min-size clamping for grid item reflow. r=dholbert 2016-11-05 02:57:06 +01:00
Mats Palmgren
a0c5be1ac8 Bug 1300369 part 6 - Make nsBlockFrame::ComputeFinalSize handle margin-box min-size clamping. r=dholbert 2016-11-05 02:57:06 +01:00
Mats Palmgren
1296ddcec3 Bug 1300369 part 5 - Make nsFrame::ComputeSize and nsFrame::ShrinkWidthToFit handle margin-box min-size clamping. r=dholbert 2016-11-05 02:57:06 +01:00
Mats Palmgren
e78d14df88 Bug 1300369 part 4 - Refactor all ComputeAutoSize methods to take the full ComputeSizeFlags instead of just a "bool aShrinkWrap" for the eShrinkWrap flag (idempotent patch). r=dholbert 2016-11-05 02:57:06 +01:00
Mats Palmgren
6b8c4c8679 Bug 1300369 part 3 - [css-grid] Implement margin-box min-size clamping during track sizing. r=dholbert 2016-11-05 02:57:06 +01:00
Mats Palmgren
d523cbcf73 Bug 1300369 part 1 - Add two new ComputeSizeFlags flags e{I,B}ClampMarginBoxMinSize and associated reflow state flags to indicate we want margin-box min-size clamping in the indicated axis. r=dholbert 2016-11-05 02:57:06 +01:00
Cameron McCormack
32c930ba08 Bug 1288302 - Part 5: Make nsStyleImage use nsStyleImageRequest. r=bholley
This makes background-image, mask-image and border-image settable
from Servo.

Since imgRequestProxy resolution in nsStyleImages can now happen later than
at computed value setting time, and that resolution can fail,
nsStyleImage::GetImageData() might now return null.  So all of the users of
nsStyleImage now null check its result.

MozReview-Commit-ID: FMRUrC3SfOs
2016-11-02 16:58:32 +08:00
Daniel Holbert
e8d54b0d73 Bug 1269017 part 5 - [css-grid] Tag grid placeholder children as needing CSS Box Alignment, & consolidate their placement code. r=mats
MozReview-Commit-ID: 5105oez3IO3
2016-11-08 16:30:00 -08:00
Daniel Holbert
d36239361c Bug 1269017 part 4 - [css-grid] When doing CSS Box Alignment, opt out of a CalculateHypotheticalPosition() clause that disregards placeholder's inline position. r=mats
(We don't want to disregard this position -- it's what we use to encode the
start of the alignment container for this child, when we're doing CSS Box
Alignment. So we need it to be reflected in the hypothetical position, not
disregarded.)

MozReview-Commit-ID: 28IgPn8z1Hr
2016-11-08 16:30:00 -08:00
Daniel Holbert
b48516cdb2 Bug 1269017 part 3 - [css-grid] Reduce scope of a mStaticPosIsCBOrigin check to *just* cover hypothetical-position calculation, and update comments. r=mats
Previously, I'd thought the "mStaticPosIsCBOrigin" flag was going to become
obsolete -- but now I've realized it's quite useful to avert mixup between the
coordinate space of the grid vs. the coordinate space of
grid-areas-acting-as-abspos-containing-blocks.

So, this patch clarifies/removes some stale comments about this flag, and also
pulls out some code that was unnecessarily in an "else" clause, so that it
happens regardless of whether this flag is set.

(Note: the InitAbsoluteConstraints changes are basically just code-reordering & deindentation.)

MozReview-Commit-ID: 9TFrOuldVBe
2016-11-08 16:30:00 -08:00
Daniel Holbert
e2446048f6 Bug 1269017 part 2 - [css-grid] Give grid an implementation of CSSAlignmentForAbsPosChild(). r=mats
This grid implementation is similar to the one on nsFlexContainerFrame, with a few simplifications:
 - We can simply use the LogicalAxis to decide between align-* vs justify-* prpoerties (whereas flexbox has extra abstraction from the flex axes).
 - We don't have to bother with "align-content" or "justify-content", since those apply to grid areas rather than to children. (And any grid area that's involved will be sized/positioned separately.)
 - Grid can unconditionally treat "flex-start" & "flex-end" as "start" & "end".

MozReview-Commit-ID: 9l1Wq9Cq5T0
2016-11-08 16:30:00 -08:00
Daniel Holbert
df60393385 Bug 1269017 part 1 - [css-grid] Adjust OffsetToAlignedStaticPos() to use correct alignment container for abpsos children of grid containers. r=mats
MozReview-Commit-ID: LItIGLH5GJP
2016-11-08 16:30:00 -08:00
Ting-Yu Lin
a22cb5f094 Bug 1321166 - Wrap DetailsFrame's definition and implementation in mozilla namespace. r=dholbert
MozReview-Commit-ID: 24cUKrWKRe

--HG--
extra : rebase_source : f9c1c0bc99bf77a1312fc408e4bc5c352efe0f37
2016-12-01 13:18:03 +08:00
Daniel Holbert
5e2f87bff5 Bug 1269046 part 11: Add reftests for CSS Alignment of absolutely positioned flex children.
MozReview-Commit-ID: FpWhqZdyvBr
2016-10-31 08:59:40 -07:00
Daniel Holbert
f3a0064ac4 Bug 1269046 part 10: Skip the normal margin-adding codepath for abspos frames that undergo CSS Box Alignment (which takes care of margins). r=mats
MozReview-Commit-ID: Ha0o1rwFzE9
2016-10-31 08:59:40 -07:00
Daniel Holbert
0d6dda2ff4 Bug 1269046 part 9: Add a flag to control whether CSSAlignUtils::AlignJustifySelf() expands "auto" margins. r=mats
MozReview-Commit-ID: I0UdEIfiOqX
2016-10-31 08:59:40 -07:00
Daniel Holbert
8a46fab5d0 Bug 1269046 part 8: Rewrite CSSAlignUtils::AlignJustifySelf to use a single "flags" arg instead of boolean args. r=mats
MozReview-Commit-ID: 5loE21U7FF6
2016-10-31 08:59:40 -07:00
Daniel Holbert
5801c1a6f6 Bug 1269046 part 7: Give nsFlexContainerFrame a CSSAlignmentForAbsPosChild() implementation (to determine appropriate align enum for abspos children). r=mats
MozReview-Commit-ID: LFQfKPlR9Gv
2016-10-31 08:59:40 -07:00
Daniel Holbert
773cf89b1c Bug 1269046 part 6: Add a flags enum-class to customize FlexboxAxisTracker behavior. r=mats
Right now, there's only one flag in this new class (with no usages until a
later patch). This flag suppresses a hack, which otherwise makes us
transparently reverse the child list & flex axes in some circumstances, to
prevent bottom-to-top child ordering. (We don't want that hack when we're
dealing with individual abspos children, since it only makes things more
complicated.)

MozReview-Commit-ID: HYUf0vjlfiJ
2016-10-31 08:58:18 -07:00
Daniel Holbert
4c7bd3c17e Bug 1269046 part 5: If an abspos child's offset depends on CSS Box Alignment, ask nsContainerFrame for the alignment enum to use, and align with CSSAlignUtils. r=mats
Right now, this method has only one stub impl, in nsContainerFrame; a later
patch will add a more interesting (overriding) impl in nsFlexContainerFrame.

MozReview-Commit-ID: 3U3vTTX4vdm
2016-10-31 08:58:18 -07:00
Daniel Holbert
689d473b8d Bug 1269046 part 4: Set flags on nsPlaceholderFrame & ReflowInput to track abspos frames that need CSS Box Alignment to resolve static position. r=mats
(We'll react to the ReflowInput flags and do the actual CSS Box Alignment in a
later patch in this series.)

MozReview-Commit-ID: EZd7npWSzQI
2016-10-31 08:58:18 -07:00
Daniel Holbert
6512700680 Bug 1269046 part 3: Make a grid-specific comment more general, in CSSAlignUtils::AlignJustifySelf. r=mats
MozReview-Commit-ID: GZ35iZ2E1Iz
2016-10-31 08:58:18 -07:00
Daniel Holbert
ac46282aec Bug 1269046 part 2: Spin out a helper function to hold nsAbsoluteContainingBlock's code for resolving abspos offsets. r=mats
MozReview-Commit-ID: 5tvCIEhAsPH
2016-10-31 08:58:18 -07:00
Daniel Holbert
2a8bcc81e7 Bug 1269046 part 1: Spin out some grid alignment code into a helper method, in a new CSSAlignUtils class. r=mats
MozReview-Commit-ID: 1Eh2CreOLTC
2016-10-31 08:58:18 -07:00
Daniel Holbert
3903256ea3 Bug 1269045 part 3: Stop wrapping placeholder frames in anonymous flex items. r=mats
This patch also:
 * Removes some now-unnecessary code from nsFlexContainerFrame, which was for jumping from wrapped-placeholders to their out-of-flow frames (for DOM comparisons). This code is now unnecessary because placeholders won't be wrapped anymore.
 * Updates some reftests with abspos content to match the updated spec's expectations, with one marked as "fails" for the time being (until bug 1269046 implements css box alignment, which we need to render that test correctly).

MozReview-Commit-ID: 8canWfXk6Kf
2016-10-31 08:58:17 -07:00
Daniel Holbert
4bef1cf802 Bug 1269045 part 2: Separate out abspos placeholders when creating FlexItems, and give them a trivial reflow at container's content-box origin. r=mats
MozReview-Commit-ID: 5lXUsusLryC
2016-10-31 08:58:17 -07:00
Daniel Holbert
6195387be1 Bug 1269045 part 1: Adjust flex item "order"-sorting code to treat placeholder frames as <= anything they're compared against, including each other. r=mats
This patch makes the following specific changes:
 (1) Adds an early-return to both versions of the IsOrderLEQ function, to treat placeholder children as LEQ everything (including each other). This will tend to sort them to the beginning of the child list, which is unimportant but fine. More importantly, though: this means our "order"-sorting code won't reorder placeholders *with respect to each other* (since our sort algorithm is stable). So their painting order won't be affected by the "order" property, which is required by the spec.
 (2) Drops some nsPlaceholderFrame::GetRealFrameFor() calls -- they're unnecessary, since any placeholder frames will have prompted us to return earlier.

One caveat to (2): this patch does leave a few "nsPlaceholderFrame::GetRealFrameFor()" calls in place, *for the moment*.  These remaining calls are for handling placeholders that are wrapped, i.e. inside of anonymous flex items. These calls are still needed to avoid assertion-failures (i.e. to get a consistent ordering) at this point, but they'll be removed in a later patch in this same bug, when we stop wrapping placeholders in anonymous flex items.

MozReview-Commit-ID: 1R6NW30Kxgv
2016-10-31 08:58:17 -07:00