Move a render schedule

As you can see I don't pay attention to the compiler yelling at me
This commit is contained in:
Ottatop 2023-10-17 23:00:19 -05:00
parent 97616ef0c1
commit 06a96849e7
2 changed files with 9 additions and 9 deletions

View file

@ -677,14 +677,14 @@ impl State {
.loop_handle
.insert_source(notifier, move |event, metadata, data| match event {
DrmEvent::VBlank(crtc) => {
{
let udev = data.state.backend.udev_mut();
let then = udev.last_vblank_time;
let now = Instant::now();
let diff = now.duration_since(then);
// tracing::debug!(time = diff.as_secs_f64(), "Time since last vblank");
udev.last_vblank_time = now;
}
// { TODO:
// let udev = data.state.backend.udev_mut();
// let then = udev.last_vblank_time;
// let now = Instant::now();
// let diff = now.duration_since(then);
// // tracing::debug!(time = diff.as_secs_f64(), "Time since last vblank");
// udev.last_vblank_time = now;
// }
data.state.on_vblank(node, crtc, metadata);
}
DrmEvent::Error(error) => {

View file

@ -113,8 +113,8 @@ impl State {
window.change_geometry(Rectangle::from_loc_and_size(window_loc, window_size));
if let Some(output) = window.output(self) {
self.update_windows(&output);
self.schedule_render(&output);
}
self.schedule_render(&output);
}
Msg::MoveWindowToTag { window_id, tag_id } => {
let Some(window) = window_id.window(self) else { return };