Generate all Derived implementations in codegen

This commit is contained in:
Anthony Ramine 2015-09-27 17:52:37 +02:00
parent 32daa17d5c
commit 617fc08783
93 changed files with 137 additions and 1027 deletions

View file

@ -4,12 +4,10 @@
use dom::bindings::codegen::Bindings::ProcessingInstructionBinding;
use dom::bindings::codegen::Bindings::ProcessingInstructionBinding::ProcessingInstructionMethods;
use dom::bindings::codegen::InheritTypes::{CharacterDataTypeId, EventTargetTypeId};
use dom::bindings::codegen::InheritTypes::{NodeTypeId, ProcessingInstructionDerived};
use dom::bindings::codegen::InheritTypes::CharacterDataTypeId;
use dom::bindings::js::Root;
use dom::characterdata::CharacterData;
use dom::document::Document;
use dom::eventtarget::EventTarget;
use dom::node::Node;
use util::str::DOMString;
@ -20,13 +18,6 @@ pub struct ProcessingInstruction {
target: DOMString,
}
impl ProcessingInstructionDerived for EventTarget {
fn is_processinginstruction(&self) -> bool {
*self.type_id() ==
EventTargetTypeId::Node(NodeTypeId::CharacterData(CharacterDataTypeId::ProcessingInstruction))
}
}
impl ProcessingInstruction {
fn new_inherited(target: DOMString, data: DOMString, document: &Document) -> ProcessingInstruction {
ProcessingInstruction {