mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-07-02 03:52:49 -05:00
Add an "open" command to the "file" (now "session") menu on the Mac to
open an existing saved session. This has entailed adding an extra hook to settings.c to allow for loading settings other than by name. [originally from svn r2387]
This commit is contained in:
12
settings.c
12
settings.c
@ -321,11 +321,17 @@ void save_settings(char *section, int do_host, Config * cfg)
|
||||
|
||||
void load_settings(char *section, int do_host, Config * cfg)
|
||||
{
|
||||
int i;
|
||||
char prot[10];
|
||||
void *sesskey;
|
||||
|
||||
sesskey = open_settings_r(section);
|
||||
load_open_settings(sesskey, do_host, cfg);
|
||||
close_settings_r(sesskey);
|
||||
}
|
||||
|
||||
void load_open_settings(void *sesskey, int do_host, Config *cfg)
|
||||
{
|
||||
int i;
|
||||
char prot[10];
|
||||
|
||||
cfg->ssh_subsys = 0; /* FIXME: load this properly */
|
||||
cfg->remote_cmd_ptr = cfg->remote_cmd;
|
||||
@ -637,8 +643,6 @@ void load_settings(char *section, int do_host, Config * cfg)
|
||||
gppi(sesskey, "ScrollbarOnLeft", 0, &cfg->scrollbar_on_left);
|
||||
gpps(sesskey, "BoldFont", "", cfg->boldfont, sizeof(cfg->boldfont));
|
||||
gppi(sesskey, "ShadowBoldOffset", 1, &cfg->shadowboldoffset);
|
||||
|
||||
close_settings_r(sesskey);
|
||||
}
|
||||
|
||||
void do_defaults(char *session, Config * cfg)
|
||||
|
Reference in New Issue
Block a user