Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement Range::createContextualFragment #11496

Merged
merged 2 commits into from Jun 3, 2016
Merged
Changes from 1 commit
Commits
File filter...
Filter file types
Jump to…
Jump to file
Failed to load files.

Always

Just for now

Next

Replace HTMLScriptElement::mark_script_already_started by set_script_…

…already_started
  • Loading branch information
GuillaumeGomez committed Jun 2, 2016
commit 2ef143745753d3600b6135e7ecdee7c603799d71
@@ -538,8 +538,8 @@ impl HTMLScriptElement {
is_js
}

pub fn mark_already_started(&self) {
self.already_started.set(true);
pub fn set_already_started(&self, already_started: bool) {
self.already_started.set(already_started);
}

fn dispatch_event(&self,
@@ -599,7 +599,7 @@ impl VirtualMethods for HTMLScriptElement {

// https://html.spec.whatwg.org/multipage/#already-started
if self.already_started.get() {
copy.downcast::<HTMLScriptElement>().unwrap().mark_already_started();
copy.downcast::<HTMLScriptElement>().unwrap().set_already_started(true);
}
}
}
@@ -150,7 +150,7 @@ impl<'a> TreeSink for servohtmlparser::Sink {

fn mark_script_already_started(&mut self, node: JS<Node>) {
let script = node.downcast::<HTMLScriptElement>();
script.map(|script| script.mark_already_started());
script.map(|script| script.set_already_started(true));
}

fn complete_script(&mut self, node: JS<Node>) -> NextParserState {
@@ -107,7 +107,7 @@ impl<'a> TreeSink for servoxmlparser::Sink {
fn mark_script_already_started(&mut self, node: Self::Handle) {
let script = node.downcast::<HTMLScriptElement>();
if let Some(script) = script {
script.mark_already_started();
script.set_already_started(true);
}
}

ProTip! Use n and p to navigate between commits in a pull request.
You can’t perform that action at this time.