-theme option added

This commit is contained in:
p.kosyh 2009-09-07 06:14:26 +00:00
parent d67e30622b
commit 129d48300a
2 changed files with 13 additions and 2 deletions

1
debian/changelog vendored
View file

@ -1,5 +1,6 @@
instead (0.8.9) unstable; urgency=low
* -gamespath -game -themespath -theme options
* runtime languages
* desabled function in stead
* list_zap, list_concat

View file

@ -7,6 +7,7 @@ extern void debug_done(void);
int debug_sw = 0;
char *game_sw = NULL;
char *games_sw = NULL;
char *theme_sw = NULL;
char *themes_sw = NULL;
int main(int argc, char **argv)
@ -28,6 +29,11 @@ int main(int argc, char **argv)
game_sw = argv[++i];
else
game_sw = "";
} else if (!strcmp(argv[i], "-theme")) {
if ((i + 1) < argc)
theme_sw = argv[++i];
else
theme_sw = "";
} else if (!strcmp(argv[i], "-gamespath")) {
if ((i + 1) < argc)
games_sw = argv[++i];
@ -73,10 +79,14 @@ int main(int argc, char **argv)
cfg_load();
if (game_sw) {
if (opt_game)
free(opt_game);
FREE(opt_game);
opt_game = game_sw;
}
if (theme_sw) {
FREE(opt_theme);
opt_theme = theme_sw;
}
if (opt_theme)
game_theme_select(opt_theme);