mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Generate all Derived implementations in codegen
This commit is contained in:
parent
32daa17d5c
commit
617fc08783
93 changed files with 137 additions and 1027 deletions
|
@ -8,15 +8,13 @@ use dom::bindings::codegen::Bindings::NodeBinding::NodeMethods;
|
|||
use dom::bindings::codegen::Bindings::TextBinding::{self, TextMethods};
|
||||
use dom::bindings::codegen::Bindings::WindowBinding::WindowMethods;
|
||||
use dom::bindings::codegen::InheritTypes::{CharacterDataCast, CharacterDataTypeId};
|
||||
use dom::bindings::codegen::InheritTypes::{EventTargetTypeId, NodeCast};
|
||||
use dom::bindings::codegen::InheritTypes::{NodeTypeId, TextDerived};
|
||||
use dom::bindings::codegen::InheritTypes::{NodeCast, TextDerived};
|
||||
use dom::bindings::error::{Error, Fallible};
|
||||
use dom::bindings::global::GlobalRef;
|
||||
use dom::bindings::js::Root;
|
||||
use dom::bindings::js::{RootedReference};
|
||||
use dom::characterdata::CharacterData;
|
||||
use dom::document::Document;
|
||||
use dom::eventtarget::EventTarget;
|
||||
use dom::node::Node;
|
||||
use util::str::DOMString;
|
||||
|
||||
|
@ -26,12 +24,6 @@ pub struct Text {
|
|||
characterdata: CharacterData,
|
||||
}
|
||||
|
||||
impl TextDerived for EventTarget {
|
||||
fn is_text(&self) -> bool {
|
||||
*self.type_id() == EventTargetTypeId::Node(NodeTypeId::CharacterData(CharacterDataTypeId::Text))
|
||||
}
|
||||
}
|
||||
|
||||
impl Text {
|
||||
fn new_inherited(text: DOMString, document: &Document) -> Text {
|
||||
Text {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue