From 75164cdaa9a9826c9ca8bc7246ea4abfe22e38db Mon Sep 17 00:00:00 2001 From: Lachezar Lechev Date: Tue, 24 Oct 2023 17:15:14 +0300 Subject: [PATCH] fix: typo for esc exit fullscreen Signed-off-by: Lachezar Lechev --- src/runtime/env.rs | 4 ++-- src/types/profile/settings.rs | 4 ++-- src/unit_tests/serde/default_tokens_ext.rs | 2 +- src/unit_tests/serde/settings.rs | 6 +++--- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/runtime/env.rs b/src/runtime/env.rs index a0e1c6779..8947f5989 100644 --- a/src/runtime/env.rs +++ b/src/runtime/env.rs @@ -479,7 +479,7 @@ fn migrate_storage_schema_to_v9() -> TryEnvFuture<()> { ); // add the new setting for Escape key exiting full screen - settings.insert("escExistFullscreen".to_owned(), true.into()); + settings.insert("escExitFullscreen".to_owned(), true.into()); // add the new setting for pause on minimize, which is disabled by default settings.insert("pauseOnMinimize".to_owned(), false.into()); E::set_storage(PROFILE_STORAGE_KEY, Some(&profile)) @@ -833,7 +833,7 @@ mod test { let migrated_profile = json!({ "settings": { - "escExistFullscreen": true, + "escExitFullscreen": true, "seekShortTimeDuration": 3000, "pauseOnMinimize": false, } diff --git a/src/types/profile/settings.rs b/src/types/profile/settings.rs index 43b6779fa..dc4e03003 100644 --- a/src/types/profile/settings.rs +++ b/src/types/profile/settings.rs @@ -27,7 +27,7 @@ pub struct Settings { pub subtitles_background_color: String, pub subtitles_outline_color: String, /// Whether or not the Escape key should exists from the app when in Full screen. - pub esc_exist_fullscreen: bool, + pub esc_exit_fullscreen: bool, /// The Seek time duration (in milliseconds) is when using the Arrow keys pub seek_time_duration: u32, /// The Seek short time duration (in milliseconds) is when we are finer seeking, @@ -68,7 +68,7 @@ impl Default for Settings { subtitles_text_color: "#FFFFFFFF".to_owned(), subtitles_background_color: "#00000000".to_owned(), subtitles_outline_color: "#000000".to_owned(), - esc_exist_fullscreen: true, + esc_exit_fullscreen: true, seek_time_duration: 10000, seek_short_time_duration: 3000, pause_on_minimize: false, diff --git a/src/unit_tests/serde/default_tokens_ext.rs b/src/unit_tests/serde/default_tokens_ext.rs index 5f5eb8969..52b35569a 100644 --- a/src/unit_tests/serde/default_tokens_ext.rs +++ b/src/unit_tests/serde/default_tokens_ext.rs @@ -416,7 +416,7 @@ impl DefaultTokens for Settings { Token::Str("#00000000"), Token::Str("subtitlesOutlineColor"), Token::Str("#000000"), - Token::Str("escExistFullscreen"), + Token::Str("escExitFullscreen"), Token::Bool(true), Token::Str("seekTimeDuration"), Token::U32(10000), diff --git a/src/unit_tests/serde/settings.rs b/src/unit_tests/serde/settings.rs index 9491ba86e..e02c31cdf 100644 --- a/src/unit_tests/serde/settings.rs +++ b/src/unit_tests/serde/settings.rs @@ -27,7 +27,7 @@ fn settings() { subtitles_text_color: "subtitles_text_color".to_owned(), subtitles_background_color: "subtitles_background_color".to_owned(), subtitles_outline_color: "subtitles_outline_color".to_owned(), - esc_exist_fullscreen: true, + esc_exit_fullscreen: true, seek_time_duration: 10, seek_short_time_duration: 3, pause_on_minimize: true, @@ -86,7 +86,7 @@ fn settings() { Token::Str("subtitles_background_color"), Token::Str("subtitlesOutlineColor"), Token::Str("subtitles_outline_color"), - Token::Str("escExistFullscreen"), + Token::Str("escExitFullscreen"), Token::Bool(true), Token::Str("seekTimeDuration"), Token::U32(10), @@ -150,7 +150,7 @@ fn settings_de() { Token::Str("#00000000"), Token::Str("subtitlesOutlineColor"), Token::Str("#000000"), - Token::Str("escExistFullscreen"), + Token::Str("escExitFullscreen"), Token::Bool(true), Token::Str("seekTimeDuration"), Token::U32(10000),