Commit graph

71 commits

Author SHA1 Message Date
Emilio Cobos Álvarez
15a32fa8eb
geckolib: Remove unneeded unsafe. 2016-04-29 22:54:58 +02:00
Emilio Cobos Álvarez
2dbd17040a
geckolib: Refactor atom-to-pseudo logic and use ArcHelpers when
appropiate
2016-04-29 22:54:55 +02:00
Emilio Cobos Álvarez
02da1bb050
geckolib: Regen bindings, implement anon-box computed values, and pass
correct origin to StyleSheet::from_raw
2016-04-29 22:54:54 +02:00
Emilio Cobos Álvarez
1a0175fdbb
geckolib: Fix geckolib build after style and layout changes 2016-04-29 22:54:51 +02:00
bors-servo
78ae9a5da0 Auto merge of #10889 - heycam:insert-sheet, r=bholley
Add Servo_InsertStyleSheetBefore.

r? @bholley
Will be used by https://bugzilla.mozilla.org/show_bug.cgi?id=1268390.

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/10889)
<!-- Reviewable:end -->
2016-04-28 22:37:40 -07:00
Cameron McCormack
ef0476115d Add Servo_InsertStyleSheetBefore. 2016-04-29 09:42:09 +10:00
Cameron McCormack
b488e1d1d4 Make Servo_GetComputedValues take a node rather than an element. 2016-04-28 18:44:31 +10:00
bors-servo
e079e01320 Auto merge of #10848 - heycam:struct-accessor, r=bholley
Add Servo_GetStyleFoo functions to get style structs from GeckoComputedValues

r?@bholley

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/10848)
<!-- Reviewable:end -->
2016-04-27 02:20:17 -07:00
Cameron McCormack
88f51af3f8 Add Servo_GetStyleFoo functions to get style structs from GeckoComputedValues.
While we're here we also:

* remove any code conditional on style_struct.gecko_ffi_name, since all
  style structs now do have a corresponding Geckos struct

* add new UIReset and XUL style structs, so that all Gecko structs are
  now present (apart from Variables, which is special)
2016-04-27 17:13:26 +10:00
Bobby Holley
2c63de2492 Pass a RawServoStyleSet to Servo_GetComputedValuesForAnonymousBox. 2016-04-26 14:36:06 -07:00
Bobby Holley
899d6a9f64 Invoke the ctor/copy/dtor when managing gecko style structs from servo, and implement GeckoComputedValues::initial_values(). 2016-04-01 19:26:16 -07:00
Bobby Holley
ce206dd4d6 Regenerate bindings.rs with new bindgen. 2016-03-31 23:07:02 -07:00
Bobby Holley
e82aa66245 Implement more glue methods. 2016-03-24 11:50:59 -07:00
Bobby Holley
dbbbebd664 Parse ServoBindings.h as C++.
This allows us to remove the bool-as-int contortions we were doing before.
2016-03-04 11:46:35 -08:00
Bobby Holley
4da1171474 Stop using servo UA stylesheets for geckolib.
Gecko will provide these. This also removes the need to reference
the servo resource directory.
2016-03-04 11:46:32 -08:00
Bobby Holley
c4aa7cd862 Update gecko bindings.
I'm in the process of making the binding generator easier to use, so that we can check it
into the tree. More patches in that direction soon, but I wanted to first just update the
existing bindings to match the state of the world in gecko.
2016-03-02 16:48:54 -08:00
Emilio Cobos Álvarez
dd503dfacb Refactor style to be completely backend-independent
This commit refactors the style crate to be completely independent of
the actual implementation and pseudo-elements supported.

This also adds a gecko backend which introduces parsing for the
anonymous box pseudo-elements[1], although there's still no way of
querying them.

https://mxr.mozilla.org/mozilla-central/source/layout/style/nsCSSAnonBoxList.h
2016-02-13 16:05:14 +01:00
Bobby Holley
2e770b78a2 Implement a more realistic and persistent document restyle. 2016-02-03 18:39:16 -08:00
Bobby Holley
cafc0aabdf Hoist style-only traversal into geckolib.
Implementing StandaloneStyleContext::new is going to require a TLS key (just
like LayoutContext::new), and we don't want that key in shared code.
2016-02-03 18:39:16 -08:00
Cameron McCormack
da079c5b63 Add style sheet parsing functions. 2016-02-03 18:39:16 -08:00
Bobby Holley
84f24a04a4 Basic wrappers and glue for GeckoLib. 2016-01-13 12:14:00 -08:00