parent
219527ed7d
commit
125afb41ac
@ -39,6 +39,7 @@ pub struct Window {
|
|||||||
pub title: String,
|
pub title: String,
|
||||||
pub vsync: bool,
|
pub vsync: bool,
|
||||||
pub resizable: bool,
|
pub resizable: bool,
|
||||||
|
pub decorations: bool,
|
||||||
pub mode: WindowMode,
|
pub mode: WindowMode,
|
||||||
#[cfg(target_arch = "wasm32")]
|
#[cfg(target_arch = "wasm32")]
|
||||||
pub canvas: Option<String>,
|
pub canvas: Option<String>,
|
||||||
@ -65,6 +66,7 @@ impl Window {
|
|||||||
title: window_descriptor.title.clone(),
|
title: window_descriptor.title.clone(),
|
||||||
vsync: window_descriptor.vsync,
|
vsync: window_descriptor.vsync,
|
||||||
resizable: window_descriptor.resizable,
|
resizable: window_descriptor.resizable,
|
||||||
|
decorations: window_descriptor.decorations,
|
||||||
mode: window_descriptor.mode,
|
mode: window_descriptor.mode,
|
||||||
#[cfg(target_arch = "wasm32")]
|
#[cfg(target_arch = "wasm32")]
|
||||||
canvas: window_descriptor.canvas.clone(),
|
canvas: window_descriptor.canvas.clone(),
|
||||||
@ -80,6 +82,7 @@ pub struct WindowDescriptor {
|
|||||||
pub title: String,
|
pub title: String,
|
||||||
pub vsync: bool,
|
pub vsync: bool,
|
||||||
pub resizable: bool,
|
pub resizable: bool,
|
||||||
|
pub decorations: bool,
|
||||||
pub mode: WindowMode,
|
pub mode: WindowMode,
|
||||||
#[cfg(target_arch = "wasm32")]
|
#[cfg(target_arch = "wasm32")]
|
||||||
pub canvas: Option<String>,
|
pub canvas: Option<String>,
|
||||||
@ -98,6 +101,7 @@ impl Default for WindowDescriptor {
|
|||||||
height: 720,
|
height: 720,
|
||||||
vsync: true,
|
vsync: true,
|
||||||
resizable: true,
|
resizable: true,
|
||||||
|
decorations: true,
|
||||||
mode: WindowMode::Windowed,
|
mode: WindowMode::Windowed,
|
||||||
#[cfg(target_arch = "wasm32")]
|
#[cfg(target_arch = "wasm32")]
|
||||||
canvas: None,
|
canvas: None,
|
||||||
|
@ -35,7 +35,8 @@ impl WinitWindows {
|
|||||||
)),
|
)),
|
||||||
_ => winit_window_builder
|
_ => winit_window_builder
|
||||||
.with_inner_size(winit::dpi::PhysicalSize::new(window.width, window.height))
|
.with_inner_size(winit::dpi::PhysicalSize::new(window.width, window.height))
|
||||||
.with_resizable(window.resizable),
|
.with_resizable(window.resizable)
|
||||||
|
.with_decorations(window.decorations),
|
||||||
};
|
};
|
||||||
|
|
||||||
#[allow(unused_mut)]
|
#[allow(unused_mut)]
|
||||||
|
Loading…
Reference in New Issue
Block a user