feat: additional debug, fixed decorations issue

This commit is contained in:
imgurbot12 2024-07-08 22:37:50 -07:00
parent 64103fcd1b
commit ab1b68e7db
4 changed files with 87 additions and 1 deletions

81
Cargo.lock generated
View File

@ -494,6 +494,39 @@ version = "1.6.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "514de17de45fdb8dc022b1a7975556c53c86f9f0aa5f534b98977b171857c2c9"
[[package]]
name = "cached"
version = "0.52.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a8466736fe5dbcaf8b8ee24f9bbefe43c884dc3e9ff7178da70f55bffca1133c"
dependencies = [
"ahash",
"cached_proc_macro",
"cached_proc_macro_types",
"hashbrown 0.14.5",
"instant",
"once_cell",
"thiserror",
]
[[package]]
name = "cached_proc_macro"
version = "0.22.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "575f32e012222055211b70f5b0601f951f84523410a0e65c81f2744a6042450d"
dependencies = [
"darling",
"proc-macro2",
"quote",
"syn 2.0.66",
]
[[package]]
name = "cached_proc_macro_types"
version = "0.1.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "ade8366b8bd5ba243f0a58f036cc0ca8a2f069cff1a2351ef1cac6b083e16fc0"
[[package]]
name = "cairo-rs"
version = "0.18.5"
@ -940,6 +973,7 @@ dependencies = [
"ident_case",
"proc-macro2",
"quote",
"strsim",
"syn 2.0.66",
]
@ -2659,6 +2693,14 @@ dependencies = [
"log",
]
[[package]]
name = "lastlog"
version = "0.3.0"
source = "git+https://github.com/imgurbot12/lastlog#58eb3daf9f1e56ed033a4d1acb89ba3c445ed536"
dependencies = [
"libc",
]
[[package]]
name = "lazy_static"
version = "1.4.0"
@ -3677,19 +3719,28 @@ dependencies = [
name = "rmenu"
version = "1.2.2"
dependencies = [
"cached",
"clap",
"dioxus",
"dioxus-desktop",
"env_logger",
"heck 0.5.0",
"lastlog",
"log",
"once_cell",
"png",
"regex",
"resvg",
"rmenu-plugin",
"serde",
"serde_json",
"serde_yaml",
"shell-words",
"shellexpand",
"strfmt",
"thiserror",
"tokio",
"which",
"xdg",
]
@ -4040,6 +4091,12 @@ dependencies = [
"lazy_static",
]
[[package]]
name = "shell-words"
version = "1.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "24188a676b6ae68c3b2cb3a01be17fbf7240ce009799bb56d5b1409051e78fde"
[[package]]
name = "shellexpand"
version = "3.1.0"
@ -4206,6 +4263,12 @@ version = "1.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f"
[[package]]
name = "strfmt"
version = "0.2.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "7a8348af2d9fc3258c8733b8d9d8db2e56f54b2363a4b5b81585c7875ed65e65"
[[package]]
name = "strict-num"
version = "0.1.1"
@ -5047,6 +5110,18 @@ version = "0.1.8"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "53a85b86a771b1c87058196170769dd264f66c0782acf1ae6cc51bfd64b39082"
[[package]]
name = "which"
version = "6.0.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "8211e4f58a2b2805adfbefbc07bab82958fc91e3836339b1ab7ae32465dce0d7"
dependencies = [
"either",
"home",
"rustix 0.38.34",
"winsafe",
]
[[package]]
name = "winapi"
version = "0.3.9"
@ -5408,6 +5483,12 @@ dependencies = [
"memchr",
]
[[package]]
name = "winsafe"
version = "0.0.19"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d135d17ab770252ad95e9a872d365cf3090e3be864a34ab46f48555993efc904"
[[package]]
name = "wry"
version = "0.37.0"

View File

@ -341,6 +341,7 @@ impl Args {
match crate::cache::read_cache(&name, &plugin) {
Err(err) => log::error!("cache read failed: {err:?}"),
Ok(cached) => {
log::debug!("plugin {name:?} loaded entries from cache");
entries.extend(cached);
continue;
}
@ -355,6 +356,7 @@ impl Args {
.get(0)
.ok_or_else(|| RMenuError::InvalidPlugin(name.to_owned()))?;
// spawn command
log::debug!("plugin {name:?} reading from command output");
let mut command = Command::new(main)
.args(&args[1..])
.stdout(Stdio::piped())

View File

@ -23,7 +23,9 @@ pub fn run(ctx: Context) {
.with_inner_size(ctx.config.window.logical_size())
.with_fullscreen(ctx.config.window.get_fullscreen())
.with_theme(ctx.config.window.get_theme());
let config = dioxus_desktop::Config::default().with_window(window);
let config = dioxus_desktop::Config::default()
.with_window(window)
.with_menu(None);
LaunchBuilder::desktop()
.with_cfg(config)
.with_context(Rc::new(RefCell::new(ctx)))

View File

@ -48,6 +48,7 @@ fn main() -> cli::Result<()> {
cli.set_env();
// run gui
log::debug!("launching gui");
let context = gui::ContextBuilder::default()
.with_css(css)
.with_theme(theme)