Minor refactoring of mouse event types

* Move some types into the `msg` crate so they can be shared more.
* Use MouseEventType instead of duplicating it in other enums.
This commit is contained in:
Matt Brubeck 2015-12-02 11:49:37 -08:00
parent 2be60be062
commit 8c4fed42b0
13 changed files with 43 additions and 64 deletions

View file

@ -11,9 +11,9 @@ use euclid::size::TypedSize2D;
use euclid::{Point2D, Size2D};
use layers::geometry::DevicePixel;
use layers::platform::surface::NativeDisplay;
use msg::constellation_msg::{Key, KeyModifiers, KeyState};
use msg::constellation_msg::{Key, KeyModifiers, KeyState, MouseButton};
use net_traits::net_error_list::NetError;
use script_traits::{MouseButton, TouchEventType, TouchId};
use script_traits::{TouchEventType, TouchId};
use std::fmt::{Debug, Error, Formatter};
use std::rc::Rc;
use url::Url;
@ -27,7 +27,6 @@ pub enum MouseWindowEvent {
MouseUp(MouseButton, TypedPoint2D<DevicePixel, f32>),
}
#[derive(Clone)]
pub enum WindowNavigateMsg {
Forward,