Rust codegen that forward to the interpreter (live-reload)

When the SLINT_LIVE_RELOAD env variable is set, generate a component
that will forward everything to the interpreter instead of generating
everything.

Fix running the test driver rust with the SLINT_LIVE_RELOAD

```
SLINT_LIVE_RELOAD=1 cargo test -p test-driver-rust --all-features --features=slint/live-reload
```
This commit is contained in:
Olivier Goffart 2025-05-28 11:20:40 +02:00
parent ec12f22653
commit cc9c573c9a
6 changed files with 545 additions and 40 deletions

View file

@ -442,6 +442,7 @@ pub fn compile_with_config(
println!("cargo:rerun-if-env-changed=SLINT_ASSET_SECTION");
println!("cargo:rerun-if-env-changed=SLINT_EMBED_RESOURCES");
println!("cargo:rerun-if-env-changed=SLINT_EMIT_DEBUG_INFO");
println!("cargo:rerun-if-env-changed=SLINT_LIVE_RELOAD");
println!(
"cargo:rustc-env=SLINT_INCLUDE_GENERATED={}",