1
0
Fork 0
forked from wry/wry

cursor: don't overwrite busy hardware buffers

This commit is contained in:
Julian Orth 2022-06-01 22:24:57 +02:00
parent b9ce5f22d8
commit 375d7da2f2
3 changed files with 13 additions and 4 deletions

View file

@ -34,9 +34,6 @@ impl CursorSurface {
let (hot_x, hot_y) = self.hotspot.get();
self.extents
.set(self.surface.extents.get().move_(-hot_x, -hot_y));
if self.seat.hardware_cursor() {
self.seat.update_hardware_cursor();
}
}
pub fn handle_surface_destroy(&self) {
@ -57,6 +54,12 @@ impl CursorSurface {
self.hotspot.set((hot_x - hotspot_dx, hot_y - hotspot_dy));
self.update_extents();
}
pub fn update_hardware_cursor(&self) {
if self.seat.hardware_cursor() {
self.seat.update_hardware_cursor();
}
}
}
impl Cursor for CursorSurface {