add: ActiveEventLoop::create_proxy()

Co-authored-by: Kirill Chibisov <contact@kchibisov.com>
This commit is contained in:
daxpedda 2024-06-29 17:19:09 +02:00 committed by GitHub
parent 2e93e48a3b
commit a0d69c782a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
14 changed files with 78 additions and 71 deletions

View file

@ -468,16 +468,16 @@ impl EventLoop {
}
}
pub fn create_proxy(&self) -> EventLoopProxy {
EventLoopProxy { target_window: self.window_target.p.thread_msg_target }
}
fn exit_code(&self) -> Option<i32> {
self.window_target.p.exit_code()
}
}
impl ActiveEventLoop {
pub fn create_proxy(&self) -> EventLoopProxy {
EventLoopProxy { target_window: self.thread_msg_target }
}
#[inline(always)]
pub(crate) fn create_thread_executor(&self) -> EventLoopThreadExecutor {
EventLoopThreadExecutor { thread_id: self.thread_id, target_window: self.thread_msg_target }