Measure heap memory usage for more types. Fixes #6951

This commit is contained in:
Bogdan Cuza 2015-08-05 18:31:42 +03:00
parent 94c8dcd575
commit 45145108da
175 changed files with 669 additions and 94 deletions

View file

@ -20,6 +20,7 @@ use time;
#[derive(JSTraceable, Copy, Clone)]
#[repr(u16)]
#[derive(HeapSizeOf)]
pub enum EventPhase {
None = EventConstants::NONE,
Capturing = EventConstants::CAPTURING_PHASE,
@ -27,7 +28,7 @@ pub enum EventPhase {
Bubbling = EventConstants::BUBBLING_PHASE,
}
#[derive(JSTraceable, PartialEq)]
#[derive(JSTraceable, PartialEq, HeapSizeOf)]
pub enum EventTypeId {
CustomEvent,
HTMLEvent,
@ -41,19 +42,20 @@ pub enum EventTypeId {
CloseEvent
}
#[derive(PartialEq)]
#[derive(PartialEq, HeapSizeOf)]
pub enum EventBubbles {
Bubbles,
DoesNotBubble
}
#[derive(PartialEq)]
#[derive(PartialEq, HeapSizeOf)]
pub enum EventCancelable {
Cancelable,
NotCancelable
}
#[dom_struct]
#[derive(HeapSizeOf)]
pub struct Event {
reflector_: Reflector,
type_id: EventTypeId,