mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Merge pull request #5492 from Ms2ger/MouseButton
Introduce a MouseButton enum.
This commit is contained in:
commit
02be76bd48
18 changed files with 58 additions and 22 deletions
|
@ -49,7 +49,7 @@ pub struct CompositorData {
|
|||
impl CompositorData {
|
||||
pub fn new_layer(layer_properties: LayerProperties,
|
||||
wants_scroll_events: WantsScrollEventsFlag,
|
||||
tile_size: uint)
|
||||
tile_size: usize)
|
||||
-> Rc<Layer<CompositorData>> {
|
||||
let new_compositor_data = CompositorData {
|
||||
pipeline_id: layer_properties.pipeline_id,
|
||||
|
|
|
@ -4,7 +4,6 @@
|
|||
|
||||
#![feature(box_syntax)]
|
||||
#![feature(core)]
|
||||
#![feature(int_uint)]
|
||||
#![feature(io)]
|
||||
#![feature(old_io)]
|
||||
#![feature(rustc_private)]
|
||||
|
|
|
@ -13,6 +13,7 @@ use layers::geometry::DevicePixel;
|
|||
use layers::platform::surface::NativeGraphicsMetadata;
|
||||
use msg::compositor_msg::{PaintState, ReadyState};
|
||||
use msg::constellation_msg::{Key, KeyState, KeyModifiers};
|
||||
use script_traits::MouseButton;
|
||||
use url::Url;
|
||||
use util::cursor::Cursor;
|
||||
use util::geometry::ScreenPx;
|
||||
|
@ -21,9 +22,9 @@ use std::rc::Rc;
|
|||
|
||||
#[derive(Clone)]
|
||||
pub enum MouseWindowEvent {
|
||||
Click(uint, TypedPoint2D<DevicePixel, f32>),
|
||||
MouseDown(uint, TypedPoint2D<DevicePixel, f32>),
|
||||
MouseUp(uint, TypedPoint2D<DevicePixel, f32>),
|
||||
Click(MouseButton, TypedPoint2D<DevicePixel, f32>),
|
||||
MouseDown(MouseButton, TypedPoint2D<DevicePixel, f32>),
|
||||
MouseUp(MouseButton, TypedPoint2D<DevicePixel, f32>),
|
||||
}
|
||||
|
||||
#[derive(Clone)]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue