Add argument for no-vsync (#185)

Default is vsync on
This commit is contained in:
Philip Kristoffersen
2022-07-18 09:23:46 +02:00
committed by GitHub
parent e377224573
commit 4bafe868cc
3 changed files with 14 additions and 7 deletions
+4 -4
View File
@@ -1,6 +1,7 @@
mod amazon;
mod config;
mod egs;
mod flatpak;
mod gog;
mod heroic;
mod itch;
@@ -15,19 +16,18 @@ mod steamgriddb;
mod sync;
mod ui;
mod uplay;
mod flatpak;
use std::error::Error;
fn main() -> Result<(), Box<dyn Error>> {
ensure_config_folder();
migration::migrate_config();
let mut args = std::env::args();
if args.len() > 1 && args.nth(1).unwrap_or_default() == "--no-ui" {
let args: Vec<String> = std::env::args().collect();
if args.contains(&"--no-ui".to_string()) {
ui::run_sync();
Ok(())
} else {
ui::run_ui()
ui::run_ui(args)
}
}