Switch to using WebRender hit testing

This trades quite a bit of complicated code in Servo for few more
messages and a significant performance improvement. In particular,
WebRender can search the entire display list at once instead of
ping-ponging down the pipeline tree. This allows us to send mouse
events to the correct pipeline immediately.
This commit is contained in:
Martin Robinson 2017-09-30 15:50:47 +02:00
parent 00e2a1c62a
commit b5d51dd263
20 changed files with 381 additions and 555 deletions

View file

@ -35,6 +35,15 @@ macro_rules! define_cursor {
_ => Err(())
}
}
/// From the C u8 value, get the corresponding Cursor enum.
pub fn from_u8(value: u8) -> Result<Cursor, ()> {
match value {
$( $c_value => Ok(Cursor::$c_variant), )+
$( #[cfg(feature = "gecko")] $g_value => Ok(Cursor::$g_variant), )+
_ => Err(())
}
}
}
impl ToCss for Cursor {