mirror of
https://github.com/MidnightCommander/mc
synced 2025-03-30 11:42:54 +03:00
* setup.c (save_setup) [HAVE_X]: Don't save the [Dirs] section.
(load_setup) [HAVE_X]: Don't load the [Dirs] section. * main.c [HAVE_X]: Disable other_dir and boot_current_is_left. Adjust all users.
This commit is contained in:
parent
8040aeec39
commit
6ccb2a0131
@ -1,3 +1,10 @@
|
||||
2001-06-20 Pavel Roskin <proski@gnu.org>
|
||||
|
||||
* setup.c (save_setup) [HAVE_X]: Don't save the [Dirs] section.
|
||||
(load_setup) [HAVE_X]: Don't load the [Dirs] section.
|
||||
* main.c [HAVE_X]: Disable other_dir and boot_current_is_left.
|
||||
Adjust all users.
|
||||
|
||||
2001-06-19 Pavel Roskin <proski@gnu.org>
|
||||
|
||||
* background.h: Correct condition when WITH_BACKGROUND is
|
||||
|
11
src/main.c
11
src/main.c
@ -306,8 +306,14 @@ char *program_name;
|
||||
/* The home directory */
|
||||
char *home_dir;
|
||||
|
||||
#ifndef HAVE_X
|
||||
/* The value of the other directory, only used when loading the setup */
|
||||
char *other_dir = 0;
|
||||
|
||||
/* Only used at program boot */
|
||||
int boot_current_is_left = 1;
|
||||
#endif /* !HAVE_X */
|
||||
|
||||
char *this_dir = 0;
|
||||
|
||||
/* If this is true, then when browsing the tree the other window will
|
||||
@ -349,9 +355,6 @@ int midnight_shutdown = 0;
|
||||
/* to show nice prompts */
|
||||
static int last_paused = 0;
|
||||
|
||||
/* Only used at program boot */
|
||||
int boot_current_is_left = 1;
|
||||
|
||||
/* Used for keeping track of the original stdout */
|
||||
int stdout_fd = 0;
|
||||
|
||||
@ -2913,8 +2916,10 @@ handle_args (int argc, char *argv [])
|
||||
char buffer[MC_MAXPATHLEN + 2];
|
||||
this_dir = g_strdup (tmp);
|
||||
mc_get_current_wd (buffer, sizeof (buffer) - 2);
|
||||
#ifndef HAVE_X
|
||||
if ((tmp = poptGetArg (ctx)))
|
||||
other_dir = g_strdup (tmp);
|
||||
#endif /* !HAVE_X */
|
||||
}
|
||||
}
|
||||
|
||||
|
14
src/setup.c
14
src/setup.c
@ -416,19 +416,19 @@ save_setup (void)
|
||||
saving_setup = 1;
|
||||
profile = concat_dir_and_file (home_dir, PROFILE_NAME);
|
||||
|
||||
save_configure ();
|
||||
|
||||
#ifndef HAVE_X
|
||||
save_layout ();
|
||||
#endif /* !HAVE_X */
|
||||
save_configure ();
|
||||
save_string ("Dirs", "other_dir",
|
||||
get_other_type () == view_listing
|
||||
? opanel->cwd : ".", profile);
|
||||
if (get_current_panel () != NULL)
|
||||
WritePrivateProfileString ("Dirs", "current_is_left",
|
||||
get_current_index () == 0 ? "1" : "0", profile);
|
||||
#ifndef HAVE_X
|
||||
save_hotlist ();
|
||||
#endif /* !HAVE_X */
|
||||
|
||||
save_panelize ();
|
||||
save_panel_types ();
|
||||
/* directory_history_save (); */
|
||||
@ -602,6 +602,7 @@ load_setup (void)
|
||||
if (startup_left_mode != view_listing && startup_right_mode!=view_listing)
|
||||
startup_left_mode = view_listing;
|
||||
|
||||
#ifndef HAVE_X
|
||||
if (!other_dir){
|
||||
char *buffer;
|
||||
|
||||
@ -613,11 +614,14 @@ load_setup (void)
|
||||
else
|
||||
g_free (buffer);
|
||||
}
|
||||
|
||||
boot_current_is_left =
|
||||
GetPrivateProfileInt ("Dirs", "current_is_left", 1, profile);
|
||||
#endif /* !HAVE_X */
|
||||
|
||||
#ifdef USE_NETCODE
|
||||
ftpfs_proxy_host = do_load_string ("Misc", "ftp_proxy_host", "gate");
|
||||
#endif
|
||||
boot_current_is_left =
|
||||
GetPrivateProfileInt ("Dirs", "current_is_left", 1, profile);
|
||||
|
||||
load_string ("Misc", "find_ignore_dirs", "", setup_color_string,
|
||||
sizeof (setup_color_string));
|
||||
|
Loading…
x
Reference in New Issue
Block a user