mirror of
https://github.com/servo/servo.git
synced 2025-09-30 16:49:16 +01:00
Allow Window implementations to indicate that they don't support a clipboard.
This is important for the SERVO_HEADLESS configuration, because creating a clipboard on linux creates an X context which then causes reftest instability.
This commit is contained in:
parent
ec79881471
commit
2b396b2485
6 changed files with 46 additions and 11 deletions
|
@ -451,6 +451,10 @@ impl WindowMethods for Window {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
fn supports_clipboard(&self) -> bool {
|
||||
true
|
||||
}
|
||||
}
|
||||
|
||||
struct CefCompositorProxy {
|
||||
|
|
|
@ -614,6 +614,10 @@ impl WindowMethods for Window {
|
|||
_ => {}
|
||||
}
|
||||
}
|
||||
|
||||
fn supports_clipboard(&self) -> bool {
|
||||
true
|
||||
}
|
||||
}
|
||||
|
||||
/// The type of a window.
|
||||
|
@ -718,6 +722,10 @@ impl WindowMethods for Window {
|
|||
/// Helper function to handle keyboard events.
|
||||
fn handle_key(&self, _: Key, _: constellation_msg::KeyModifiers) {
|
||||
}
|
||||
|
||||
fn supports_clipboard(&self) -> bool {
|
||||
false
|
||||
}
|
||||
}
|
||||
|
||||
struct GlutinCompositorProxy {
|
||||
|
|
|
@ -841,6 +841,10 @@ impl WindowMethods for Window {
|
|||
fn prepare_for_composite(&self, _width: usize, _height: usize) -> bool {
|
||||
true
|
||||
}
|
||||
|
||||
fn supports_clipboard(&self) -> bool {
|
||||
true
|
||||
}
|
||||
}
|
||||
|
||||
struct GonkCompositorProxy {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue