mirror of
https://github.com/rustdesk/rustdesk.git
synced 2026-11-13 06:42:18 +00:00
feat: insert core entry before launching flutter
This commit is contained in:
1 parent
3a1bbc260b
commit
7cd0940661
4 files changed
+55
-4
No files matched your search
@@ -52,6 +52,13 @@ fn initialize(app_dir: &str) {
|
||||
}
|
||||
}
|
||||
|
||||
/// FFI for rustdesk core's main entry.
|
||||
/// Return true if the app should continue running with UI(possibly Flutter), false if the app should exit.
|
||||
#[no_mangle]
|
||||
pub extern "C" fn rustdesk_core_main() -> bool {
|
||||
crate::core_main::core_main()
|
||||
}
|
||||
|
||||
pub fn start_event_stream(s: StreamSink<String>) -> ResultType<()> {
|
||||
let _ = flutter::EVENT_STREAM.write().unwrap().insert(s);
|
||||
Ok(())
|
||||
|
||||
Reference in new issue
Block a user