Change Windows startup
remove the safeproc pseudo-windowport routines from
almost a decade ago.
A very early pass is made through the config file,
seeking out just the interface-related OPTIONS=windowport
and OPTIONS=soundlib and ignoring all other options in the
config file during that early pass, so the windowport
can be activated without the NetHack core initialization
in place that some of the other rcfile OPTIONS require.
Bundles the existing rcfile processing code into rcfile().
New functions to control which rcfile options will be
disregarded in the early config file pass, and which will be
processed:
set_all_options_disregarded();
set_all_options_heeded();
disregard_this_option(opt_xx);
heed_this_option(opt_xx);
Windows calls rcfile_interface_options(), which is
a bundling of a series of function calls to achieve
the desired result.
void
rcfile_interface_options(void)
{
allopt_array_init();
set_all_options_disregarded();
heed_this_option(opt_windowtype);
heed_this_option(opt_soundlib);
rcfile();
set_all_options_heeded();
disregard_this_option(opt_windowtype);
disregard_this_option(opt_soundlib);
}
This commit is contained in:
@@ -725,7 +725,8 @@ struct instance_globals_o {
|
||||
|
||||
/* options.c */
|
||||
|
||||
int opt_phase; /* builtin_opt, syscf_, rc_file_, environ_, play_opt */
|
||||
/* builtin_opt, syscf_, rc_file_, environ_, play_opt */
|
||||
enum option_phases opt_phase;
|
||||
boolean opt_initial;
|
||||
boolean opt_from_file;
|
||||
boolean opt_need_redraw; /* for doset() */
|
||||
|
||||
Reference in New Issue
Block a user