mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-10 03:45:46 +00:00
Bug 1399228
- stylo: Remove FontComputationData, switch over to using the new font tracking; r=emilio
MozReview-Commit-ID: 66IAynRiUkU
This commit is contained in:
parent
aa9a1e8f52
commit
0b79b6657e
@ -352,7 +352,6 @@ mapped-generic-types = [
|
||||
{ generic = true, gecko = "mozilla::ServoCell", servo = "::std::cell::Cell" },
|
||||
{ generic = false, gecko = "ServoNodeData", servo = "AtomicRefCell<ElementData>" },
|
||||
{ generic = false, gecko = "mozilla::ServoWritingMode", servo = "::logical_geometry::WritingMode" },
|
||||
{ generic = false, gecko = "mozilla::ServoFontComputationData", servo = "::properties::FontComputationData" },
|
||||
{ generic = false, gecko = "mozilla::ServoCustomPropertiesMap", servo = "Option<::servo_arc::Arc<::custom_properties::CustomPropertiesMap>>" },
|
||||
{ generic = false, gecko = "mozilla::ServoRuleNode", servo = "Option<::rule_tree::StrongRuleNode>" },
|
||||
{ generic = false, gecko = "mozilla::ServoVisitedStyle", servo = "Option<::servo_arc::RawOffsetArc<::properties::ComputedValues>>" },
|
||||
|
@ -135,34 +135,6 @@ struct ServoWritingMode {
|
||||
uint8_t mBits;
|
||||
};
|
||||
|
||||
// Don't attempt to read from this
|
||||
// (see comment on ServoFontComputationData
|
||||
enum ServoKeywordSize {
|
||||
Empty, // when the Option is None
|
||||
XXSmall,
|
||||
XSmall,
|
||||
Small,
|
||||
Medium,
|
||||
Large,
|
||||
XLarge,
|
||||
XXLarge,
|
||||
XXXLarge,
|
||||
};
|
||||
|
||||
// Don't attempt to read from this. We can't
|
||||
// always guarantee that the interior representation
|
||||
// of this is correct (the mKeyword field may have a different padding),
|
||||
// but the entire struct should
|
||||
// have the same size and alignment as the Rust version.
|
||||
// Ensure layout tests get run if touching either side.
|
||||
struct ServoFontComputationData {
|
||||
ServoKeywordSize mKeyword;
|
||||
float/*32_t*/ mRatio;
|
||||
int32_t mAbsolute;
|
||||
|
||||
static_assert(sizeof(float) == 4, "float should be 32 bit");
|
||||
};
|
||||
|
||||
struct ServoCustomPropertiesMap {
|
||||
uintptr_t mPtr;
|
||||
};
|
||||
@ -270,14 +242,6 @@ private:
|
||||
/// element being matched if it is a link or the nearest ancestor link.
|
||||
mozilla::ServoVisitedStyle visited_style;
|
||||
|
||||
// this is the last member because most of the other members
|
||||
// are pointer sized. This makes it easier to deal with the
|
||||
// alignment of the fields when replacing things via bindgen
|
||||
//
|
||||
// This is opaque, please don't read from it from C++
|
||||
// (see comment on ServoFontComputationData)
|
||||
mozilla::ServoFontComputationData font_computation_data;
|
||||
|
||||
// C++ just sees this struct as a bucket of bits, and will
|
||||
// do the wrong thing if we let it use the default copy ctor/assignment
|
||||
// operator. Remove them so that there is no footgun.
|
||||
|
Loading…
Reference in New Issue
Block a user