child window creation improvement
This commit is contained in:
parent
5a09e8ba21
commit
2b25bf1480
4 changed files with 31 additions and 3 deletions
|
|
@ -361,7 +361,7 @@ impl Window {
|
|||
/// threads.
|
||||
#[derive(Clone)]
|
||||
pub struct WindowProxy {
|
||||
pub proxy: platform::WindowProxy,
|
||||
proxy: platform::WindowProxy,
|
||||
}
|
||||
|
||||
impl WindowProxy {
|
||||
|
|
@ -372,6 +372,18 @@ impl WindowProxy {
|
|||
pub fn wakeup_event_loop(&self) {
|
||||
self.proxy.wakeup_event_loop();
|
||||
}
|
||||
|
||||
/// Returns the platform specific proxy data
|
||||
#[inline]
|
||||
pub fn get_proxy_data(&self) -> &platform::WindowProxy {
|
||||
&self.proxy
|
||||
}
|
||||
|
||||
/// Create a WindowProxy by directly setting its platform specific data
|
||||
#[inline]
|
||||
pub fn create_proxy(data: platform::WindowProxy) -> WindowProxy {
|
||||
WindowProxy {proxy: data}
|
||||
}
|
||||
}
|
||||
/// An iterator for the `poll_events` function.
|
||||
pub struct PollEventsIterator<'a>(platform::PollEventsIterator<'a>);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue