Bobby Holley
ace7380088
Bug 1304913 - Have Servo manage node data directly without FFI calls. r=Manishearth
...
MozReview-Commit-ID: H8f8VP18TbM
2016-09-23 15:58:48 -07:00
Manish Goregaokar
49b3b83008
Bug 1300337 - Replace None_ variants from nsStyleConsts.h with None; r=heycam,TYLin
...
MozReview-Commit-ID: CxHzbEzjLxT
2016-09-04 00:16:58 +05:30
Wes Kocher
eda25c5728
Merge inbound to m-c a=merge
2016-09-02 13:17:30 -07:00
Emilio Cobos Álvarez
38949ab18a
Bug 1296556: Recreate style contexts inside generated content. r=heycam
...
MozReview-Commit-ID: JvVyml8yCrO
2016-08-20 00:17:04 -07:00
Bobby Holley
8e6b8445cc
Bug 1299348 - Remove StylingStarted(). r=emilio
...
StylingStarted is a kind of nebulous and not-very-useful concept. The concept
that _is_ useful is whether the presshell has been initialized or not, but the
root element may not exist at that point.
So we need to make sure we that we can trigger the initial document style in both
presshell initialized _and_ ContentInserted, which has the nice effect of handling
root element reinsertions.
We also take the opportunity to make StyleDocument assert the existence of a root
element, and align the responsibility for clearing the dirty descendant bits between
document and non-document nodes.
2016-08-31 10:32:42 -07:00
Markus Stange
dc677bbb79
Bug 1298205 - Fix ServoRestyleManager.cpp includes. r=heycam
...
MozReview-Commit-ID: IhXCuG7V7gL
2016-08-29 11:20:07 -04:00
Bobby Holley
2317c7eb1c
Bug 1292662 - Use accessors to unset stylo dirty bits. r=heycam
...
I often find myself wanting to hook them for logging etc, and this makes the
API symmetric with the setters.
2016-08-25 21:36:57 -07:00
Bobby Holley
a256e14379
Bug 1292662 - Use StyleChildrenIterator in ServoRestyleManger and ServoStyleSet. r=heycam
...
Most importantly, this causes us to traverse NAC during style context fixup.
2016-08-25 21:36:51 -07:00
Bobby Holley
7cba59f144
Bug 1292279 - Add a helper to get the real container and use it in nsPresShell::Content{Inserted,Removed}. r=heycam
...
The existing static_cast checks are totally wrong, by the way, since
nsIDocuments are never nsIContent. Looks like they were erroneously
added in bug 862763.
2016-08-25 21:36:41 -07:00
Bobby Holley
d78f7933b3
Bug 1292279 - Explicitly style new children in Content{Appended/Inserted} rather than using restyle hints. r=heycam
...
This gives us more control over what gets restyled when.
2016-08-25 21:36:32 -07:00
Bobby Holley
fb49955c2b
Bug 1292279 - Clear up the semantics of our Servo traversal APIs. r=heycam
2016-08-25 21:34:31 -07:00
Bobby Holley
046b455094
Bug 1292279 - Add an API on nsIContent to propagate the dirty bit up the tree, and use it in ServoRestyleManager. r=heycam
...
We don't need this API outside of its current consumers yet, but will probably
need it when we handle lazy frame construction.
2016-08-25 21:34:25 -07:00
Xidorn Quan
a87b549cbc
Bug 1296173 part 2 - Rename the servo binding functions. r=bholley
...
MozReview-Commit-ID: Gxqx52v3sDQ
2016-08-23 13:14:27 +10:00
Emilio Cobos Álvarez
b233d1f26a
Bug 1292618: Support basic pseudo-element restyling. r=heycam
...
:before and :after only, for now.
MozReview-Commit-ID: 9hLFvVhqIrN
2016-08-19 20:24:27 -07:00
Wes Kocher
9e201f5768
Backed out 4 changesets (bug 1292618) because it was making merging things difficult a=backout
...
Backed out changeset 14733a383b4c (bug 1292618)
Backed out changeset 17dfe8bc5f76 (bug 1292618)
Backed out changeset d04597bd1109 (bug 1292618)
Backed out changeset 30f7696fea2d (bug 1292618)
2016-08-19 18:37:09 -07:00
Emilio Cobos Álvarez
6798126e12
Bug 1292618: Support basic pseudo-element restyling. r=heycam
...
:before and :after only, for now.
MozReview-Commit-ID: 9hLFvVhqIrN
Signed-off-by: Emilio Cobos Álvarez <ecoal95@gmail.com >
2016-08-19 18:26:38 -07:00
Phil Ringnalda
069e5d30dc
Backed out 5 changesets (bug 1292618) for !mImageTracked assertion failures
...
CLOSED TREE
Backed out changeset 1d767147e160 (bug 1292618)
Backed out changeset e6034e58efe4 (bug 1292618)
Backed out changeset 928dd363efa0 (bug 1292618)
Backed out changeset 8e274c66ae7f (bug 1292618)
Backed out changeset 6c347701d343 (bug 1292618)
2016-08-19 00:23:42 -07:00
Emilio Cobos Álvarez
9abb4abaeb
Bug 1292618: Support basic pseudo-element restyling. r=heycam
...
:before and :after only, for now.
MozReview-Commit-ID: 9hLFvVhqIrN
2016-08-18 22:16:16 -07:00
Manish Goregaokar
6eb3ca0a81
Bug 1275913 - Use already_addrefed properly when dealing with arcs sent from servo to gecko; r=bholley
...
MozReview-Commit-ID: 5FDS8J2Fo1G
2016-08-16 10:38:46 +05:30
Phil Ringnalda
a5bcb4d23c
Backed out 2 changesets (bug 1275913) for static analysis bustage
...
CLOSED TREE
Backed out changeset 4420244e8fba (bug 1275913)
Backed out changeset 324554b04f19 (bug 1275913)
2016-08-15 22:27:16 -07:00
Manish Goregaokar
af75fd460e
Bug 1275913 - Use already_addrefed properly when dealing with arcs sent from servo to gecko; r=bholley
...
MozReview-Commit-ID: 5FDS8J2Fo1G
2016-08-16 10:38:46 +05:30
Emilio Cobos Álvarez
ae38809763
Bug 1292930: stylo: Make change hint processing more straight-forward. r=heycam
...
MozReview-Commit-ID: 4ZcCMKSc6Tv
2016-08-10 22:02:00 -07:00
Emilio Cobos Álvarez
b77a84c879
Bug 1292930: stylo: Remove expected warning. r=heycam
...
This should actually have been a followup for bug 1290335.
MozReview-Commit-ID: GIl67fSMRQg
2016-08-10 22:01:49 -07:00
Emilio Cobos Álvarez
5f3cbb7bc3
Bug 1292930: stylo: Fix handling of eRestyle_LaterSiblings when not combined with other change hints. r=heycam
...
MozReview-Commit-ID: AeLLm64d5aP
2016-08-10 22:01:06 -07:00
Emilio Cobos Álvarez
ce22257791
Bug 1292930: stylo: Reuse RestyleManager::PostRestyleEventInternal. r=heycam
...
MozReview-Commit-ID: J6rw1feAYWh
2016-08-10 22:00:33 -07:00
Bobby Holley
9b0bd4c762
Bug 1291891 - Switch to NS_WARNING for various unimplemented incremental restyle methods. r=emilio
...
No need to bring the browser down.
2016-08-03 18:30:59 -07:00
Emilio Cobos Álvarez
497d4d951b
Bug 1290335: Make ProcessRestyledFrames non static, and tidy up a bit. r=heycam
...
MozReview-Commit-ID: 4aALVtI5DXT
2016-08-03 15:11:15 -07:00
Emilio Cobos Álvarez
d171a94d06
Bug 1290335: Implement dumb versions of RestyleForAppend and RestyleForInsertOrChange. r=heycam
...
This lets us take rid of the delay-layout hack on the stylo branch.
MozReview-Commit-ID: 9fqhBCQnfYV
2016-08-03 15:11:15 -07:00
Emilio Cobos Álvarez
d529d90d3b
Bug 1290335: Reuse the OverflowChangedTracker between both restyle managers. r=heycam
...
MozReview-Commit-ID: objnqfecZD
2016-08-03 15:11:15 -07:00
Emilio Cobos Álvarez
41ee485ee4
Bug 1290335: stylo: Allow processing change hints generated from Servo. r=heycam
...
MozReview-Commit-ID: Alc0wcXvHcD
2016-08-03 15:11:15 -07:00
Emilio Cobos Álvarez
7a245cf103
Bug 1290335: Hoist frame-construction logic in RestyleManager to static members in RestyleManagerBase. r=heycam
...
MozReview-Commit-ID: BqywJXZ0CYU
2016-08-03 15:11:15 -07:00
Emilio Cobos Álvarez
e054965222
Bug 1287951: followup: Know if a snapshot belongs to a HTML element in an HTML document at construction time. r=heycam
...
MozReview-Commit-ID: eN0j8vnesa
2016-07-30 15:03:31 -07:00
Bobby Holley
9edbeb583e
Bug 1290214 - Remove NS_ERROR for {un,partially-}implemented ServoRestyleManager and ServoStyleSet methods. r=emilio
...
These are core methods that we know we need to implement, and I'm not worried that
we'll forget about them. The warnings should be enough here.
2016-07-28 17:25:53 -07:00
Bobby Holley
4730d97c3e
Bug 1290214 - Make ServoRestyleManager::AttributeChanged a no-op. r=emilio
...
We do all the work we need to do with the snapshot model in AttributeWillChange.
2016-07-28 17:25:48 -07:00
Bobby Holley
20b26a1432
Bug 1289916 - Check tree dirtiness in ProcessPendingRestyles before triggering traversal. r=emilio
...
It's possible (and in fact, desirable) for the restyle hints to all evaluate
to 0, which means the tree stays clean even though the map was non-empty.
2016-07-27 18:20:18 -07:00
Bobby Holley
1c9c1d221f
Bug 1289620 - Hook up initial styling. r=heycam
...
Aside from the parser-side hacks, this should subsume all the current scattered
logic in the stylo tree to handle initial styling.
2016-07-27 09:44:25 -07:00
Cameron McCormack
3cc2283166
Bug 1289620 - Stub out ReparentStyleContext. r=bholley
2016-07-27 09:41:50 -07:00
Emilio Cobos Álvarez
85da92ad01
Bug 1288873: stylo: Improve the error message when we don't handle a restyle hint. r=heycam
...
MozReview-Commit-ID: 3FCCCCF5gQS
2016-07-27 09:35:20 -07:00
Emilio Cobos Álvarez
df732f119d
Bug 1288873: Don't propagate the IS_DIRTY flag down the whole tree, just make it
...
imply that all descendants are dirty. r=heycam
We're probably going to be a lot more smarter than this in the future, but since
there is work in progress to figure out how should we avoid running
selector-matching on the elements, this helps a lot with perf in the meantime.
MozReview-Commit-ID: CEb15JwHAdH
2016-07-27 09:35:20 -07:00
Emilio Cobos Álvarez
4c885f5fce
Bug 1287951: stylo: Implement ServoRestyleManager::AttributeWillChange. r=heycam
...
MozReview-Commit-ID: 5CCleWo06Ow
2016-07-21 16:57:52 -07:00
Emilio Cobos Álvarez
029cda8ee4
Bug 1287951: stylo: Add support for computing style hints from Servo. r=heycam
...
MozReview-Commit-ID: ALuJxcfAMuL
2016-07-21 16:57:52 -07:00
Emilio Cobos Álvarez
6d49d6c409
Bug 1287542: stylo: Actually post a restyle event to the restyle manager on content state change. r=bholley
...
This was somehow a leftover from Bug 1286445.
MozReview-Commit-ID: 1bGKsNvm1qn
2016-07-18 11:28:57 -07:00
Emilio Cobos Álvarez
f702c2acc1
Bug 1287542: stylo: Implement ServoRestyleManager::HasPendingRestyles() r=bholley
...
MozReview-Commit-ID: JeDly0eqjka
2016-07-18 11:28:27 -07:00
Emilio Cobos Álvarez
03dcde9d5c
Bug 1286445: stylo: Unset restyle frames appropriately after regenerating style contexts. r=heycam
...
MozReview-Commit-ID: IgG4KOESJUY
2016-07-16 16:22:12 -07:00
Emilio Cobos Álvarez
95dc632f01
Bug 1286445: stylo: Support restyles of non-pseudo content on state change. r=heycam
...
This includes, for example :hover.
Also removes the call to IsStyledByServo() in the document constructor, it's not
only unnecessary, but also we call UpdateStyleBackendType() too early.
MozReview-Commit-ID: 4YfCdmLoSxu
2016-07-16 16:22:12 -07:00
Emilio Cobos Álvarez
d3a2ca57e6
Bug 1285474: Add mozilla::RestyleManagerBase to share logic between RestyleManager and ServoRestyleManager. r=bholley
...
Partially implement some restyling APIs to take rid of some gecko-only code
paths.
MozReview-Commit-ID: L5i6Kr2Qars
2016-07-12 00:33:57 -07:00
Cameron McCormack
4d4e79b681
Bug 1270956 - Stub out some ServoRestyleManager methods. r=bholley
2016-05-06 14:19:57 -07:00
Cameron McCormack
09d16d0bfa
Bug 1248864 - Part 2: Add skeleton ServoRestyleManager and a RestyleManagerHandle smart pointer. r=dholbert
2016-02-24 18:01:12 +11:00
Emilio Cobos Álvarez
2efcfaad38
Bug 1299066: Make NS_STYLE_DISPLAY_* an enum class. Prefer indexing instead of linear search in the frame constructor r=heycam,bz
...
The main renaming was generated with the following python script:
```
import sys
import re
CAMEL_CASE_REGEX = re.compile(r"(^|_|-)([A-Z])([A-Z]+)")
DISPLAY_REGEX = re.compile(r"\bNS_STYLE_DISPLAY_([^M][A-Z_]+)\b")
def to_camel_case(ident):
return re.sub(CAMEL_CASE_REGEX,
lambda m: m.group(2) + m.group(3).lower(), ident)
def constant_to_enum(constant):
return "StyleDisplay::" + to_camel_case(constant) + ("_" if constant == "NONE" else "")
def process_line(line):
return re.sub(DISPLAY_REGEX,
lambda m: constant_to_enum(m.group(1)), line)
lines = []
with open(sys.argv[1], "r") as f:
for line in f:
lines.append(process_line(line))
with open(sys.argv[1], "w") as f:
for line in lines:
f.write(line)
```
And the following shell commands:
```
find . -name '*.cpp' -exec python display.py {} \;
find . -name '*.h' -exec python display.py {} \;
```
MozReview-Commit-ID: 91xYCbLC2Vf
2016-09-01 20:41:17 -07:00