mirror of
https://github.com/servo/servo.git
synced 2025-08-06 22:15:33 +01:00
add check for self.context existence in composite_specific_target()
This commit is contained in:
parent
8330eabac1
commit
9f7aacdacf
1 changed files with 5 additions and 2 deletions
|
@ -1288,8 +1288,11 @@ impl<Window: WindowMethods> IOCompositor<Window> {
|
||||||
self.composite_specific_target(target);
|
self.composite_specific_target(target);
|
||||||
}
|
}
|
||||||
|
|
||||||
fn composite_specific_target(&mut self, target: CompositeTarget) -> Option<png::Image> {
|
pub fn composite_specific_target(&mut self, target: CompositeTarget) -> Option<png::Image> {
|
||||||
if !self.window.prepare_for_composite() {
|
if !self.context.is_some() {
|
||||||
|
return None
|
||||||
|
}
|
||||||
|
if !self.window.prepare_for_composite(width, height) {
|
||||||
return None
|
return None
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue