first try to allow child window on windows

This commit is contained in:
k-brac 2016-11-25 17:05:39 +01:00
parent 13620118f6
commit 5a09e8ba21
5 changed files with 83 additions and 14 deletions

View file

@ -3,6 +3,7 @@
use libc;
use Window;
use WindowBuilder;
use window;
/// Additional methods on `Window` that are specific to Windows.
pub trait WindowExt {
@ -23,8 +24,14 @@ impl WindowExt for Window {
/// Additional methods on `WindowBuilder` that are specific to Windows.
pub trait WindowBuilderExt {
fn with_parent_window(self, parent: window::WindowProxy) -> WindowBuilder;
}
impl WindowBuilderExt for WindowBuilder {
/// Sets a parent to the window to be created
#[inline]
fn with_parent_window(mut self, parent: window::WindowProxy) -> WindowBuilder {
self.platform_specific.parent = Some(parent);
self
}
}