1
0
Fork 0
forked from wry/wry

metal: latch hardware cursors in the backend

This commit is contained in:
Julian Orth 2024-09-09 17:02:09 +02:00
parent 12c9b36ded
commit 93bfb9c0b4
7 changed files with 204 additions and 186 deletions

View file

@ -87,7 +87,7 @@ impl OutputSchedule {
}
}
pub fn presented(&self) {
pub fn latched(&self) {
self.last_present_nsec.set(self.eng.now().nsec());
self.present_scheduled.set(false);
self.iteration.fetch_add(1);
@ -166,9 +166,8 @@ impl OutputSchedule {
}
if self.needs_hardware_cursor_commit.take() {
if let Some(hc) = self.hardware_cursor.get() {
if hc.schedule_present() {
self.present_scheduled.set(true);
}
hc.damage();
self.present_scheduled.set(true);
}
}
if self.needs_software_cursor_damage.take() {