mirror of
https://github.com/yuezk/GlobalProtect-openconnect.git
synced 2026-11-19 14:36:15 -05:00
fix: expose display compositor availability
This commit is contained in:
1 file changed
+5
@@ -7,6 +7,11 @@ pub enum WindowTypeHint {
|
||||
Utility,
|
||||
}
|
||||
|
||||
#[cfg(any(target_os = "linux", target_os = "freebsd", target_os = "openbsd"))]
|
||||
pub fn is_screen_composited() -> bool {
|
||||
gtk::gdk::Screen::default().is_some_and(|screen| screen.is_composited())
|
||||
}
|
||||
|
||||
#[cfg(any(target_os = "linux", target_os = "freebsd", target_os = "openbsd"))]
|
||||
pub fn set_window_type_hint(window: &WebviewWindow, hint: WindowTypeHint) -> anyhow::Result<()> {
|
||||
use gtk::{gdk, traits::GtkWindowExt};
|
||||
|
||||
Reference in new issue
Block a user