X11: Continuous Presentation (#7762)

Alternative to #7758, which doesn't involve adding a new trait method
`request_draw`.
Somehow, my whole screen goes blinking black with this when moving the
window, so not ready for landing.

Release Notes:
- N/A

---------

Co-authored-by: Mikayla Maki <mikayla@zed.dev>
This commit is contained in:
Dzmitry Malyshau 2024-02-14 12:24:12 -08:00 committed by GitHub
parent 181f556269
commit 8f7a26f397
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
9 changed files with 78 additions and 23 deletions

View file

@ -111,6 +111,9 @@ impl App {
/// Builds an app with the given asset source.
#[allow(clippy::new_without_default)]
pub fn new() -> Self {
#[cfg(any(test, feature = "test-support"))]
log::info!("GPUI was compiled in test mode");
Self(AppContext::new(
current_platform(),
Arc::new(()),
@ -676,7 +679,6 @@ impl AppContext {
self.update_window(window, |_, cx| cx.draw()).unwrap();
}
#[allow(clippy::collapsible_else_if)]
if self.pending_effects.is_empty() {
break;
}