Move resize_callback field from WindowBuilder into WindowAttributes struct

This commit is contained in:
mitchmindtree 2016-11-12 02:55:21 +11:00
parent eb18b3d8b6
commit 53065bda40
2 changed files with 7 additions and 7 deletions

View file

@ -107,10 +107,6 @@ pub struct WindowBuilder {
/// Platform-specific configuration.
platform_specific: platform::PlatformSpecificWindowBuilderAttributes,
/// A function called upon resizing, necessary to receive resize events on Mac and possibly
/// other systems.
window_resize_callback: Option<fn(u32, u32)>,
}
/// Error that can happen while creating a window or a headless renderer.
@ -263,6 +259,10 @@ pub struct WindowAttributes {
/// [iOS only] Enable multitouch, see [UIView#multipleTouchEnabled]
/// (https://developer.apple.com/library/ios/documentation/UIKit/Reference/UIView_Class/#//apple_ref/occ/instp/UIView/multipleTouchEnabled)
pub multitouch: bool,
/// A function called upon resizing, necessary to receive resize events on Mac and possibly
/// other systems.
pub resize_callback: Option<fn(u32, u32)>,
}
impl Default for WindowAttributes {
@ -278,6 +278,7 @@ impl Default for WindowAttributes {
transparent: false,
decorations: true,
multitouch: false,
resize_callback: None,
}
}
}