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

41 Коммитов

Автор SHA1 Сообщение Дата
Emilio Cobos Álvarez dad3a20b22 Bug 1525955 - Include anon boxes in CSSPseudoElementType, to remove ComputedStyle::mPseudoTag. r=heycam
This is more consistent with what the Rust bits of the style system do, and
removes a pointer from ComputedStyle which is always nice.

This also aligns the Rust bits with the C++ bits re. not treating xul pseudos as
anonymous boxes. See the comment in nsTreeStyleCache.cpp regarding those.

Can't wait for XUL trees to die.

Depends on D19001

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

--HG--
extra : moz-landing-system : lando
2019-02-19 13:44:33 +00:00
Emilio Cobos Álvarez d2ed260822 Bug 1517241 - Rename nsIDocument to mozilla::dom::Document. r=smaug
Summary: Really sorry for the size of the patch. It's mostly automatic
s/nsIDocument/Document/ but I had to fix up in a bunch of places manually to
add the right namespacing and such.

Overall it's not a very interesting patch I think.

nsDocument.cpp turns into Document.cpp, nsIDocument.h into Document.h and
nsIDocumentInlines.h into DocumentInlines.h.

I also changed a bunch of nsCOMPtr usage to RefPtr, but not all of it.

While fixing up some of the bits I also removed some unneeded OwnerDoc() null
checks and such, but I didn't do anything riskier than that.
2019-01-03 17:48:33 +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
Brian Birtles 043ffca9de Bug 1483404 - Move conversion of CompositeOperation enum types to KeyframeUtils::GetAnimationPropertiesFromKeyframes; r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D3457

--HG--
extra : moz-landing-system : lando
2018-08-16 16:24:52 +00:00
Brian Birtles 29e984d336 Bug 1483404 - Use "auto" values for unspecified keyframe-specific composite operations; r=smaug
Summary:
This brings our implementation into line with the following spec change:

  ced6b5aac0

See https://github.com/w3c/csswg-drafts/issues/3000

Reviewers: smaug

Tags: #secure-revision

Bug #: 1483404

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

--HG--
extra : rebase_source : 097d8307cea82b5d1ea0345414153965067b2b5b
extra : amend_source : fe1f4aeef842961600fe3dba760a573ed2fc84df
2018-08-15 09:51:28 +09:00
Hiroyuki Ikezoe 437d6b5387 Bug 1412716 - De-templatize EffectCompositor::UpdateEffectProperties and relevant stuff. r=emilio
MozReview-Commit-ID: K8yb8Kw16Mr

--HG--
extra : rebase_source : b5153f46ecd0352496b6222c847ef5663aff6ab7
2018-04-09 20:15:59 +09:00
Xidorn Quan 0401ef821e Bug 1447828 part 1 - Remove StyleBackendType uses from dom/animation. r=emilio
MozReview-Commit-ID: 3INWUuocNPm

--HG--
extra : rebase_source : 1e024084e325b075b3c1b534b544092d7f792e2e
extra : source : 1bcf22436ced3f5b2afd6a7db4250ff5b79f71c0
2018-03-29 02:29:42 +11: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
Brian Birtles 0fec9ac501 Bug 1425548 - Update references to Web Animations spec in dom/animation; r=hiro
MozReview-Commit-ID: 1f2Mz0VhnBm

--HG--
extra : rebase_source : 30c952ed20ee64810d225e5778650dd01791964d
2017-12-15 14:55:08 -06:00
Boris Chiou 570057e075 Bug 1408303 - Part 3: Move several Servo parsers into ServoCSSParser helper class. r=heycam
We have ServoCSSParser class, and I think it's better to move those
Servo FFI into this class to avoid including ServoBindings.h everywhere.

MozReview-Commit-ID: 6orXtddp9ZU

--HG--
extra : rebase_source : 6da4158c4fec606aaee49fddee3192f94d6c85a3
2017-12-01 17:35:47 +08:00
Manish Goregaokar 26f3a98f78 Bug 1382017 part 4 Gecko piece - Remove usage of ServoComputedValues from most Gecko code; r=xidorn
MozReview-Commit-ID: 2NB4DgxMrL3
2017-07-20 17:27:05 -07:00
Cameron McCormack 9654eabe7f Bug 1380133 - Part 1: Minor reformatting and encapsulation. r=emilio
MozReview-Commit-ID: 3hmptLbxxok
---
 dom/animation/KeyframeUtils.h      |  2 +-
 layout/style/ServoBindings.cpp     | 24 +++++++++++++++---------
 layout/style/ServoStyleContext.cpp | 21 ++++++++++++---------
 layout/style/ServoStyleContext.h   | 33 ++++++++++++++-------------------
 layout/style/ServoTypes.h          | 24 ++++++++++++++----------
 layout/style/nsAnimationManager.h  |  7 +++----
 6 files changed, 59 insertions(+), 52 deletions(-)

