File tree Expand file tree Collapse file tree 2 files changed +18
-3
lines changed Expand file tree Collapse file tree 2 files changed +18
-3
lines changed Original file line number Diff line number Diff line change
1
+ use slint_build:: CompilerConfiguration ;
2
+
1
3
fn main ( ) {
2
- slint_build:: compile ( "ui/main.slint" ) . expect ( "Slint build failed" ) ;
4
+ let config = CompilerConfiguration :: new ( )
5
+ . with_style ( "cosmic-dark" . into ( ) ) ;
6
+
7
+ slint_build:: compile_with_config ( "ui/main.slint" , config)
8
+ . expect ( "Slint build failed" ) ;
3
9
}
Original file line number Diff line number Diff line change @@ -121,8 +121,17 @@ fn run_game(cfg: &Config) {
121
121
122
122
let mut command = Command :: new ( "love" ) ;
123
123
command. arg ( & path) ;
124
- command. status ( )
125
- . expect ( "Running love2d yielded an error" ) ;
124
+ // command.status()
125
+ // .expect("Running love2d yielded an error");
126
+ let status = command. status ( ) ;
127
+
128
+ if let Err ( e) = status {
129
+ open_error_window_safe (
130
+ Some ( "Failed to run game" . to_string ( ) ) ,
131
+ Some ( "An error was yielded from love2d." . to_string ( ) ) ,
132
+ Some ( e. to_string ( ) )
133
+ ) ;
134
+ }
126
135
127
136
// Restore main.lua
128
137
let mut command = Command :: new ( "git" ) ;
You can’t perform that action at this time.
0 commit comments