1
0
Fork 0
forked from wry/wry

metal: reset frontend damage state when latching

Fixes ada4e5a5
This commit is contained in:
Julian Orth 2024-09-13 15:09:24 +02:00
parent 297a6e58cd
commit e514c32c9d

View file

@ -269,10 +269,6 @@ impl MetalConnector {
self.can_present.set(false);
if let Some(latched) = latched {
self.has_damage.fetch_sub(latched.damage);
node.global
.connector
.damaged
.set(self.has_damage.is_not_zero());
}
self.cursor_changed.set(false);
Ok(())
@ -486,6 +482,7 @@ impl MetalConnector {
if damage == 0 {
return None;
}
node.global.connector.damaged.set(false);
let render_hw_cursor = !self.cursor_enabled.get();
let mode = node.global.mode.get();
let pass = create_render_pass(