mirror of
https://github.com/emilk/egui.git
synced 2026-09-02 23:00:04 -04:00
Allow specifying override_redirect x11 window attribute (#7830)
This commit is contained in:
@@ -1728,6 +1728,7 @@ pub fn create_winit_window_attributes(
|
||||
|
||||
// x11
|
||||
window_type: _window_type,
|
||||
override_redirect: _override_redirect,
|
||||
|
||||
mouse_passthrough: _, // handled in `apply_viewport_builder_to_window`
|
||||
clamp_size_to_monitor_size: _, // Handled in `viewport_builder` in `epi_integration.rs`
|
||||
@@ -1827,8 +1828,8 @@ pub fn create_winit_window_attributes(
|
||||
|
||||
#[cfg(all(feature = "x11", target_os = "linux"))]
|
||||
{
|
||||
use winit::platform::x11::WindowAttributesExtX11 as _;
|
||||
if let Some(window_type) = _window_type {
|
||||
use winit::platform::x11::WindowAttributesExtX11 as _;
|
||||
use winit::platform::x11::WindowType;
|
||||
window_attributes = window_attributes.with_x11_window_type(vec![match window_type {
|
||||
egui::X11WindowType::Normal => WindowType::Normal,
|
||||
@@ -1847,6 +1848,9 @@ pub fn create_winit_window_attributes(
|
||||
egui::X11WindowType::Dnd => WindowType::Dnd,
|
||||
}]);
|
||||
}
|
||||
if let Some(override_redirect) = _override_redirect {
|
||||
window_attributes = window_attributes.with_override_redirect(override_redirect);
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(target_os = "windows")]
|
||||
|
||||
Reference in New Issue
Block a user