Commit Graph

82 Commits

Author SHA1 Message Date
Xidorn Quan
c9a1c4a65c Bug 1407888 part 2 - Make ServoStyleRuleMap::FillTableFromStyleSheet not make unique inner. r=heycam
MozReview-Commit-ID: 1I7sawfjcnl
2017-10-12 18:56:02 +11:00
Phil Ringnalda
5f2bcd264d Backed out 2 changesets (bug 1407888) for aSheet->HasUniqueInner() assertion failures
CLOSED TREE

Backed out changeset 50e535750cc9 (bug 1407888)
Backed out changeset e1287860a439 (bug 1407888)

MozReview-Commit-ID: 8UHuO8Fz0pL
2017-10-12 19:59:50 -07:00
Xidorn Quan
8dc12d7dcf Bug 1407888 part 2 - Make ServoStyleRuleMap::FillTableFromStyleSheet not make unique inner. r=heycam
MozReview-Commit-ID: 1I7sawfjcnl
2017-10-12 18:56:02 +11:00
Tom Tromey
5132043cac Bug 1399911 - preserve sourceURL comment directive on style sheets; r=bz,heycam
In addition to the sourceMappingURL comment, there is a second special
comment, "sourceURL", that can be used to set the "display name" of a
style sheet for developer tools.  This name is also used as the base
URL for the source-map URL resolution algorithm.  sourceURL is
described here:
https://blog.getfirebug.com/2009/08/11/give-your-eval-a-name-with-sourceurl/

This patch changes Firefox to record this URL, if specified, and to
expose it (chrome-only) vai StyleSheet.webidl.

MozReview-Commit-ID: 7NwXsOf7nbY
2017-09-14 14:59:32 -06:00
Tom Tromey
7ccfa075fd Bug 1388855 - Extract source map URL when parsing CSS, r=bz,heycam
This changes the CSS lexer to extract sourceMappingURL directives from
comments and preserve them; then changes the parser to expose this value
as the style sheet's sourceMapURL.

MozReview-Commit-ID: LfMamJ1PsU0
2017-08-09 13:33:24 -06:00
Josh Matthews
34594ebaa7 Bug 1352669 - Hook up Stylo CSS parser to Gecko error reporter. r=emilio
MozReview-Commit-ID: 3r5Z6KiPgRM
2017-07-10 17:52:00 -04:00
Tom Tromey
5d536690db Bug 1306887 - keep SourceMap response header on CSS style sheets; r=bz,heycam
When loading a style sheet, if the SourceMap (or legacy X-SourceMap)
response header was seen, record it and make it available to chrome
scripts.

MozReview-Commit-ID: 3wtUADzgrI3
2017-06-28 16:51:46 -07:00
Wes Kocher
8cbe4b5d79 Backed out changeset f220d8060c14 (bug 1352669) for build bustage CLOSED TREE a=bustage
MozReview-Commit-ID: INYGT4WT1pO
2017-07-06 14:56:06 -07:00
Josh Matthews
6416600b5e Bug 1352669 - Hook up Stylo CSS parser to Gecko error reporter.
MozReview-Commit-ID: 3r5Z6KiPgRM
2017-07-06 13:15:08 -07:00
Xidorn Quan
7fbfb43629 Bug 1372790 - Change uint8_t to back some enum and reorder some fields in StyleSheet to make it more compact. r=heycam
MozReview-Commit-ID: DddIzhJqmcZ
2017-06-14 14:26:48 +10:00
Emilio Cobos Álvarez
e310a60d66 Bug 1372041: Refactor @import so it also respects the stylesheet's media properly. r=heycam
MozReview-Commit-ID: EBmd8nG877t
2017-07-02 17:19:08 +02:00
Xidorn Quan
c27fb6df6b Bug 1373484 - Drop all reference to StyleSheet when last strong reference is dropped. r=bz
MozReview-Commit-ID: 2RrNZDIjx3s
2017-06-19 10:15:49 +10:00
Phil Ringnalda
27dd6d760f Backed out changeset a5fe1b7f3dad (bug 1372790) for build bustage in nsCSSParser.cpp
CLOSED TREE

MozReview-Commit-ID: 3qoTERDArAo
2017-06-13 22:39:50 -07:00
Xidorn Quan
154deecdcc Bug 1372790 - Change uint8_t to back some enum and reorder some fields in StyleSheet to make it more compact. r=heycam
MozReview-Commit-ID: DddIzhJqmcZ
2017-06-14 14:26:48 +10:00
Emilio Cobos Álvarez
02e12853ab Bug 1368986: Cleanup stylesheet copy-constructor. r=heycam
MozReview-Commit-ID: I8vUuJfET24
2017-05-31 13:12:33 +02:00
Xidorn Quan
b134804bb8 Bug 1352968 part 8 - Construct @import rule object eagerly. r=heycam
MozReview-Commit-ID: HrgZnW21dHz
2017-05-30 11:10:25 +10:00
Xidorn Quan
08c91e75e4 Bug 1352968 part 7 - Make RuleHasPendingChildSheet a static method of StyleSheet. r=heycam
MozReview-Commit-ID: HPJgsFftT6f
2017-05-30 11:10:25 +10:00
Xidorn Quan
6a6b1408bb Bug 1352968 part 4 - Change the direction of child stylesheet list. r=heycam
It seems no one actually care about the order of the list, and the order
is completely meaningless if the script insert new @import rules.

