feat(player): update config module
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
//! Configuration module
|
||||
//!
|
||||
//!
|
||||
//! Command line arguments and runtime configuration
|
||||
|
||||
use anyhow::Result;
|
||||
@@ -19,16 +19,30 @@ pub struct Config {
|
||||
#[arg(short = 'y', long = "yolo", help = "YOLO JSON file path")]
|
||||
pub yolo: Option<PathBuf>,
|
||||
|
||||
#[arg(short = 'w', long = "width", default_value = "1280", help = "Window width")]
|
||||
#[arg(
|
||||
short = 'w',
|
||||
long = "width",
|
||||
default_value = "1280",
|
||||
help = "Window width"
|
||||
)]
|
||||
pub width: u32,
|
||||
|
||||
#[arg(short = 'h', long = "height", default_value = "720", help = "Window height")]
|
||||
#[arg(
|
||||
short = 'h',
|
||||
long = "height",
|
||||
default_value = "720",
|
||||
help = "Window height"
|
||||
)]
|
||||
pub height: u32,
|
||||
|
||||
#[arg(long = "fullscreen", help = "Start in fullscreen mode")]
|
||||
pub fullscreen: bool,
|
||||
|
||||
#[arg(long = "locale", default_value = "en", help = "UI language (en, zh-TW, etc.)")]
|
||||
#[arg(
|
||||
long = "locale",
|
||||
default_value = "en",
|
||||
help = "UI language (en, zh-TW, etc.)"
|
||||
)]
|
||||
pub locale: String,
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user