Bug 1294572 - Avoid traversing children of XBL-bound elements during initial styling. r=heycam

MozReview-Commit-ID: JHABvLnMYco
This commit is contained in:
Bobby Holley 2016-12-13 15:35:15 -08:00
parent 7c7dd0f965
commit 652e891d0d
6 changed files with 73 additions and 14 deletions

View file

@ -244,16 +244,6 @@ pub trait TElement : PartialEq + Debug + Sized + Copy + Clone + ElementExt + Pre
/// traversal. Returns the number of children left to process.
fn did_process_child(&self) -> isize;
/// Returns true if this element's style is display:none. Panics if
/// the element has no style.
fn is_display_none(&self) -> bool {
let data = self.borrow_data().unwrap();
// See the comment on `cascade_node` about getting the up-to-date parent
// style for why we allow this on Gecko.
debug_assert!(cfg!(feature = "gecko") || data.has_current_styles());
data.styles().is_display_none()
}
/// Gets a reference to the ElementData container.
fn get_data(&self) -> Option<&AtomicRefCell<ElementData>>;