diff --git a/ui/build.rs b/ui/build.rs index 71763a3..7ad38a0 100644 --- a/ui/build.rs +++ b/ui/build.rs @@ -1,7 +1,7 @@ fn main() { glib_build_tools::compile_resources( &["rsc"], - "rsc/resources.gresource.xml", - "ui.gresource", + "rsc/lsfg-vk.xml", + "lsfg-vk.gresource", ); } diff --git a/ui/rsc/entry.ui b/ui/rsc/entry/entry.ui similarity index 100% rename from ui/rsc/entry.ui rename to ui/rsc/entry/entry.ui diff --git a/ui/rsc/resources.gresource.xml b/ui/rsc/lsfg-vk.xml similarity index 90% rename from ui/rsc/resources.gresource.xml rename to ui/rsc/lsfg-vk.xml index b1d3e98..ca7a1fa 100644 --- a/ui/rsc/resources.gresource.xml +++ b/ui/rsc/lsfg-vk.xml @@ -1,8 +1,7 @@ - entry.ui - window.ui + entry/entry.ui pane/main.ui pane/sidebar.ui pref/dropdown.ui @@ -10,5 +9,6 @@ pref/entry.ui pref/slider.ui pref/switch.ui + window.ui diff --git a/ui/rsc/pane/main.ui b/ui/rsc/pane/main.ui index e4a0f03..45fd1bc 100644 --- a/ui/rsc/pane/main.ui +++ b/ui/rsc/pane/main.ui @@ -34,12 +34,14 @@ Path to Lossless.dll + (Global Option) Override where lsfg-vk finds Lossless Scaling Preset name + Command name used for automatically activating in games. @@ -52,18 +54,21 @@ Multiplier + Double, triple or quadruple your FPS. Flow Scale + Lowers the internal motion estimation resolution Performance Mode + Massively improve performance at the cost of quality. false @@ -77,18 +82,20 @@ HDR Mode + Enable special HDR-only behavior. false - Experimental Present Mode + Present Mode + (Experimental) Override the present mode to immediate or mailbox. 0 - VSync/FIFO + VSync/FIFO (Default, Recommended) Mailbox Immediate diff --git a/ui/rsc/pref/dropdown.ui b/ui/rsc/pref/dropdown.ui index a3b38c7..263b179 100644 --- a/ui/rsc/pref/dropdown.ui +++ b/ui/rsc/pref/dropdown.ui @@ -11,11 +11,31 @@ 8 8 - - - start + + vertical + 4 + center true + + + + start + true + + + + + + start + true + + + diff --git a/ui/rsc/pref/entry.ui b/ui/rsc/pref/entry.ui index 6a821f6..123e382 100644 --- a/ui/rsc/pref/entry.ui +++ b/ui/rsc/pref/entry.ui @@ -11,11 +11,31 @@ 8 8 - - - start + + vertical + 4 + center true + + + + start + true + + + + + + start + true + + + diff --git a/ui/rsc/pref/number.ui b/ui/rsc/pref/number.ui index fb4e838..314d3ce 100644 --- a/ui/rsc/pref/number.ui +++ b/ui/rsc/pref/number.ui @@ -11,11 +11,31 @@ 8 8 - - - start + + vertical + 4 + center true + + + + start + true + + + + + + start + true + + + diff --git a/ui/rsc/pref/slider.ui b/ui/rsc/pref/slider.ui index eb833db..a790f11 100644 --- a/ui/rsc/pref/slider.ui +++ b/ui/rsc/pref/slider.ui @@ -11,11 +11,31 @@ 8 8 - - - start + + vertical + 4 + center true + + + + start + true + + + + + + start + true + + + diff --git a/ui/rsc/pref/switch.ui b/ui/rsc/pref/switch.ui index e167001..e5fa6c1 100644 --- a/ui/rsc/pref/switch.ui +++ b/ui/rsc/pref/switch.ui @@ -11,11 +11,31 @@ 8 8 - - - start + + vertical + 4 + center true + + + + start + true + + + + + + start + true + + + @@ -23,6 +43,7 @@ compact + 70 diff --git a/ui/src/main.rs b/ui/src/main.rs index 1093d1d..48be441 100644 --- a/ui/src/main.rs +++ b/ui/src/main.rs @@ -17,7 +17,7 @@ struct State { static STATE: OnceLock>> = OnceLock::new(); fn main() { - gio::resources_register_include!("ui.gresource") + gio::resources_register_include!("lsfg-vk.gresource") .expect("Failed to register resources"); config::load_config() .expect("Failed to load configuration"); diff --git a/ui/src/wrapper/entry/entry.rs b/ui/src/wrapper/entry/entry.rs index 0a65df7..301e974 100644 --- a/ui/src/wrapper/entry/entry.rs +++ b/ui/src/wrapper/entry/entry.rs @@ -6,7 +6,7 @@ use gtk::prelude::*; #[derive(gtk::CompositeTemplate, glib::Properties, Default)] #[properties(wrapper_type = super::Entry)] -#[template(resource = "/gay/pancake/lsfg-vk/entry.ui")] +#[template(resource = "/gay/pancake/lsfg-vk/entry/entry.ui")] pub struct Entry { #[property(get, set)] exe: RefCell, diff --git a/ui/src/wrapper/pref/dropdown.rs b/ui/src/wrapper/pref/dropdown.rs index 0895a76..2020a6a 100644 --- a/ui/src/wrapper/pref/dropdown.rs +++ b/ui/src/wrapper/pref/dropdown.rs @@ -12,6 +12,8 @@ pub struct PrefDropdown { #[property(get, set)] opt_name: RefCell, #[property(get, set)] + opt_subtitle: RefCell, + #[property(get, set)] default_selection: RefCell, #[property(get, set)] options: RefCell, diff --git a/ui/src/wrapper/pref/entry.rs b/ui/src/wrapper/pref/entry.rs index a6a5b38..fbfd793 100644 --- a/ui/src/wrapper/pref/entry.rs +++ b/ui/src/wrapper/pref/entry.rs @@ -12,6 +12,8 @@ pub struct PrefEntry { #[property(get, set)] opt_name: RefCell, #[property(get, set)] + opt_subtitle: RefCell, + #[property(get, set)] default_text: RefCell, #[property(get, set)] tooltip_text: RefCell, diff --git a/ui/src/wrapper/pref/number.rs b/ui/src/wrapper/pref/number.rs index 5d96c96..fc6bad3 100644 --- a/ui/src/wrapper/pref/number.rs +++ b/ui/src/wrapper/pref/number.rs @@ -11,6 +11,8 @@ use adw::prelude::*; pub struct PrefNumber { #[property(get, set)] opt_name: RefCell, + #[property(get, set)] + opt_subtitle: RefCell, #[template_child] pub number: TemplateChild, diff --git a/ui/src/wrapper/pref/slider.rs b/ui/src/wrapper/pref/slider.rs index 7cd7edd..207cbd0 100644 --- a/ui/src/wrapper/pref/slider.rs +++ b/ui/src/wrapper/pref/slider.rs @@ -11,6 +11,8 @@ use adw::prelude::*; pub struct PrefSlider { #[property(get, set)] opt_name: RefCell, + #[property(get, set)] + opt_subtitle: RefCell, #[template_child] pub slider: TemplateChild, diff --git a/ui/src/wrapper/pref/switch.rs b/ui/src/wrapper/pref/switch.rs index e438546..7f3d77b 100644 --- a/ui/src/wrapper/pref/switch.rs +++ b/ui/src/wrapper/pref/switch.rs @@ -12,6 +12,8 @@ pub struct PrefSwitch { #[property(get, set)] opt_name: RefCell, #[property(get, set)] + opt_subtitle: RefCell, + #[property(get, set)] default_state: RefCell, #[template_child]