Jeremy Chen
aee90be343
Bug 1286468 followup - Fix naming issues.
...
MozReview-Commit-ID: C2PDA4R5k5F
2016-10-24 15:01:25 +08:00
Jeremy Chen
349eabf2f7
Bug 1286468 - Rename line related functions in nsBlockFrame. r=TYLin
...
1. Rename these functions to agree with Mozilla coding style.
2. Use singular naming instead of plural naming since each of these functions
returns an iterator pointing to a singular line.
3. Rename line() and rline() to BeginLineFrom() and RBeginLineFrom(), which
shall improve the readability.
MozReview-Commit-ID: txZjVnv9Yb
--HG--
extra : rebase_source : b4dae99ab7bf751bd9974616f8f8e6dfe6248fc2
2016-10-22 19:41:05 +08:00
Jeremy Chen
a670e3349a
Bug 1286468 - Rename line related typedefs in nsBlockFrame. r=TYLin
...
MozReview-Commit-ID: Cz9R3D4NzMc
--HG--
extra : rebase_source : 19da1e2a58abedf61fddd9c8e314830cf81a4602
2016-10-22 19:41:04 +08:00
Manish Goregaokar
aad318e17a
Bug 1300337
- Replace None_ variants from nsStyleConsts.h with None; r=heycam,TYLin
...
MozReview-Commit-ID: CxHzbEzjLxT
--HG--
extra : rebase_source : 232f90b8b107f7fb49f47a29a4e493660b8a7d87
2016-09-04 00:16:58 +05:30
Jeremy Chen
c6d0429830
Bug 1297306 - part6:replace NS_STYLE_CLEAR_* with StyleClear enum class. r=xidorn
...
After using enum class, a switch-case warning in CombineBreakType is caught.
This is one of such kind safty checks that we would like to gain.
Fix it by adding default case for switch-case in CombineBreakType.
MozReview-Commit-ID: BdS3LPN6qzX
--HG--
extra : rebase_source : 17f24a0d482ed6eb51b23e6942d0ac1c87375e0b
2016-09-07 10:20:17 +08:00
Ting-Yu Lin
d77152fcd0
Bug 1277129 Part 7c - Rename various RS variables to RI. r=dbaron
...
This patch is generated by the following script:
function rename() {
find layout\
-type f\
! -path "./obj*"\
! -path "./.git"\
! -path "./.hg"\
\( -name "*.cpp" -or\
-name "*.h" \)\
-exec sed -i -r "s/$1/$2/g" "{}" \;
}
rename aChildRS aChildRI
rename aContainingBlockRS aContainingBlockRI
rename aFrameRS aFrameRI
rename aLastRS aLastRI
rename aOuterRS aOuterRI
rename aRS aRI
rename blockHtmlRS blockHtmlRI
rename captionRS captionRI
rename cellRS cellRI
rename childRS childRI
rename firstAncestorRS firstAncestorRI
rename flexContainerRS flexContainerRI
rename gridRS gridRI
rename innerRS innerRI
rename lastButOneRS lastButOneRI
rename LineContainerRS LineContainerRI
rename mBlockRS mBlockRI
rename parentRS parentRI
rename secondAncestorRS secondAncestorRI
rename lastRSSize lastRISize
rename lastRSPadding lastRIPadding
MozReview-Commit-ID: YEgZs3WMow
--HG--
extra : rebase_source : c26050c71a3a5b13ef46e6d3582e581702d49ee8
2016-07-21 18:36:39 +08:00
Ting-Yu Lin
40fcd21b9a
Bug 1277129 Part 7b - Rename various ReflowState variables to ReflowInput. r=dbaron
...
This patch is generated by the following script:
function rename() {
find .\
-type f\
! -path "./obj*"\
! -path "./.git"\
! -path "./.hg"\
\( -name "*.cpp" -or\
-name "*.h" \)\
-exec sed -i -r "s/$1/$2/g" "{}" \;
}
rename "([[:alpha:]]*)([rR])eflowState(s?)" "\1\2eflowInput\3"
MozReview-Commit-ID: ITFO7uMTkSb
--HG--
extra : rebase_source : c91a2e174a0baec60c1b0111ac7636295004ab35
2016-07-21 18:36:39 +08:00
Ting-Yu Lin
cd13f0ea71
Bug 1277129 Part 6a - Rename frame to mFrame in SizeComputationInput. r=dbaron
...
MozReview-Commit-ID: 3SXZ4qEZJc
--HG--
extra : rebase_source : 577d48f047af163585acea95dda311358f5e8c25
2016-07-21 18:36:38 +08:00
Ting-Yu Lin
6111a2de40
Bug 1277129 Part 2c - Rename nsBlockReflowState to BlockReflowInput. r=dbaron
...
This patch is generated by 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 "nsBlockReflowState" "BlockReflowInput"
MozReview-Commit-ID: FtjqkQpGfcI
--HG--
extra : rebase_source : c8f678bc47217b778df7f91f0f6cce6c44b04d90
2016-07-21 18:36:36 +08:00
Ting-Yu Lin
371989a096
Bug 1277129 Part 2b - Rename nsBlockReflowState.h/cpp to BlockReflowInput.h/cpp and fix #includes. r=dbaron
...
The #includes are fixed by 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 "nsBlockReflowState\.h" "BlockReflowInput\.h"
MozReview-Commit-ID: 6QMqko1XOsT
--HG--
rename : layout/generic/nsBlockReflowState.cpp => layout/generic/BlockReflowInput.cpp
rename : layout/generic/nsBlockReflowState.h => layout/generic/BlockReflowInput.h
extra : rebase_source : 8911b9bbe68ceca82c77b7e120d87bfa71b7211c
2016-07-21 18:36:36 +08:00
Ting-Yu Lin
820f88de49
Bug 1277129 Part 1c - Rename nsHTMLReflowState to ReflowInput. r=dbaron
...
This patch is generated by 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 nsHTMLReflowState ReflowInput
MozReview-Commit-ID: 9r9vdVv1pXc
--HG--
extra : rebase_source : 623ec822996ba0ea0058dd137acf5a658cdea04a
2016-07-21 18:36:35 +08:00
Ting-Yu Lin
1889f6bc41
Bug 1227927 Part 2 - Remove nsIFrame::GetFirstPrincipalChild(). r=mats
...
--HG--
extra : commitid : 5qtaK1nS8RC
extra : rebase_source : dcc98f423b2446269beb6fa6a9d092ae8213f38e
2016-01-29 22:42:14 +08:00
Mats Palmgren
73b1279e0e
Bug 1174553 part 3 - [css-grid] Implement the 'min-content' / 'max-content' sizing functions in layout. r=dholbert
2015-09-04 22:06:57 +02:00
L. David Baron
bb57d7d42e
Bug 451791 patch 2 - Report block non-empty to its parent block during margin collapsing if we encounter clearance. r=roc
...
The goal of ComputeCollapsedBStartMargin is to collapse all of the
margins that collapse with a block's top margin. It does this by
scanning forward through the child list until it finds something that
blocks collapsing; it descends into children through recursion. When we
find a non-empty block or line, we stop collapsing and report to the
parent that the child is non-empty so that it stops collapsing as well.
This patch changes our behavior when we have clearance to do the same
thing that we do for non-empty lines or blocks (which makes both
occurrences of |goto done| be preceded by the same code). Without the
patch we would fail to report being non-empty to the parent (and instead
report emptiness based on the IsEmpty() method). This meant that,
without the patch, if a block has a child with clearance but also has
IsEmpty() true, we would stop scanning margins in that block after the
clearance, but start searching again for margins in the block's parent,
starting with the block's bottom margin. This patch sets *aBlockIsEmpty
to true in that case so that we do not pick up again in the block's
parent (or, potentially, grandparent, etc.).
--HG--
extra : commitid : LCMTvXvZT3G
2015-08-05 21:04:38 -07:00
L. David Baron
119b557460
Bug 538194 patch 2 - Redo block reflow below floats when the height of a block that does not intersect floats pushes it into the way of other floats. r=roc
...
This adds an additional retry loop in block reflow that we can only
trigger when reflowing a block formatting context (replacedBlock
non-null). It can retry in two different ways, either with a narrower
width but at the same vertical position (when
ReplacedBlockFitsInAvailSpace is still true) or at a new vertical
position (which is treated as a form of clearance).
Fortunately we don't have to worry about margins collapsing *through*
such a boundary since we're dealing with a new block formatting context.
Note that Chromium passes all of the new bfc-displace-* tests, although
it moves the block formating context down unnecessarily in
bfc-shrink-1.html (which we do neither before nor after the patch),
though agrees with the width we have after the patch (but not before the
patch).
--HG--
extra : commitid : FgDc4hjTxHp
2015-08-02 21:03:09 -07:00
L. David Baron
dc94df9c46
Bug 478834 - Record that we need to look for clearance if we encounter a block that might need to be pushed down for intersecting floats (i.e., one that establishes a BFC). r=roc
...
Without this change, nsBlockFrame::ReflowBlockFrame will fail to have
mayNeedRetry true, which means that it won't set
blockHTMLRS.mDiscoveredClearance, which means that on a descendant
replaced block we will fail to fall into any of the cases that call
ClearFloats. This change will cause us to hit the first ClearFloats
call and discover the need for clearance.
I tested locally that the new reftest fails without the patch and passes
with the patch.
2015-07-27 20:23:56 -07:00
Jonathan Kew
4e6c40d7ea
Bug 1131451 part 1 - Replace containerWidth with containerSize in logical-coordinate classes and APIs, frame classes, etc. r=dholbert
2015-07-16 10:07:57 +01:00
Jonathan Kew
a97792aed1
Bug 1144501 - Take account of orthogonal writing modes when adjusting available size to reflow a child frame. r=smontagu
2015-04-07 15:35:30 +01:00
Mats Palmgren
ed9ed2d61a
Bug 1148833 part 3 - Remove nsIFrame::WillReflow and add a non-virtual MarkInReflow method instead that sets NS_FRAME_IN_REFLOW. Call it at the start of Reflow(). r=roc
2015-03-29 22:38:40 +00:00
Simon Montagu
13be932c72
Bug 1143218 patch 3: a better fix for bug 1105137 using line-left and line-right to place floats, r=jfkthame
2015-03-22 11:44:48 +02:00
Simon Montagu
4454a1b4b5
Bug 1143218 patch 1: Back out the fix for bug 1105137, r=jfkthame
2015-03-22 11:44:48 +02:00
Simon Montagu
9cdb41a6f4
Bug 1131013: when setting the position of inline frames in vertical writing modes with right-to-left direction, subtract the inline start from the container height to get the correct vertical position. r=jfkthame
2015-02-11 01:43:03 -08:00
Simon Montagu
2df582470e
Bug 1121748 - patch 1 - Make sure to update the frame dimensions before calling ApplyRelativePositioning. r=jfkthame
2015-01-18 22:01:57 -08:00
Simon Montagu
32d27c84d2
Bug 1063471: finish off converting nsBlockReflowContext to logical coordinates (comment-only change), r=jfkthame
2015-01-08 02:10:24 -08:00
Simon Montagu
1eacdee679
Bug 1079154 patch 5: convert callers of ApplyRelativePosition, ReflowChild and FinishReflowChild in layout/generic to the logical versions, r=jfkthame
2015-01-06 23:10:07 -08:00
Simon Montagu
33a271e5bd
Bug 1105137: treat nsFloatManager's mOrigin as an offset, not a point, and rename it to mOffset to make that clearer, r=jfkthame
2014-12-11 03:56:03 -08:00
Jonathan Kew
1c2aa200a8
Bug 1096224 - part 2 - Fix writing mode mismatch in margin calculation in PlaceBlock. r=smontagu
2014-11-26 10:24:16 +00:00
Jonathan Kew
bc30822def
Bug 1093684 - part 3 - Replace |bottom| with |block-end| in a bunch of comments, and rename mCarriedOutBottomMargin to mCarriedOutBEndMargin. r=smontagu
2014-11-17 08:49:38 +00:00
Jonathan Kew
bb857cabb0
Bug 1086883 - Convert writing modes where necessary for orthogonal flows when collapsing margins in nsBlockReflowContext methods. r=smontagu
2014-10-24 12:24:38 +01:00
Simon Montagu
8d64967541
Bug 1079139: make nsFlowAreaRect.mRect a LogicalRect. r=jfkthame
2014-10-21 15:16:13 -07:00
Simon Montagu
e753ab75a0
Bug 1062963 patch 3: make nsFloatManager's origin a LogicalPoint, adapt GetFlowAreas, AddFloats, ClearFloats, etc. to use it and make nsFloatManager region functions work with logical region. r=jfkthame
2014-10-21 15:16:12 -07:00
Phil Ringnalda
b2eb743d9b
Backed out 4 changesets (bug 1062963, bug 1079139) for failures in 427129-table-caption.html in b2g reftest-6 and Android 2.3 reftest-5
...
Backed out changeset a9672db96a5d (bug 1079139)
Backed out changeset 241c23570a62 (bug 1062963)
Backed out changeset 90172cc0b012 (bug 1062963)
Backed out changeset 71211c4a4acc (bug 1062963)
2014-10-19 18:44:16 -07:00
Simon Montagu
3134a81fca
Bug 1079139: make nsFlowAreaRect.mRect a LogicalRect. r=jfkthame
2014-10-19 12:32:17 -07:00
Simon Montagu
3f0d7f2fcc
Bug 1062963 patch 3: make nsFloatManager's origin a LogicalPoint, adapt GetFlowAreas, AddFloats, ClearFloats, etc. to use it and make nsFloatManager region functions work with logical region. r=jfkthame
2014-10-19 12:32:17 -07:00
Mats Palmgren
0ddbded605
Bug 1042489 - Call DrainOverflowColumns() to pick up any overflow frames from our prev-in-flow. r=roc
2014-08-25 04:25:00 +02:00
Simon Montagu
18c9f2f61a
Bug 789096 patch 10: make Reflow set nsHTMLReflowMetrics.ISize and BSize instead of Width and Height. r=jfkthame
2014-07-24 01:30:07 -07:00
Simon Montagu
c3b44c4dad
Bug 789096 patch 9: use logical coordinates in nsHTMLReflowState available size. r=jfkthame
2014-07-24 01:28:46 -07:00
Simon Montagu
f3e261c3a0
Bug 789096 patch 7: Use logical coordinates in nsBlockReflowContext. r=jfkthame
2014-06-17 07:41:35 -07:00
Mats Palmgren
75bad2215e
Bug 508665 - part 9, Remove now redundant static_cast<nsContainerFrame*> and do_QueryFrame() calls. r=roc
2014-05-24 22:20:40 +00:00
Mats Palmgren
9795aca511
Bug 1008917 - part 2,3,4, make Reflow() return type 'void', and make a few reflow related helper methods 'void' too. r=roc
2014-05-13 00:47:52 +00:00
Wes Kocher
42253715d7
Backed out 11 changesets (bug 1008917) for apparently introducing an intermittent failure of B2G Crashtest-2 on a CLOSED TREE
...
Backed out changeset e2ab653f688a (bug 1008917)
Backed out changeset b52154d8d900 (bug 1008917)
Backed out changeset 2ab5b01da4de (bug 1008917)
Backed out changeset f7a38df1d44f (bug 1008917)
Backed out changeset 80304bb9a572 (bug 1008917)
Backed out changeset 10ed89a302e9 (bug 1008917)
Backed out changeset 161c41991d46 (bug 1008917)
Backed out changeset 25b2475d2368 (bug 1008917)
Backed out changeset b8000b31277c (bug 1008917)
Backed out changeset 9afa5e7715e1 (bug 1008917)
Backed out changeset 5c380c21351f (bug 1008917)
2014-05-12 15:47:41 -07:00
Mats Palmgren
a722b491f1
Bug 1008917 - part 2,3,4, make Reflow() return type 'void', and make a few reflow related helper methods 'void' too. r=roc
2014-05-12 17:40:28 +00:00
Simon Montagu
f8a68ec80e
Make nsLineBox.mBounds a LogicalRect. Bug 789096, r=jfkthame
2014-04-16 01:03:28 -07:00
Simon Montagu
2110ef8dc6
Use logical text layout API in nsLineLayout. Bug 789096, r=jfkthame
2014-03-11 13:23:50 -07:00
Carsten "Tomcat" Book
b99f5df532
Backed out changeset aeff4052ef00 (bug 789096)
2014-03-11 09:22:52 +01:00
Simon Montagu
5e0cf76c45
Use logical text layout API in nsLineLayout. Bug 789096, r=jfkthame
2014-03-10 22:19:03 -07:00
Daniel Holbert
03c54ea5eb
Bug 967287 part 1: Remove unnecessary nsPresContext* argument from functions defined in nsContainerFrame.h. r=mats
2014-02-06 14:07:47 -08:00
Peiyong Lin
14bf63554d
Bug 959874 - Reorder two parameters in nsContainerFrame::FinishReflowChild(), for consistency with nsContainerFrame::ReflowChild(). r=dholbert
2014-01-16 17:34:44 -08:00
Jonathan Kew
a7837e1ffa
bug 735577 - pt 4.1 - use accessor functions for some physical-coordinate fields in nsHTMLReflowMetrics, in preparation for logicalization. r=smontagu
2013-12-27 17:59:52 +00:00
Jonathan Kew
954a119d07
bug 735577 - pt 3.2 - update the rest of layout code to use the new accessors on nsHTMLReflowState. r=smontagu
2013-12-27 17:59:21 +00:00