Generate the TypeId enums in codegen

This commit is contained in:
Anthony Ramine 2015-09-27 13:37:57 +02:00
parent 55769b2fbf
commit aab2c40389
107 changed files with 678 additions and 774 deletions

View file

@ -2,12 +2,12 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
use dom::bindings::codegen::InheritTypes::HTMLMediaElementDerived;
use dom::bindings::codegen::InheritTypes::{ElementTypeId, EventTargetTypeId};
use dom::bindings::codegen::InheritTypes::{HTMLElementTypeId, HTMLMediaElementDerived};
use dom::bindings::codegen::InheritTypes::{HTMLMediaElementTypeId, NodeTypeId};
use dom::document::Document;
use dom::element::ElementTypeId;
use dom::eventtarget::{EventTarget, EventTargetTypeId};
use dom::htmlelement::{HTMLElement, HTMLElementTypeId};
use dom::node::NodeTypeId;
use dom::eventtarget::EventTarget;
use dom::htmlelement::HTMLElement;
use util::str::DOMString;
#[dom_struct]
@ -40,16 +40,3 @@ impl HTMLMediaElement {
&self.htmlelement
}
}
#[derive(Copy, Clone, Debug)]
pub enum HTMLMediaElementTypeId {
HTMLAudioElement = 0,
HTMLVideoElement = 1,
}
impl PartialEq for HTMLMediaElementTypeId {
#[inline]
fn eq(&self, other: &HTMLMediaElementTypeId) -> bool {
(*self as u8) == (*other as u8)
}
}