Граф коммитов

55 Коммитов

Автор SHA1 Сообщение Дата
Masayuki Nakano 2f9688c14e Bug 1544343 - part 2: Make factory methods take mozilla::PresShell instead of nsIPresShell r=emilio
Additionally, this patch makes `nsFrame.h` stop including `nsIPresShell.h`
and makes each users include `mozilla/PresShell.h` instead.  So, this improves
rebuild performance of `nsIPresShell.h` (and `mozilla/PresShell.h` in the
future).

Note that due to `nsIFrame::PresShell()`, `mozilla::` prefix is necessary for
`PresShell` in a lot of classes which are derived from `nsIFrame` even in
`.cpp` files.

Differential Revision: https://phabricator.services.mozilla.com/D27476

--HG--
extra : moz-landing-system : lando
2019-04-16 07:24:49 +00:00
Emilio Cobos Álvarez 12867b1a3f Bug 1525371 - Kill ComputedStyle::mPresContext, move the pointer to the frame instead. r=jwatt
Differential Revision: https://phabricator.services.mozilla.com/D18734
2019-02-07 11:15:36 +01:00
Sylvestre Ledru 265e672179 Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format
# ignore-this-changeset

--HG--
extra : amend_source : 4d301d3b0b8711c4692392aa76088ba7fd7d1022
2018-11-30 11:46:48 +01:00
Emilio Cobos Álvarez e341b20ec4 Bug 1447483: Merge nsStyleContext and ServoStyleContext, rename to ComputedStyle. r=jwatt on a CLOSED TREE
MozReview-Commit-ID: JPopq0LudD
2018-03-22 20:06:24 +01:00
Emilio Cobos Álvarez 5dd797f154 Back out changeset b683bb3f22a1 (Bug 1447483) for not landing with all the files. r=me on a CLOSED TREE
This reverts commit 1808914126bb9f9e4a82d2c3d7ac961885fe7d62.

MozReview-Commit-ID: 5skESBseEvo
2018-03-22 20:05:22 +01:00
Emilio Cobos Álvarez ca5ac79cca Bug 1447483: Merge nsStyleContext and ServoStyleContext, rename to ComputedStyle. r=jwatt
MozReview-Commit-ID: JPopq0LudD
2018-03-22 19:48:42 +01:00
Daniel Holbert 680815cd6e Bug 1412346 part 5: (automated patch) Switch a bunch of C++ files in layout to use our standard mode lines. r=jfkthame
This patch was generated automatically by the "modeline.py" script, available
here: https://github.com/amccreight/moz-source-tools/blob/master/modeline.py

For every file that is modified in this patch, the changes are as follows:
 (1) The patch changes the file to use the exact C++ mode lines from the
     Mozilla coding style guide, available here:
https://developer.mozilla.org/en-US/docs/Mozilla/Developer_guide/Coding_Style#Mode_Line

 (2) The patch deletes any blank lines between the mode line & the MPL
     boilerplate comment.

 (3) If the file previously had the mode lines and MPL boilerplate in a
     single contiguous C++ comment, then the patch splits them into
     separate C++ comments, to match the boilerplate in the coding style.

MozReview-Commit-ID: EuRsDue63tK

--HG--
extra : rebase_source : 3356d4b80ff6213935192e87cdbc9103fec6084c
2017-10-27 10:33:53 -07:00
Daniel Holbert a7f82bed77 Bug 1412346 part 4: Update stale MPL license boilerplate on a few files in layout. r=jfkthame
We have a fair number of files that have a particular stale version of the MPL
boilerplate.  (It was probably originally correct, and then the official
boilerplate changed, and the stale MPL boilerplate continued to propagate via
copypasting from neighboring files into newly-added files.)

This patch updates this stale MPL text (and *only* the MPL text) to the latest
version, which can be found at https://www.mozilla.org/en-US/MPL/headers/ and
https://developer.mozilla.org/en-US/docs/Mozilla/Developer_guide/Coding_Style#Mode_Line

MozReview-Commit-ID: 8WeBb8b0uRo