--HG--
extra : rebase_source : 150278b5f7429986e79976ec9faf290db6de86c0
2017-07-21 11:42:42 +08:00
Boris Chiou 855f40d72b Bug 1339690 - Part 6: Move GetComputedKeyframeValues into local static. r=birtles
MozReview-Commit-ID: Ay3i9fDSbVg

--HG--
extra : rebase_source : 9d1de95cf15a0882fd50feb55878758c419d66ae
2017-06-14 12:51:27 +08:00
Boris Chiou 02bf8062fe Bug 1339690 - Part 4: Rename ApplyDistributeSpacing to DistributeKeyframes. r=birtles
There is no spacing mode any more, so rename this function.

MozReview-Commit-ID: 9DIqKmQnuJo

--HG--
extra : rebase_source : 3600be87a699a1a5fe237f8ed75baf03f0b5ae84
2017-06-15 10:47:32 +08:00
Boris Chiou f8dbd6bb32 Bug 1339690 - Part 3: Drop spacing mode. r=birtles,smaug
MozReview-Commit-ID: 1c7jpzWQjVP

--HG--
extra : rebase_source : 7850e290abb5fd87684c99710666c881eb777eb4
2017-06-13 15:09:19 +08:00
Brian Birtles 22d0b7d971 Bug 1371518 - Make KeyframeUtils::IsAnimatable consult the Servo backend; r=hiro
When styling with the Servo backend, we should also use the Servo backend to
determine if a property is animatable or not. However, if we do this,
Servo_Property_IsAnimatable will start returning true for the 'display' property
once we mark that as animatable in Servo (for SMIL).

Even if we later fail to actually animate 'display' (due checks added to Servo
in the next patch) we still need to treat 'display' as un-animatable in
KeyframeUtils so that we don't *read* the 'display' property of Keyframe objects
passed to the Animations API, since that is observable.

This patch makes us consult Servo_Property_IsAnimatable when using the Servo
backend and also explicitly treat the 'display' property as not animatable.

MozReview-Commit-ID: 1JllbeJisAS

--HG--
extra : rebase_source : d73b7d9ee0da03bfed68e574b67e10b342c1868d
2017-06-14 15:23:45 +09:00
Hiroyuki Ikezoe 14e0273b91 Bug 1367293 - Don't get parent style for GetComputedKeyframeValuesFor. r=birtles
MozReview-Commit-ID: 7WjsO7P2QGz

--HG--
extra : rebase_source : b9d2d672dd670f54174a5811c7d28efe268c0c4d
2017-06-02 09:38:54 +09:00
Boris Chiou c78d90ed63 Bug 1346052 - Part 1: Factor out ParseProperty. r=birtles
We can reuse ParseProperty in nsDOMWindowUtils::ComputeAnimationDistance(),
so factor out this function.

MozReview-Commit-ID: FdXGPxOZf84

--HG--
extra : rebase_source : 525bb436fdc1ce4d1241a08b198f9cd572506a86
2017-03-24 17:35:27 +08:00
Boris Chiou 5fdc3654b4 Bug 1349124 - Replace ServoComputedStyleValues with ServoComputedValuesWithParent. r=hiro
MozReview-Commit-ID: 5POa8DRjmc8

--HG--
extra : rebase_source : 5a88f1c30c32dcd6bb728707c066a4b8becfc311
2017-03-21 15:41:23 +08:00
Hiroyuki Ikezoe c7df70030a Bug 1338927 - Part 4: Templatize BuildProperties(). r=birtles
We'd like to use template to manage functions that have almost the same functionality
both on stylo and gecko instead of branching in each functions because it will be
easier to maintain stylo and gecko for a while.

MozReview-Commit-ID: 25ukMpOeqLj

--HG--
extra : rebase_source : 145b66695f9772f5cb527bbcf15b5a3fc2e34510
2017-02-23 09:52:44 +09:00
Hiroyuki Ikezoe b5a2377fb5 Bug 1338927 - Part 3: Introduce ServoComputedStyleValues. r=birtles
The operator bool() will be used in the case where we call
MOZ_ASSERT() for const ref of this struct.

MozReview-Commit-ID: tCtpXmPJvV

--HG--
extra : rebase_source : f878c49ab93d8173f9de99b500efc280db886ea3
2017-02-23 09:52:43 +09:00
Hiroyuki Ikezoe 64f3fa3651 Bug 1338927 - Part 2: Generate ComputedKeyframeValues array from servo's computed values. r=birtles,manishearth
Servo_GetComputedKeyframeValues is almost the same as what we do in
KeyframeUtils::GetComputedKeyframeValues() for Gecko. Unlike the function
for Gecko, this function does not allocate each ComputedKeyframeValues element,
the allocation has been done before calling Servo_GetComputedKeyframeValues.

MozReview-Commit-ID: LRbriWoal2l

--HG--
extra : rebase_source : 785bb1bc6a62a2f9764fff09f5047942855e3c25
2017-02-23 09:52:43 +09:00
Hiroyuki Ikezoe 5de465377c Bug 1338927 - Part 1: Drop nsStyleContext argument from KeyframeUtils::GetAnimationPropertiesFromKeyframes. r=birtles
It's not used at all.

MozReview-Commit-ID: 2vAmlDhp12G

--HG--
extra : rebase_source : e1f9b226ff4d3fdd6f6bb6b03d6b157c5d153598
2017-02-23 09:52:43 +09:00
Hiroyuki Ikezoe 1f8b99b847 Bug 1305325 - Part 6: Handle missing keyframe whose offset 0 or 1 on the main thread. r=birtles
MozReview-Commit-ID: 5WMiTJQKfZd

--HG--
rename : dom/animation/test/chrome/test_animation_properties.html => dom/animation/test/chrome/test_simulate_compute_values_failure.html
2016-12-04 08:07:40 +09:00
Boris Chiou 304026cd9d Bug 1272549 - Part 9: Compute distance for mismatched transform lists. r=birtles
MozReview-Commit-ID: JJWcMgj88GX

--HG--
extra : rebase_source : 3f1c314a2bf9c7c12991fb3873738c79b0152ea9
2016-10-05 15:36:16 +08:00
Brian Birtles 732a6955f2 Bug 1300045 part 1 - Tidy up some missing includes r=hiro
I came across these while working on a different bug that changed the grouping
in the unified build. Adding these as a separate step will hopefully remove a
little noise from the next patch in the series.

MozReview-Commit-ID: Km7wTcVWG9n

--HG--
extra : rebase_source : 0610add67482c1a5aa7c4f576e151ed9437698c0
2016-09-04 16:33:38 +09:00
Jonathan Chan 4b87f11bd9 Bug 1293739 - Part 1: Rename nsCSSProperty to nsCSSPropertyID. r=dholbert
This patch is generated by the following commands (note: if you're running
using OS X's sed, which accepts slightly different flags, you'll have to
specify an actual backup suffix in -i, or use gsed from Homebrew):

  hg stat -c \
  | cut -c 3-  \
  | tr '\n' '\0' \
  | xargs -0 -P 8 gsed --follow-symlinks 's/\bnsCSSProperty\b/nsCSSPropertyID/g' -i''

Then:

  hg mv layout/style/nsCSSProperty.h layout/style/nsCSSPropertyID.h

... and finally, manually renaming nsCSSProperty in the include guard in
nsCSSProperty.h.

MozReview-Commit-ID: ZV6jyvmLfA

--HG--
rename : layout/style/nsCSSProperty.h => layout/style/nsCSSPropertyID.h
2016-08-16 18:37:48 -07:00
Gregory Szorc 1794619188 Backed out changesets dcdb85fc5517, 702bca0deee2, 9cKX8gC1ATA (bug 1293739) for build bustage; a=bustage
The merge from inbound to central conflicted with the merge from
autoland to central, it appears. Per tree rules, the commit from the
autoland repo wins and the inbound commit gets backed out.

CLOSED TREE

--HG--
extra : amend_source : 927e1cdfa8e55ccbd873d404d905caf6871c8c4f
extra : histedit_source : 07095868c3f767258e1d7d2645193bf4811b13bb%2Ca49ae5a28bf6e67298b6208ee9254c25a2539712
2016-08-16 17:50:40 -07:00
Jonathan Chan 9c62a2c11c Bug 1293739 - Part 1: Rename nsCSSProperty to nsCSSPropertyID. r=dholbert
This patch is generated by the following commands (note: if you're running
using OS X's sed, which accepts slightly different flags, you'll have to
specify an actual backup suffix in -i, or use gsed from Homebrew):

  hg stat -c \
  | cut -c 3-  \
  | tr '\n' '\0' \
  | xargs -0 -P 8 gsed --follow-symlinks 's/\bnsCSSProperty\b/nsCSSPropertyID/g' -i''

