Compare commits

...

5 Commits
0.1.4 ... main

Author SHA1 Message Date
Bel LaPointe 6095fd69fc 0.1.6 release 2023-12-28 22:20:22 -05:00
Bel LaPointe 8f1c0876c5 for highlighted spans, add a fat green border 2023-12-28 22:19:59 -05:00
Bel LaPointe 6e2cf357f4 0.1.5 release 2023-12-28 22:17:36 -05:00
Bel LaPointe 4aede62dbb lint 2023-12-28 22:17:21 -05:00
Bel LaPointe c3d6cd1545 menu causes crashes so skip it 2023-12-28 22:16:16 -05:00
4 changed files with 9 additions and 20 deletions

2
src/Cargo.lock generated
View File

@ -1351,7 +1351,7 @@ dependencies = [
[[package]]
name = "home-video-blue-extractinator"
version = "0.1.3"
version = "0.1.6"
dependencies = [
"base64 0.21.5",
"dioxus",

View File

@ -1,6 +1,6 @@
[package]
name = "home-video-blue-extractinator"
version = "0.1.4"
version = "0.1.6"
edition = "2021"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
@ -15,7 +15,7 @@ dioxus-desktop = "0.4.3"
[package.metadata.bundle]
name = "home-video-blue-extractinator"
identifier = "com.breel.home-video-blue-extractinator"
version = "0.1.4"
version = "0.1.6"
copyright = "Copyright (c) breel.dev 2023. All rights reserved."
long_description = """
Tool to turn long home movies into clips with less noise.

View File

@ -1,28 +1,16 @@
#![allow(non_snake_case)]
// import the prelude to get access to the `rsx!` macro and the `Scope` and `Element` types
use dioxus::prelude::*;
use dioxus::hooks::use_future;
use lib;
use base64::{engine::general_purpose, Engine as _};
use core::cmp::Ordering;
use std::str::FromStr;
fn main() {
dioxus_desktop::launch(App);
dioxus_desktop::launch_cfg(App, dioxus_desktop::Config::new()
.with_window(dioxus_desktop::WindowBuilder::new()
.with_title("home-video-blue-extractinator")
.with_menu({
let mut menu = dioxus_desktop::tao::menu::MenuBar::new();
let mut app_menu = dioxus_desktop::tao::menu::MenuBar::new();
app_menu.add_native_item(dioxus_desktop::tao::menu::MenuItem::Minimize);
app_menu.add_native_item(dioxus_desktop::tao::menu::MenuItem::Quit);
menu.add_submenu("&home-video-blue-extractinator", true, app_menu);
menu
}),
),
);
));
}
// define a component that renders a div with the text "Hello, world!"
@ -226,7 +214,7 @@ async fn analyze(file: String) -> Analysis {
stop: content_span.stop.to_string(),
screenshot: match lib::video::screenshot_png(&file, ts) {
Ok(png) => general_purpose::STANDARD.encode(&png),
Err(_) => a_png.to_string(),
Err(_) => A_PNG.to_string(),
},
has_content: false,
}
@ -269,9 +257,9 @@ async fn clipify(file: String, content_spans: Vec<lib::video::ContentSpan>) -> S
}
let _ = opener::open(d.clone());
match statuses.len() {
_ => statuses.join(", "),
0 => d,
_ => statuses.join(", "),
}
}
const a_png: &str = r"iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHElEQVQI12P4//8/w38GIAXDIBKE0DHxgljNBAAO9TXL0Y4OHwAAAABJRU5ErkJggg==";
const A_PNG: &str = r"iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHElEQVQI12P4//8/w38GIAXDIBKE0DHxgljNBAAO9TXL0Y4OHwAAAABJRU5ErkJggg==";

File diff suppressed because one or more lines are too long