tauri-runtime-servocat 1.4.0

Servo-replacement runtime for Tauri: wires html-cat, css-cat, dom-cat, layout-cat, paint-cat, net-cat, boa-cat, ecma-runtime-cat, and web-api-cat into a single rendering + scripting pipeline. v1.4.0 wires monitor enumeration (`primary_monitor` / `available_monitors` / `monitor_from_point`) through the live winit event loop, hooks up `run_on_main_thread` so worker threads can dispatch closures back to the main thread, and extends `WebviewDispatch::navigate` to handle `file://` URLs and percent-encoded `data:` URLs (plus blocking `http://` via net-cat for non-localhost fetches). The Servo no-AI policy disqualifies upstream contribution; this is the AI-built parallel.
//! v1.1 demo: drive the `tauri_runtime::Runtime` trait skeleton on
//! the main thread.  Opens a window via `Runtime::create_window`,
//! sets its title via `WindowDispatch::set_title`, runs the event
//! loop, and exits when the window is closed.
//!
//! Run with `cargo run --bin demo_tauri_runtime`.

use std::time::Duration;

use tauri_runtime::window::{PendingWindow, WindowBuilder};
use tauri_runtime::{Runtime, RuntimeInitArgs, WindowDispatch};
use tauri_runtime_servocat::{ServocatRuntime, ServocatWindowBuilder};

fn main() {
    let _ = ServocatRuntime::<()>::new(RuntimeInitArgs::default()).map(|runtime| {
        let attrs = ServocatWindowBuilder::new()
            .title("tauri-runtime-servocat v1.1")
            .inner_size(640.0, 480.0)
            .resizable(true)
            .visible(true);
        let _ = PendingWindow::<(), ServocatRuntime<()>>::new(attrs, "main").map(|pending| {
            let _ = runtime
                .create_window::<fn(tauri_runtime::window::RawWindow)>(pending, None)
                .map(|detached| {
                    let dispatcher = detached.dispatcher.clone();
                    let _ = std::thread::spawn(move || {
                        std::thread::sleep(Duration::from_millis(500));
                        let _ = dispatcher.set_title("tauri-runtime-servocat v1.1 (renamed)");
                    });
                    runtime.run(|_event| {});
                });
        });
    });
}