From a65a1088a44f8fea8b3df0abba5edb3cf16aafc7 Mon Sep 17 00:00:00 2001 From: Ms2ger Date: Fri, 20 Feb 2015 14:39:42 +0100 Subject: [PATCH] Change the representation of EventPhase to u16. This matches the IDL definitions. --- components/script/dom/event.rs | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/components/script/dom/event.rs b/components/script/dom/event.rs index 7c9d73675d1..eae43afe9c2 100644 --- a/components/script/dom/event.rs +++ b/components/script/dom/event.rs @@ -20,11 +20,12 @@ use time; #[jstraceable] #[derive(Copy)] +#[repr(u16)] pub enum EventPhase { - None = EventConstants::NONE as int, - Capturing = EventConstants::CAPTURING_PHASE as int, - AtTarget = EventConstants::AT_TARGET as int, - Bubbling = EventConstants::BUBBLING_PHASE as int, + None = EventConstants::NONE, + Capturing = EventConstants::CAPTURING_PHASE, + AtTarget = EventConstants::AT_TARGET, + Bubbling = EventConstants::BUBBLING_PHASE, } #[derive(PartialEq)]