Then:

  hg mv layout/style/nsCSSProperty.h layout/style/nsCSSPropertyID.h

... and finally, manually renaming nsCSSProperty in the include guard in
nsCSSProperty.h.

MozReview-Commit-ID: ZV6jyvmLfA

--HG--
rename : layout/style/nsCSSProperty.h => layout/style/nsCSSPropertyID.h
2016-08-09 16:28:19 -07:00
Brian Birtles 7d054e7e89 Bug 1277456 part 5 - Pass the document associated with an AnimationEffectTiming/KeyframeEffect object to KeyframeUtils as the context to use when parsing CSS properties; r=hiro
Note that when we actually compute values, we will use the composed document of
the target element (see the next patch in this series).

MozReview-Commit-ID: 8Pp3y19pltP

--HG--
extra : rebase_source : bb1c21f3fdcf2e831213d2f278d70e4ca2637028
2016-07-13 13:22:25 +09:00
Boris Chiou 34e916b2cb Bug 1244590 - Part 7: Calculate paced spacing. r=birtles
Calculate the paced spacing for each Keyframes by the context element. Use the
algorithm in the spec.

MozReview-Commit-ID: HFWQwoKhKWt

--HG--
extra : rebase_source : 40112eb1f722179cfc0a4ccbd188e22bc7af9b9b
2016-05-27 18:09:06 +08:00
Boris Chiou 95267f5a26 Bug 1244590 - Part 6: Refactor the calculation of StyleAnimationValue. r=birtles
We want to reuse the StyleAnimationValues of properties of each keyframe when
applying spacing and building animation property segments, so refactor this
part.

MozReview-Commit-ID: 8G56C3BU3FR

--HG--
extra : rebase_source : 73b6d374ac8bd25645d1b1b2f15f4e778b3ec949
2016-05-25 17:10:53 +08:00
Boris Chiou 8c0079ef08 Bug 1244590 - Part 4: Rewrite ApplyDistributeSpacing. r=birtles
Rename it to ApplySpacing, and let it handle both distribute and paced mode.

MozReview-Commit-ID: 2kGA6LMHUsz

--HG--
extra : rebase_source : ebd5566392b1ea6a4a445ff7c3ed81cdc94bdded
2016-05-10 17:40:53 +08:00
Boris Chiou 03d90dd78b Bug 1244590 - Part 3: Parse spacing. r=birtles
We only support spacing mode from Web Animations API, so add a simple parser and
use it only from the API. In this patch, parse spacing mode from the constructor
and throw TypeError if we have any parse error.

MozReview-Commit-ID: 9H7g80IcZfZ

--HG--
extra : rebase_source : e1bc781ff0f20a1a38c04e672832ec013edc549d
2016-05-13 16:38:25 +08:00
Brian Birtles 119a18fee3 Bug 1245748 - Remove no-longer-needed code for directly setting up properties in KeyframeEffect(ReadOnly) constructor; r=heycam
MozReview-Commit-ID: 4V3LMByas9Q

--HG--
extra : rebase_source : c2c687cd39b8287e7e9cb2a4edd12c86a056a0de
2016-03-22 16:36:45 +09:00
Brian Birtles 1cf303b56f Bug 1245748 - Add ApplyDistributeSpacing for Keyframe objects; r=heycam
MozReview-Commit-ID: 8KNERsl8tea

--HG--
extra : rebase_source : e48ca76aea6e93722f285bf59a8696d6a102bf99
2016-03-22 16:35:53 +09:00
Brian Birtles 93bd57b41f Bug 1245748 - Add GetAnimationPropertiesFromKeyframes; r=heycam
MozReview-Commit-ID: GUnogloqViS

--HG--
extra : rebase_source : ba999c9f9bf18683b7942dfefe0c0242124af474
2016-03-22 16:34:14 +09:00
Brian Birtles 67707b72eb Bug 1245748 - Add KeyframeUtils::GetKeyframesFromObject; r=heycam
MozReview-Commit-ID: 2cl8NIMApSy

--HG--
extra : rebase_source : f0cafad483afcf36efa86f6fa137bbffd068bcb5
2016-03-22 16:25:38 +09:00
Brian Birtles 9ccb67c08b Bug 1245748 - Move keyframe handling code to a separate KeyframeUtils class; r=heycam
MozReview-Commit-ID: 2r27vCLcOhs

--HG--
extra : rebase_source : 6ba24ece944543e250728cf2b18370c277e746d0
2016-03-22 16:20:37 +09:00