From d871b89ef01c056ca8a465f2d1736c58c979f905 Mon Sep 17 00:00:00 2001 From: Jackson Goode Date: Sun, 11 Feb 2024 12:20:40 -0800 Subject: [PATCH] Rename --- psst-gui/src/controller/playback.rs | 2 +- psst-gui/src/data/config.rs | 4 ++-- psst-gui/src/ui/preferences.rs | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/psst-gui/src/controller/playback.rs b/psst-gui/src/controller/playback.rs index 8577bf14..cd1db0ae 100644 --- a/psst-gui/src/controller/playback.rs +++ b/psst-gui/src/controller/playback.rs @@ -276,7 +276,7 @@ impl PlaybackController { fn seek_relative(&mut self, data: &AppState, forward: bool) { if let Some(now_playing) = &data.playback.now_playing { - let seek_duration = Duration::from_secs(data.config.step_duration as u64); + let seek_duration = Duration::from_secs(data.config.seek_duration as u64); // Calculate new position, ensuring it does not exceed duration for forward seeks. let seek_position = if forward { diff --git a/psst-gui/src/data/config.rs b/psst-gui/src/data/config.rs index 96adbb67..62fcb526 100644 --- a/psst-gui/src/data/config.rs +++ b/psst-gui/src/data/config.rs @@ -94,7 +94,7 @@ pub struct Config { pub sort_order: SortOrder, pub sort_criteria: SortCriteria, pub paginated_limit: usize, - pub step_duration: usize, + pub seek_duration: usize, } impl Default for Config { @@ -112,7 +112,7 @@ impl Default for Config { sort_order: Default::default(), sort_criteria: Default::default(), paginated_limit: 500, - step_duration: 10, + seek_duration: 10, } } } diff --git a/psst-gui/src/ui/preferences.rs b/psst-gui/src/ui/preferences.rs index 0866bf06..1192db92 100644 --- a/psst-gui/src/ui/preferences.rs +++ b/psst-gui/src/ui/preferences.rs @@ -213,7 +213,7 @@ fn general_tab_widget() -> impl Widget { col = col.with_spacer(theme::grid(3.0)); col = col - .with_child(Label::new("Step Duration").with_font(theme::UI_FONT_MEDIUM)) + .with_child(Label::new("Seek Duration").with_font(theme::UI_FONT_MEDIUM)) .with_spacer(theme::grid(2.0)) .with_child( Flex::row() @@ -223,7 +223,7 @@ fn general_tab_widget() -> impl Widget { )), ) .padding((theme::grid(1.5), 0.0)) - .lens(AppState::config.then(Config::step_duration)), + .lens(AppState::config.then(Config::seek_duration)), ); col = col.with_spacer(theme::grid(3.0));