mirror of
https://github.com/servo/servo.git
synced 2025-07-23 07:13:52 +01:00
Auto merge of #19664 - emilio:dupe-slots, r=smaug
style: Stop duplicating slots. Reland of #19660 since it was backed out for not landing its Gecko changes on time. Bug: 1427001 Reviewed-by: smaug MozReview-Commit-ID: Cq647BcOzbe <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/19664) <!-- Reviewable:end -->
This commit is contained in:
commit
e882660ea6
2 changed files with 100 additions and 72 deletions
File diff suppressed because one or more lines are too long
|
@ -536,8 +536,9 @@ impl<'le> GeckoElement<'le> {
|
|||
fn get_extended_slots(
|
||||
&self,
|
||||
) -> Option<&structs::FragmentOrElement_nsExtendedDOMSlots> {
|
||||
self.get_dom_slots()
|
||||
.and_then(|s| unsafe { s.mExtendedSlots.mPtr.as_ref() })
|
||||
self.get_dom_slots().and_then(|s| unsafe {
|
||||
(s._base.mExtendedSlots.mPtr as *const structs::FragmentOrElement_nsExtendedDOMSlots).as_ref()
|
||||
})
|
||||
}
|
||||
|
||||
#[inline]
|
||||
|
@ -592,7 +593,7 @@ impl<'le> GeckoElement<'le> {
|
|||
fn get_non_xul_xbl_binding_parent_raw_content(&self) -> *mut nsIContent {
|
||||
debug_assert!(!self.is_xul_element());
|
||||
self.get_extended_slots()
|
||||
.map_or(ptr::null_mut(), |slots| slots.mBindingParent)
|
||||
.map_or(ptr::null_mut(), |slots| slots._base.mBindingParent)
|
||||
}
|
||||
|
||||
fn has_xbl_binding_parent(&self) -> bool {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue