Bug 1322945 - Improve ergonomics and share more code for style crate DOM tree logging. r=heycam

MozReview-Commit-ID: 4Fy3ujpI4n2
This commit is contained in:
Bobby Holley 2016-12-12 15:36:41 -08:00
parent 3a56954069
commit 61eadbe7f1
5 changed files with 113 additions and 83 deletions

View file

@ -18,7 +18,7 @@ use style::arc_ptr_eq;
use style::atomic_refcell::AtomicRefMut;
use style::context::{LocalStyleContextCreationInfo, ReflowGoal, SharedStyleContext};
use style::data::{ElementData, RestyleData};
use style::dom::{TElement, TNode};
use style::dom::{ShowSubtreeData, TElement, TNode};
use style::error_reporting::StdoutErrorReporter;
use style::gecko::context::StandaloneStyleContext;
use style::gecko::context::clear_local_context;
@ -145,6 +145,9 @@ fn traverse_subtree(element: GeckoElement, raw_data: RawServoStyleSetBorrowed,
return;
}
debug!("Traversing subtree:");
debug!("{:?}", ShowSubtreeData(element.as_node()));
let shared_style_context = create_shared_context(&mut per_doc_data);
let known_depth = None;