Changing the order makes inserting faster, and make it easier for later
patch to get the latest inserted child sheet.

MozReview-Commit-ID: 72eKqVoPbZ7
2017-05-30 11:10:25 +10:00
Xidorn Quan
477205b2b5 Bug 1352968 part 2 - Move mOwnerRule to StyleSheet and use dom::CSSImportRule instead of css::ImportRule. r=heycam
MozReview-Commit-ID: DTAWGHIUAQX
2017-05-30 11:10:25 +10:00
Emilio Cobos Álvarez
b7a7a08a94 Bug 1357583: Remove ServoStyleSheet::ClearRuleCascades. r=heycam
These invalidations are already handled from the PresShell notifications, no
need to handle it somewhere else.

MozReview-Commit-ID: G9KDVvSKMJY
2017-05-29 23:01:26 +02:00
Emilio Cobos Álvarez
d94e8fcc32 Bug 1367553: Avoid import hell in StyleSheet.h. r=emilio
MozReview-Commit-ID: DR4xURkcFcA
2017-05-25 16:11:13 +02:00
Emilio Cobos Álvarez
f8a30f11ac Bug 1367553: Provide the kind of change that the stylesheet suffered to RecordStyleSheetChange. r=heycam
I plan to use it for now to force a full document restyle when a standalone rule
changes or something like that.

In practice, we can do better sometimes, and we may just want to propagate to
the StyleSet all the style change notifications in order to have access to the
rule that changed and all that...

But for now this seemed easier than adding other four or five functions to
StyleSetHandle.

MozReview-Commit-ID: 2BEIliGu4mO
2017-05-24 04:28:58 +02:00
Phil Ringnalda
3864eaed9a Backed out 2 changesets (bug 1367553) for build bustage
CLOSED TREE

Backed out changeset 3e6c9a752596 (bug 1367553)
Backed out changeset 1ee24478fa16 (bug 1367553)

MozReview-Commit-ID: B805jBJYcqL
2017-05-25 06:13:01 -07:00
Emilio Cobos Álvarez
84f97fc8cb Bug 1367553: Provide the kind of change that the stylesheet suffered to RecordStyleSheetChange. r=heycam
I plan to use it for now to force a full document restyle when a standalone rule
changes or something like that.

In practice, we can do better sometimes, and we may just want to propagate to
the StyleSet all the style change notifications in order to have access to the
rule that changed and all that...

But for now this seemed easier than adding other four or five functions to
StyleSetHandle.

MozReview-Commit-ID: 2BEIliGu4mO
2017-05-24 04:28:58 +02:00
Brad Werth
fdeacb1873 Bug 1339629 Part 10: Implement ServoStyleSet::EnsureUniqueInnerOnCSSSheets. r=heycam
MozReview-Commit-ID: GuUqKYrV60z
2017-05-15 17:11:08 -07:00
Brad Werth
84b701f39e Bug 1339629 Part 9: Uplift EnsureUniqueInnerOnCSSSheets and SetNeedsRestyleAfterEnsureUniqueInner into StyleSetHandle, and eliminate CSSStyleSheet::EnsureUniqueInner. r=heycam
MozReview-Commit-ID: LH7vTKUmuv8
2017-05-15 16:30:10 -07:00
Brad Werth
d5d552db30 Bug 1339629 Part 8: Uplift ClearRuleCascades into StyleSheet. r=heycam
MozReview-Commit-ID: CCYIYjWrw86
2017-05-18 14:21:11 -07:00
Brad Werth
26ed5d2848 Bug 1339629 Part 6: Uplift mStyleSets into StyleSheet. r=heycam
MozReview-Commit-ID: G8xQ5gLJ3dr
2017-05-15 16:27:15 -07:00
Brad Werth
720274de63 Bug 1339629 Part 4: Uplift CloneFor into StyleSheetInfo, and EnsureUniqueInner into StyleSheet. r=heycam
MozReview-Commit-ID: 4aZJYAsmZ2h
2017-05-15 16:19:17 -07:00
Brad Werth
2fae31f0d5 Bug 1339629 Part 3: Uplift mDirty into StyleSheet. r=heycam
MozReview-Commit-ID: iZKdg0fWss
2017-05-15 14:48:24 -07:00
Xidorn Quan
bf22378ea2 Bug 1352763 part 3 - Have ServoStyleSheet also implement nsICSSLoaderObserver. r=heycam
MozReview-Commit-ID: 1Z6jAmQ9CY6
2017-04-03 19:55:06 +10:00
Xidorn Quan
abb46b4fde Bug 1315601 part 13 - Move common code of DeleteRuleFromGroup/InsertRuleIntoGroup from CSSStyleSheet to StyleSheet. r=heycam
MozReview-Commit-ID: BDxnYb0OkCk
2017-03-08 18:04:15 +11:00
Xidorn Quan
a1f85f934d Bug 1315601 part 3 - Add base class MediaList and move part of nsMediaList to it. r=heycam
MozReview-Commit-ID: A2uJpbGgO55
2016-11-09 17:28:24 +11:00
Brad Werth
533d5ac5ed Bug 1342869 Part 1: Uplift ChildSheetListBuilder into StyleSheet so that all StyleSheet subclasses can fixup parent chains when children are removed. r=heycam
MozReview-Commit-ID: F9KnuPC0h7K
2017-03-06 16:27:32 -08:00
Brad Werth
79bc1141f0 Bug 1290218 Part 8: Implement ServoStyleSheet Clone. r=heycam
MozReview-Commit-ID: Y2KcoMjhbn
2017-02-15 13:33:17 -08:00
Brad Werth
a2095b5907 Bug 1290218 Part 4b: Fixup cycle collector declarations for mInner moving into StyleSheetInfo. r=heycam
MozReview-Commit-ID: 9cAvEf7y8JN
2017-02-15 16:19:33 -08:00
Brad Werth
0ef4bd93de Bug 1290218 Part 2: Uplift mInner pointer from CSSStyleSheetInner into StyleSheetInfo. r=heycam
MozReview-Commit-ID: K6FbTN1r4Qg
2017-02-14 09:41:33 -08:00
Brad Werth
5c08bd08b0 Bug 1290218 Part 1: Uplift IsModified into StyleSheet from CSSStyleSheet, and provide empty implementation for ServoStyleSheet. r=heycam
MozReview-Commit-ID: IU733JoNVyC
2017-02-13 10:27:46 -08:00
Brad Werth
6403dc67fc Bug 1328420 Part 8: Uplift SizeOfIncludingThis into StyleSheet, with override in CSSStyleSheet. r=heycam
MozReview-Commit-ID: 5f1WldhnP2
2017-01-23 16:42:31 -08:00
Brad Werth
7468980400 Bug 1328420 Part 7: Uplift List debug method into StyleSheet. r=heycam
MozReview-Commit-ID: 7aqC6N6cZst
2017-01-23 16:40:28 -08:00
Brad Werth
034e91ce4d Bug 1328420 Part 6: Implement ServoStyleSheet destructor. r=heycam
MozReview-Commit-ID: iVaza2s7d
2017-01-23 16:37:59 -08:00
Brad Werth
637dfced70 Bug 1328420 Part 5: Uplift AppendStyleSheet to StyleSheet. r=heycam
MozReview-Commit-ID: CwNGWsJi65G
2017-01-23 16:23:40 -08:00
Brad Werth
d2b2e92def Bug 1328420 Part 4: Uplift SetOwningDocument into StyleSheet. r=heycam
MozReview-Commit-ID: 3TnTaFYkZS3
2017-01-24 13:12:40 -08:00
Brad Werth
88ca4998cc Bug 1328420 Part 3: Uplift the first child to StyleSheet via a new method, abstracting out the inner sheet concept (which is not present in Stylo sheets). r=heycam
MozReview-Commit-ID: KUeIlOhAJXr
2017-01-23 15:52:56 -08:00
Brad Werth
03699681a4 Bug 1328420 Part 2: Uplift mNext into StyleSheet. r=heycam
MozReview-Commit-ID: 1yHUtEAJZnl
2017-01-23 15:36:09 -08:00
Brad Werth
d6c2d2c058 Bug 1328420 Part 1: Uplift parent pointer and accessor to StyleSheet class. r=heycam
MozReview-Commit-ID: C63yRZM3ORC
2017-01-24 13:09:33 -08:00
L. David Baron
a68ac77081 Bug 1333158 - Remove StyleSheet::GetDocument in favor of the identical GetAssociatedDocument. r=bz
(GetAssociatedDocument was recently renamed in bug 1332353.)

Note that the inconsistency between the Rule and CSSParser method names
is slightly bothersome.

MozReview-Commit-ID: L1SBIV86H4s
2017-01-23 13:12:03 -08:00
Boris Zbarsky
2e97c18674 Bug 851892 part 9. Add a CSSRule Web IDL interface. r=peterv,heycam
Note that this explicitly drops CSSRule.UNKNOWN_RULE.
2017-01-13 10:41:03 -05:00
Sebastian Hengst
d3d6fbf9ca Backed out changeset b975a988fb33 (bug 851892) 2017-01-20 19:30:28 +01:00
Boris Zbarsky
ac65687b62 Bug 851892 part 9. Add a CSSRule Web IDL interface. r=peterv,heycam
Note that this explicitly drops CSSRule.UNKNOWN_RULE.
2017-01-13 10:41:03 -05:00