to web
parent
9c71c3ed3e
commit
bf3c1af8e5
File diff suppressed because it is too large
Load Diff
|
|
@ -9,5 +9,5 @@ edition = "2021"
|
|||
dioxus = "0.4.3"
|
||||
lib = { path = "../src-lib" }
|
||||
base64 = "0.21.5"
|
||||
#dioxus-web = "0.4.3"
|
||||
dioxus-desktop = "0.4.3"
|
||||
dioxus-web = "0.4.3"
|
||||
#dioxus-desktop = "0.4.3"
|
||||
|
|
|
|||
|
|
@ -6,8 +6,8 @@ use base64::{engine::general_purpose, Engine as _};
|
|||
|
||||
fn main() {
|
||||
// launch the dioxus app in a webview
|
||||
dioxus_desktop::launch(App); // TODO desktop
|
||||
//dioxus_web::launch(App);
|
||||
//dioxus_desktop::launch(App); // TODO desktop
|
||||
dioxus_web::launch(App);
|
||||
}
|
||||
|
||||
// define a component that renders a div with the text "Hello, world!"
|
||||
|
|
@ -29,7 +29,6 @@ fn App(cx: Scope) -> Element {
|
|||
if let Some(file_engine) = &evt.files {
|
||||
for f in &file_engine.files() {
|
||||
file.set(f.clone()); // TODO swap to .path() on desktop
|
||||
//file.set(f.path().clone()); // TODO swap to .path() on desktop
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -72,8 +71,8 @@ struct Analyzed {
|
|||
}
|
||||
|
||||
fn analyze(file: String) -> Vec<Analyzed> {
|
||||
let content_spans = lib::video::inspect(&file); // TODO desktop
|
||||
//let content_spans: Result<Vec<lib::video::ContentSpan>, String> = Ok(vec![lib::video::ContentSpan{start: 0.5, stop: 20.2}]);
|
||||
//let content_spans = lib::video::inspect(&file); // TODO desktop
|
||||
let content_spans: Result<Vec<lib::video::ContentSpan>, String> = Ok(vec![lib::video::ContentSpan{start: 0.5, stop: 20.2}]);
|
||||
if content_spans.is_err() {
|
||||
return vec![Analyzed{
|
||||
start: format!("<<err analyzing {}", file),
|
||||
|
|
|
|||
Loading…
Reference in New Issue