clippy, and don't hash invisible files for ts generation
This commit is contained in:
27 files changed
+173
-936
No files matched your search
@@ -1,7 +1,7 @@
|
||||
pub use crate::Config;
|
||||
use crate::{
|
||||
app::App,
|
||||
ipc::{EventData, IpcMethod, UserWindowEvent},
|
||||
ipc::{IpcMethod, UserWindowEvent},
|
||||
};
|
||||
use dioxus_core::*;
|
||||
use std::any::Any;
|
||||
@@ -15,6 +15,7 @@ pub fn launch_virtual_dom_blocking(virtual_dom: VirtualDom, desktop_config: Conf
|
||||
let (event_loop, mut app) = App::new(desktop_config, virtual_dom);
|
||||
|
||||
event_loop.run(move |window_event, _, control_flow| {
|
||||
// Set the control flow and check if any events need to be handled in the app itself
|
||||
app.tick(&window_event);
|
||||
|
||||
match window_event {
|
||||
@@ -26,19 +27,20 @@ pub fn launch_virtual_dom_blocking(virtual_dom: VirtualDom, desktop_config: Conf
|
||||
WindowEvent::Destroyed { .. } => app.window_destroyed(window_id),
|
||||
_ => {}
|
||||
},
|
||||
Event::UserEvent(UserWindowEvent(event, id)) => match event {
|
||||
EventData::Poll => app.poll_vdom(id),
|
||||
EventData::NewWindow => app.handle_new_window(),
|
||||
EventData::CloseWindow => app.handle_close_msg(id),
|
||||
|
||||
Event::UserEvent(event) => match event {
|
||||
UserWindowEvent::Poll(id) => app.poll_vdom(id),
|
||||
UserWindowEvent::NewWindow => app.handle_new_window(),
|
||||
UserWindowEvent::CloseWindow(id) => app.handle_close_msg(id),
|
||||
UserWindowEvent::GlobalHotKeyEvent(evnt) => app.handle_global_hotkey(evnt),
|
||||
#[cfg(all(feature = "hot-reload", debug_assertions))]
|
||||
EventData::HotReloadEvent(msg) => app.handle_hot_reload_msg(msg),
|
||||
EventData::Ipc(msg) => match msg.method() {
|
||||
UserWindowEvent::HotReloadEvent(msg) => app.handle_hot_reload_msg(msg),
|
||||
UserWindowEvent::Ipc { id, msg } => match msg.method() {
|
||||
IpcMethod::Initialize => app.handle_initialize_msg(id),
|
||||
IpcMethod::FileDialog => app.handle_file_dialog_msg(msg, id),
|
||||
IpcMethod::FileDrag => app.handle_file_drag(msg, id),
|
||||
IpcMethod::UserEvent => app.handle_user_event_msg(msg, id),
|
||||
IpcMethod::Query => app.handle_query_msg(msg, id),
|
||||
IpcMethod::BrowserOpen => app.handle_browser_open(msg),
|
||||
IpcMethod::Initialize => app.handle_initialize_msg(id),
|
||||
IpcMethod::Other(_) => {}
|
||||
},
|
||||
},
|
||||
|
||||
Reference in new issue
Block a user