--HG--
extra : rebase_source : 2c3aa8d07ba23714501c9e26ad03625aeab36a7a
2017-10-27 10:09:35 -07:00
Alexis Beingessner adb013669b Bug 1088760 - Remove nsRenderingContext, replacing all of its uses with gfxContext. r=jwatt,jrmuizel
MozReview-Commit-ID: K1WUIOnvazF
2017-06-13 11:00:10 -04:00
Sebastian Hengst f3bf820bfd Backed out changeset 3d1ce85e6348 (bug 1088760) for bustage, at least on Android at layout/generic/nsPluginFrame.cpp:1612. r=backout 2017-06-13 00:30:03 +02:00
Alexis Beingessner c75211cb95 Bug 1088760 - Remove nsRenderingContext, replacing all of its uses with gfxContext. r=jwatt,jrmuizel
MozReview-Commit-ID: K1WUIOnvazF
2017-06-12 17:32:48 -04:00
Mats Palmgren a254b64145 Bug 1364805 part 4 - Remove the now unused LayoutFrameType values from the ctors. r=jfkthame
MozReview-Commit-ID: 1RSDoc3pQXf
2017-05-26 12:11:11 +02:00
Mats Palmgren 1242172259 Bug 1364805 part 2 - Add a nsIFrame::mClass field and propagate the concrete class' value up the ctor chain. r=jfkthame
nsIFrame::mClass is of type enum class nsQueryFrame::ClassID which is
a strict subset of the nsQueryFrame::FrameIID values.  For a concrete
frame class, its FrameIID is the same numeric value as its ClassID.

MozReview-Commit-ID: 1N0AkCGo1ol
2017-05-26 12:11:11 +02:00
Mats Palmgren ec6b1ef065 Bug 1364805 part 1 - Make every concrete frame class be a NS_DECL_QUERYFRAME_TARGET. r=jfkthame
MozReview-Commit-ID: Gy9gcEYupeY
2017-05-26 12:11:11 +02:00
Emilio Cobos Álvarez 23bce99ae1 Bug 1361051: rename mozilla::FrameType to mozilla::LayoutFrameType. r=xidorn
This avoids conflicts with mozilla::dom::FrameType.

MozReview-Commit-ID: 7aEMbHRaTFk

--HG--
extra : rebase_source : 2d01321f5ce0ec8c0e3f70984674f82678034b3c
2017-05-01 19:32:52 +02:00
Emilio Cobos Álvarez e44543aad4 Bug 1360241: Devirtualize nsIFrame::GetType. r=heycam
MozReview-Commit-ID: 5Nzhyta5Hle

--HG--
extra : rebase_source : c2e9d4bfb9239f5e851d110cd7dff98c1e1a8d8b
2017-04-30 17:30:08 +02: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
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 7a5825e82f Bug 1277129 Part 7a - Rename ReflowState to RubyReflowInput in nsRubyBaseContainerFrame. r=dbaron
This is a prerequisite for the mass rename variables whose name
containing ReflowState in the next patch. Otherwise
nsRubyBaseContainerFrame::ReflowInput will conflict with
mozilla::ReflowInput.

MozReview-Commit-ID: KUU51Rjn6z

--HG--
extra : rebase_source : fcb3aefaea40f57e59cc81349b9fcc0f3a88394a
2016-07-21 18:36:38 +08:00
Ting-Yu Lin 4053c4c028 Bug 1277129 Part 5c - Rename nsHTMLReflowMetrics to ReflowOutput. 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 "nsHTMLReflowMetrics" "ReflowOutput"

MozReview-Commit-ID: 2HBb7DkooH5

--HG--
extra : rebase_source : acfa442a6483772fcb5748dc6f5e7072e599032a
2016-07-21 18:36:38 +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
Xidorn Quan 1ed71b2fe7 Backed out 8 changesets (bug 1225018, bug 1229278, bug 1224013) for reftest failures on CLOSED TREE
--HG--
extra : amend_source : ee1d38ab6715e193cb1462614b3395c96ca06a0c
extra : histedit_source : 65b6dcb58b89c3cbcfe9a47834baf3181a2990c8%2Cc19e313c6800de1a1906c0db2f2bd4680fe67b78
2015-12-04 13:08:17 +11:00
Xidorn Quan 45ebb9aa0e Bug 1224013 part 2 - Move leading fix to ruby base container. r=dholbert
Per spec, the additional leading is added on side of ruby base container, not
ruby container. This could lead to some trivial behavior changes on edge cases.

--HG--
extra : source : 495e466ebdb628fecd9a546b539001ac316fc133
2015-12-04 12:02:41 +11:00
Birunthan Mohanathas a8939590de Bug 1182996 - Fix and add missing namespace comments. rs=ehsan
The bulk of this commit was generated by running:

  run-clang-tidy.py \
    -checks='-*,llvm-namespace-comment' \
    -header-filter=^/.../mozilla-central/.* \
    -fix
2015-07-13 08:25:42 -07:00
Xidorn Quan 59d1864c8a Bug 1141931 part 7 - Move [Auto]RubyTextContainerArray to RubyUtils and merge RubyTextContainerIterator into AutoRubyTextContainerArray. r=dholbert
--HG--
extra : source : 89ae2f9a195fe10f4db19d0a51fd3ec7bafb0ecc
2015-04-08 11:22:34 +12:00
Xidorn Quan 966ef97045 Bug 1141931 part 6 - Move Ruby{Segment,Column}Enumerator to RubyUtils. r=dholbert
--HG--
extra : source : 2327584c7a0740617388bc544d2bb8433d034fe7
2015-04-08 11:22:34 +12:00
Xidorn Quan ddd0a788fa Bug 1141931 part 5 - Eliminate unnecessary includes in header files of ruby frames. r=dholbert
--HG--
extra : source : 860c66b5f319ed0744decf84c8c2145efd85ce83
2015-04-08 11:22:34 +12:00
Wes Kocher 74f58c915e Backed out 10 changesets (bug 1141931) for mochitest-5 failures CLOSED TREE
Backed out changeset c90940067de6 (bug 1141931)
Backed out changeset 96b48288abab (bug 1141931)
Backed out changeset 87281c7ded34 (bug 1141931)
Backed out changeset 6a914ba0b8ec (bug 1141931)
Backed out changeset 9cfea55b5e95 (bug 1141931)
Backed out changeset f432612b6475 (bug 1141931)
Backed out changeset 48cf9568a4b1 (bug 1141931)
Backed out changeset f1ab848b3fa6 (bug 1141931)
Backed out changeset 8a3c71a3b525 (bug 1141931)
Backed out changeset 119d3c0fd0f6 (bug 1141931)
2015-04-07 14:23:57 -07:00
Xidorn Quan 53a7f5a9f8 Bug 1141931 part 7 - Move [Auto]RubyTextContainerArray to RubyUtils and merge RubyTextContainerIterator into AutoRubyTextContainerArray. r=dholbert
--HG--
extra : source : 89ae2f9a195fe10f4db19d0a51fd3ec7bafb0ecc
2015-04-08 08:40:31 +12:00
Xidorn Quan 1bbf61d898 Bug 1141931 part 6 - Move Ruby{Segment,Column}Enumerator to RubyUtils. r=dholbert
--HG--
extra : source : 2327584c7a0740617388bc544d2bb8433d034fe7
2015-04-08 08:40:31 +12:00
Xidorn Quan 27d78f6b41 Bug 1141931 part 5 - Eliminate unnecessary includes in header files of ruby frames. r=dholbert
--HG--
extra : source : 860c66b5f319ed0744decf84c8c2145efd85ce83
2015-04-08 08:40:31 +12:00
Ehsan Akhgari 883849ee32 Bug 1145631 - Part 1: Replace MOZ_OVERRIDE and MOZ_FINAL with override and final in the tree; r=froydnj
This patch was automatically generated using the following script:

function convert() {
echo "Converting $1 to $2..."
find . \
       ! -wholename "*/.git*" \
       ! -wholename "obj-ff-dbg*" \
         -type f \
      \( -iname "*.cpp" \
         -o -iname "*.h" \
         -o -iname "*.c" \
         -o -iname "*.cc" \
         -o -iname "*.idl" \
         -o -iname "*.ipdl" \
         -o -iname "*.ipdlh" \
         -o -iname "*.mm" \) | \
    xargs -n 1 sed -i -e "s/\b$1\b/$2/g"
}

convert MOZ_OVERRIDE override
convert MOZ_FINAL final
2015-03-21 12:28:04 -04:00
Xidorn Quan 7969797ad3 Bug 1055658 part 4 - Revert RubyReflowState. r=dbaron
--HG--
extra : source : 27e60ddbd077439dadd09641ab54fc7eef09c69f
2015-01-13 20:04:41 +11:00
Nigel Babu 053a7d3408 Backed out 4 changesets (bug 1055658) for M5 bustage on a CLOSED TREE
Backed out changeset 3cbd9323c896 (bug 1055658)
Backed out changeset 99e071295c42 (bug 1055658)
Backed out changeset 55119d19e4c5 (bug 1055658)
Backed out changeset e82f640cb53f (bug 1055658)
2015-01-12 10:43:11 +05:30
Xidorn Quan 6ba35e648b Bug 1055658 part 4 - Revert RubyReflowState. r=dbaron
--HG--
extra : source : 27e60ddbd077439dadd09641ab54fc7eef09c69f
2015-01-12 14:31:55 +11:00
Xidorn Quan 3013e06e68 Bug 1116037 part 11 - Add RubyReflowState for sharing states between ruby level boxes. r=dbaron
--HG--
extra : source : c4f342ece9c1548053348dbc317d9857cbe790b6
2014-12-30 11:16:30 +11:00
Xidorn Quan 09350f0596 Bug 1116037 part 10 - Remove mColumnCount from nsRubyBaseContainerFrame. r=dbaron
--HG--
extra : source : 36096895ec5437c5f9cf6c97d6085bfeae8654c7
2014-12-30 10:05:54 +11:00
Xidorn Quan eb1ae2b722 Bug 1116037 part 9 - Move ruby text container arrays to stack. r=dbaron
--HG--
extra : source : 6c5d7212c3f8c355b4667aa46024dfef0710ca8e
2014-12-30 09:56:34 +11:00
Xidorn Quan 62bf8b83b1 Bug 1116037 part 8 - Merge two ruby text container arrays. r=dbaron
--HG--
extra : source : 2b3f8e1951d924c14c94c06a44012837b51a04ad
2014-12-30 09:44:12 +11:00
Xidorn Quan a33cdf1a4e Bug 1116037 part 6 - Use a single struct to represent ruby column. r=dbaron
--HG--
extra : source : 7b927cec3f77e194b37de15e3a5b93aa70925d3c
2014-12-29 15:22:19 +11:00
Xidorn Quan c7868a4f13 Bug 1116037 part 5 - Use unified struct for ruby reflow states. r=dbaron
--HG--
extra : source : 1c4bb2775ab5e26f34fb260daf12afdf86debe30
2014-12-29 15:03:38 +11:00
Xidorn Quan 259342b408 Bug 1116037 part 4 - Remove useless parameters in ruby reflow methods. r=dbaron
--HG--
extra : source : d712ee74e0f33f39b103e88753587559d0a0e9ed
2014-12-29 14:46:24 +11:00
Xidorn Quan b48d600a85 Bug 1116037 part 3 - Use ruby "column" instead of "pair" to match the spec term. r=dbaron
--HG--
extra : source : a7e31ed3d8d6933631729f014efb546844c84586
2014-12-29 14:30:00 +11:00
Xidorn Quan 17c1355146 Bug 1098272 part 6 - Check whether line break is allowed in ruby. r=dbaron
--HG--
extra : rebase_source : e016ab26fa8c22568d2310c17f34c4e1013373a2
extra : source : 7899fcd7c6f9059fdbf7417274f9181ed71d1e50
2014-12-22 16:52:30 +11:00
Xidorn Quan 4f414b3c98 Bug 1098272 part 4 - Remove unused parameter of nsRubyBaseContainerFrame::ReflowSpans. r=dbaron
--HG--
extra : rebase_source : ae32a99dbaf9faaad19f54ebba6e8d2e49a955a7
extra : source : 99bbfb3dce962504d1014e632c4b4b7f19a00276
2014-12-22 16:32:14 +11:00
Xidorn Quan e464df4013 Bug 1052924 - Implement basic line breaking for ruby. r=dbaron
Known problem:
It would cause infinite loop if there is any line break happens inside
ruby base or annotation, or the width of container is not enough for
the widest pair/span. This might be fixed in bug 1098272.
2014-11-26 15:52:50 +11:00
Xidorn Quan 5f4cd8dd0b Bug 1052924 - Separate reflow code. r=dbaron 2014-11-26 15:52:50 +11:00
Xidorn Quan 43f5510c25 Bug 1052924 - Give rbc & rtc correct position. r=dbaron
Important changes:
  * Use line layout to reflow ruby base container
2014-11-26 15:52:49 +11:00
Xidorn Quan d25178b0db Bug 1052924 - Resolve some warnings. r=dbaron
Important changes:
  * Change base class of nsRuby{Base,Text}Frame to nsInlineFrame
  * Make ComputeSize of nsRubyFrame and nsRubyBaseContainerFrame behavior like inline frames
2014-11-26 15:52:49 +11:00
Xidorn Quan c25136319a Bug 1052924 - Rewrite reflow code. r=dbaron
Important changes:
  * Avoid using GetPrefISize on the ruby texts in
    nsRubyBaseContainerFrame::Reflow, since the size it produces might
    not match the size produced by Reflow.  The old code calls that on
    all the ruby texts to determine how big they are, then reflows all
    the ruby bases, and then reflows all the ruby texts.  The new code
    instead processes one pair at a time, and for each pair reflows the
    ruby texts and then the ruby base.
  * Change the base class of nsRubyTextContainerFrame from nsBlockFrame
    to nsContainerFrame, and stop constructing an nsBlockReflowState for
    its reflow.
  * Move the code for reflowing ruby texts from nsRubyTextContainerFrame
    and to nsRubyBaseContainerFrame.
  * Fix the regression that ruby text containers contain span are not
    reflowed properly. It is the regression introduced in patch 0.

Known regression:
  * This patch drops centering ruby base and annotation in pairs. This
    should be fixed in bug 1055676 (ruby-align).
2014-11-26 15:52:49 +11:00