mirror of
https://github.com/rust-windowing/winit.git
synced 2026-06-28 07:33:14 -04:00
Move PlatformSpecificWindowBuilderAttributes (#3318)
This commit is contained in:
@@ -30,8 +30,7 @@ pub struct Inner {
|
||||
impl Window {
|
||||
pub(crate) fn new(
|
||||
target: &EventLoopWindowTarget,
|
||||
attr: WindowAttributes,
|
||||
platform_attr: PlatformSpecificWindowBuilderAttributes,
|
||||
mut attr: WindowAttributes,
|
||||
) -> Result<Self, RootOE> {
|
||||
let id = target.generate_id();
|
||||
|
||||
@@ -42,8 +41,7 @@ impl Window {
|
||||
id,
|
||||
window.clone(),
|
||||
document.clone(),
|
||||
&attr,
|
||||
platform_attr,
|
||||
&mut attr,
|
||||
)?;
|
||||
let canvas = Rc::new(RefCell::new(canvas));
|
||||
|
||||
@@ -467,7 +465,7 @@ impl From<u64> for WindowId {
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Clone)]
|
||||
#[derive(Clone, Debug)]
|
||||
pub struct PlatformSpecificWindowBuilderAttributes {
|
||||
pub(crate) canvas: Option<Arc<MainThreadSafe<backend::RawCanvasType>>>,
|
||||
pub(crate) prevent_default: bool,
|
||||
|
||||
Reference in New Issue
Block a user