mirror of
https://github.com/MidnightCommander/mc
synced 2024-12-23 04:46:55 +03:00
Change type from int to gboolean for variables controlled by checkboxes.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
This commit is contained in:
parent
5e2f4a8069
commit
c4550374b2
@ -87,10 +87,10 @@
|
||||
|
||||
int mou_auto_repeat = 100;
|
||||
int double_click_speed = 250;
|
||||
int old_esc_mode = 0;
|
||||
gboolean old_esc_mode = TRUE;
|
||||
/* timeout for old_esc_mode in usec */
|
||||
int old_esc_mode_timeout = 1000000; /* settable via env */
|
||||
int use_8th_bit_as_meta = 0;
|
||||
gboolean use_8th_bit_as_meta = FALSE;
|
||||
|
||||
gboolean bracketed_pasting_in_progress = FALSE;
|
||||
|
||||
@ -1352,7 +1352,7 @@ init_key (void)
|
||||
* is not used now (doesn't even depend on use_8th_bit_as_meta
|
||||
* as in mc-3.1.2)...GREAT!...no additional code is required!]
|
||||
*/
|
||||
use_8th_bit_as_meta = 0;
|
||||
use_8th_bit_as_meta = FALSE;
|
||||
}
|
||||
#endif /* __QNX__ */
|
||||
|
||||
|
@ -61,8 +61,8 @@ extern const key_code_name_t key_name_conv_tab[];
|
||||
extern int old_esc_mode_timeout;
|
||||
|
||||
extern int double_click_speed;
|
||||
extern int old_esc_mode;
|
||||
extern int use_8th_bit_as_meta;
|
||||
extern gboolean old_esc_mode;
|
||||
extern gboolean use_8th_bit_as_meta;
|
||||
extern int mou_auto_repeat;
|
||||
|
||||
extern gboolean bracketed_pasting_in_progress;
|
||||
|
@ -2901,7 +2901,7 @@ dview_edit (WDiff * dview, diff_place_t ord)
|
||||
vfs_path_t *tmp_vpath;
|
||||
|
||||
tmp_vpath = vfs_path_from_str (dview->file[ord]);
|
||||
edit_file_at_line (tmp_vpath, use_internal_edit != 0, linenum);
|
||||
edit_file_at_line (tmp_vpath, use_internal_edit, linenum);
|
||||
vfs_path_free (tmp_vpath);
|
||||
}
|
||||
|
||||
|
@ -116,8 +116,8 @@ typedef struct edit_stack_type
|
||||
/*** global variables defined in .c file *********************************************************/
|
||||
|
||||
extern const char VERTICAL_MAGIC[5];
|
||||
/* if enable_show_tabs_tws ==1 then use visible_tab visible_tws */
|
||||
extern int enable_show_tabs_tws;
|
||||
/* if enable_show_tabs_tws == TRUE then use visible_tab visible_tws */
|
||||
extern gboolean enable_show_tabs_tws;
|
||||
|
||||
extern edit_search_options_t edit_search_options;
|
||||
|
||||
|
@ -78,23 +78,23 @@
|
||||
int option_word_wrap_line_length = DEFAULT_WRAP_LINE_LENGTH;
|
||||
int option_typewriter_wrap = 0;
|
||||
int option_auto_para_formatting = 0;
|
||||
int option_fill_tabs_with_spaces = 0;
|
||||
int option_return_does_auto_indent = 1;
|
||||
int option_backspace_through_tabs = 0;
|
||||
int option_fake_half_tabs = 1;
|
||||
gboolean option_fill_tabs_with_spaces = FALSE;
|
||||
gboolean option_return_does_auto_indent = TRUE;
|
||||
gboolean option_backspace_through_tabs = FALSE;
|
||||
gboolean option_fake_half_tabs = TRUE;
|
||||
int option_save_mode = EDIT_QUICK_SAVE;
|
||||
int option_save_position = 1;
|
||||
gboolean option_save_position = TRUE;
|
||||
int option_max_undo = 32768;
|
||||
int option_persistent_selections = 1;
|
||||
int option_cursor_beyond_eol = 0;
|
||||
gboolean option_persistent_selections = TRUE;
|
||||
gboolean option_cursor_beyond_eol = FALSE;
|
||||
int option_line_state = 0;
|
||||
int option_line_state_width = 0;
|
||||
gboolean option_cursor_after_inserted_block = FALSE;
|
||||
int option_state_full_filename = 0;
|
||||
|
||||
int enable_show_tabs_tws = 1;
|
||||
int option_check_nl_at_eof = 0;
|
||||
int option_group_undo = 0;
|
||||
gboolean enable_show_tabs_tws = TRUE;
|
||||
gboolean option_check_nl_at_eof = FALSE;
|
||||
gboolean option_group_undo = FALSE;
|
||||
int show_right_margin = 0;
|
||||
|
||||
char *option_backup_ext = NULL;
|
||||
|
@ -33,31 +33,31 @@ typedef struct WEdit WEdit;
|
||||
extern int option_word_wrap_line_length;
|
||||
extern int option_typewriter_wrap;
|
||||
extern int option_auto_para_formatting;
|
||||
extern int option_fill_tabs_with_spaces;
|
||||
extern int option_return_does_auto_indent;
|
||||
extern int option_backspace_through_tabs;
|
||||
extern int option_fake_half_tabs;
|
||||
extern int option_persistent_selections;
|
||||
extern gboolean option_fill_tabs_with_spaces;
|
||||
extern gboolean option_return_does_auto_indent;
|
||||
extern gboolean option_backspace_through_tabs;
|
||||
extern gboolean option_fake_half_tabs;
|
||||
extern gboolean option_persistent_selections;
|
||||
extern int option_drop_selection_on_copy;
|
||||
extern int option_cursor_beyond_eol;
|
||||
extern gboolean option_cursor_beyond_eol;
|
||||
extern gboolean option_cursor_after_inserted_block;
|
||||
extern int option_state_full_filename;
|
||||
extern int option_line_state;
|
||||
extern int option_save_mode;
|
||||
extern int option_save_position;
|
||||
extern int option_syntax_highlighting;
|
||||
extern int option_group_undo;
|
||||
extern gboolean option_save_position;
|
||||
extern gboolean option_syntax_highlighting;
|
||||
extern gboolean option_group_undo;
|
||||
extern char *option_backup_ext;
|
||||
extern char *option_filesize_threshold;
|
||||
extern char *option_stop_format_chars;
|
||||
|
||||
extern int edit_confirm_save;
|
||||
extern gboolean edit_confirm_save;
|
||||
|
||||
extern int visible_tabs;
|
||||
extern int visible_tws;
|
||||
extern gboolean visible_tabs;
|
||||
extern gboolean visible_tws;
|
||||
|
||||
extern int simple_statusbar;
|
||||
extern int option_check_nl_at_eof;
|
||||
extern gboolean option_check_nl_at_eof;
|
||||
extern int show_right_margin;
|
||||
|
||||
/*** declarations of public functions ************************************************************/
|
||||
|
@ -84,7 +84,7 @@
|
||||
int search_create_bookmark = FALSE;
|
||||
|
||||
/* queries on a save */
|
||||
int edit_confirm_save = 1;
|
||||
gboolean edit_confirm_save = TRUE;
|
||||
|
||||
/* whether we need to drop selection on copy to buffer */
|
||||
int option_drop_selection_on_copy = 1;
|
||||
|
@ -63,7 +63,8 @@
|
||||
/* Toggles statusbar draw style */
|
||||
int simple_statusbar = 0;
|
||||
|
||||
int visible_tabs = 1, visible_tws = 1;
|
||||
gboolean visible_tws = TRUE;
|
||||
gboolean visible_tabs = TRUE;
|
||||
|
||||
/*** file scope macro definitions ****************************************************************/
|
||||
|
||||
|
@ -268,7 +268,7 @@ edit_drop_menu_cmd (WDialog * h, int which)
|
||||
WMenuBar *menubar;
|
||||
|
||||
menubar = find_menubar (h);
|
||||
menubar_activate (menubar, drop_menus != 0, which);
|
||||
menubar_activate (menubar, drop_menus, which);
|
||||
}
|
||||
|
||||
/* --------------------------------------------------------------------------------------------- */
|
||||
|
@ -120,7 +120,7 @@ edit_options_dialog (WDialog * h)
|
||||
char wrap_length[16], tab_spacing[16];
|
||||
char *p, *q;
|
||||
int wrap_mode = 0;
|
||||
int old_syntax_hl;
|
||||
gboolean old_syntax_hl;
|
||||
|
||||
#ifdef ENABLE_NLS
|
||||
static gboolean i18n_flag = FALSE;
|
||||
|
@ -917,7 +917,7 @@ edit_dialog_mouse_callback (Widget * w, mouse_msg_t msg, mouse_event_t * event)
|
||||
}
|
||||
|
||||
if (unhandled)
|
||||
menubar_activate (b, drop_menus != 0, -1);
|
||||
menubar_activate (b, drop_menus, -1);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -66,7 +66,7 @@
|
||||
|
||||
/*** global variables ****************************************************************************/
|
||||
|
||||
int option_syntax_highlighting = 1;
|
||||
gboolean option_syntax_highlighting = TRUE;
|
||||
int option_auto_syntax = 1;
|
||||
|
||||
/*** file scope macro definitions ****************************************************************/
|
||||
|
@ -629,7 +629,7 @@ appearance_box (void)
|
||||
void
|
||||
panel_options_box (void)
|
||||
{
|
||||
int simple_swap;
|
||||
gboolean simple_swap;
|
||||
|
||||
simple_swap = mc_config_get_bool (mc_global.main_config, CONFIG_PANELS_SECTION,
|
||||
"simple_swap", FALSE) ? 1 : 0;
|
||||
@ -693,8 +693,7 @@ panel_options_box (void)
|
||||
return;
|
||||
}
|
||||
|
||||
mc_config_set_bool (mc_global.main_config, CONFIG_PANELS_SECTION, "simple_swap",
|
||||
(gboolean) simple_swap);
|
||||
mc_config_set_bool (mc_global.main_config, CONFIG_PANELS_SECTION, "simple_swap", simple_swap);
|
||||
|
||||
if (!panels_options.fast_reload_msg_shown && panels_options.fast_reload)
|
||||
{
|
||||
@ -712,7 +711,7 @@ panel_options_box (void)
|
||||
|
||||
/* return list type */
|
||||
int
|
||||
panel_listing_box (WPanel * panel, int num, char **userp, char **minip, int *use_msformat,
|
||||
panel_listing_box (WPanel * panel, int num, char **userp, char **minip, gboolean * use_msformat,
|
||||
int *brief_cols)
|
||||
{
|
||||
int result = -1;
|
||||
@ -727,7 +726,7 @@ panel_listing_box (WPanel * panel, int num, char **userp, char **minip, int *use
|
||||
panel = g_new (WPanel, 1);
|
||||
panel->list_type = list_full;
|
||||
panel->user_format = g_strdup (DEFAULT_USER_FORMAT);
|
||||
panel->user_mini_status = 0;
|
||||
panel->user_mini_status = FALSE;
|
||||
for (i = 0; i < LIST_TYPES; i++)
|
||||
panel->user_status_format[i] = g_strdup (DEFAULT_USER_FORMAT);
|
||||
section = g_strconcat ("Temporal:", p, (char *) NULL);
|
||||
@ -741,7 +740,7 @@ panel_listing_box (WPanel * panel, int num, char **userp, char **minip, int *use
|
||||
}
|
||||
|
||||
{
|
||||
int mini_user_status;
|
||||
gboolean mini_user_status;
|
||||
char panel_brief_cols_in[BUF_TINY];
|
||||
char *panel_brief_cols_out = NULL;
|
||||
char *panel_user_format = NULL;
|
||||
@ -920,7 +919,7 @@ confirm_box (void)
|
||||
void
|
||||
display_bits_box (void)
|
||||
{
|
||||
int new_meta;
|
||||
gboolean new_meta;
|
||||
int current_mode;
|
||||
|
||||
const char *display_bits_str[] = {
|
||||
@ -982,7 +981,7 @@ display_bits_box (void)
|
||||
: ((codepage_desc *) g_ptr_array_index (codepages, new_display_codepage))->name;
|
||||
|
||||
{
|
||||
int new_meta;
|
||||
gboolean new_meta;
|
||||
|
||||
quick_widget_t quick_widgets[] = {
|
||||
/* *INDENT-OFF* */
|
||||
|
@ -21,7 +21,7 @@
|
||||
void configure_box (void);
|
||||
void appearance_box (void);
|
||||
void panel_options_box (void);
|
||||
int panel_listing_box (WPanel * p, int num, char **user, char **mini, int *use_msformat,
|
||||
int panel_listing_box (WPanel * p, int num, char **user, char **mini, gboolean * use_msformat,
|
||||
int *brief_cols);
|
||||
const panel_field_t *sort_box (dir_sort_options_t * op, const panel_field_t * sort_field);
|
||||
void confirm_box (void);
|
||||
|
@ -312,8 +312,7 @@ init_chmod (const char *fname, const struct stat *sf_stat)
|
||||
|
||||
for (i = 0; i < check_perm_num; i++)
|
||||
{
|
||||
check_perm[i].check = check_new (PY + i + 1, PX + 2,
|
||||
(c_stat & check_perm[i].mode) != 0 ? 1 : 0,
|
||||
check_perm[i].check = check_new (PY + i + 1, PX + 2, (c_stat & check_perm[i].mode) != 0,
|
||||
check_perm[i].text);
|
||||
add_widget (ch_dlg, check_perm[i].check);
|
||||
}
|
||||
|
@ -153,7 +153,7 @@ do_view_cmd (gboolean normal)
|
||||
|
||||
file_idx = current_panel->selected;
|
||||
filename_vpath = vfs_path_from_str (current_panel->dir.list[file_idx].fname);
|
||||
view_file (filename_vpath, normal, use_internal_view != 0);
|
||||
view_file (filename_vpath, normal, use_internal_view);
|
||||
vfs_path_free (filename_vpath);
|
||||
}
|
||||
|
||||
@ -165,7 +165,7 @@ do_view_cmd (gboolean normal)
|
||||
static inline void
|
||||
do_edit (const vfs_path_t * what_vpath)
|
||||
{
|
||||
edit_file_at_line (what_vpath, use_internal_edit != 0, 0);
|
||||
edit_file_at_line (what_vpath, use_internal_edit, 0);
|
||||
}
|
||||
|
||||
/* --------------------------------------------------------------------------------------------- */
|
||||
@ -472,8 +472,8 @@ nice_cd (const char *text, const char *xtext, const char *help,
|
||||
/* --------------------------------------------------------------------------------------------- */
|
||||
|
||||
static void
|
||||
configure_panel_listing (WPanel * p, int list_type, int brief_cols, int use_msformat, char **user,
|
||||
char **status)
|
||||
configure_panel_listing (WPanel * p, int list_type, int brief_cols, gboolean use_msformat,
|
||||
char **user, char **status)
|
||||
{
|
||||
p->user_mini_status = use_msformat;
|
||||
p->list_type = list_type;
|
||||
@ -658,7 +658,7 @@ view_file_cmd (void)
|
||||
|
||||
vpath = vfs_path_from_str (filename);
|
||||
g_free (filename);
|
||||
view_file (vpath, FALSE, use_internal_view != 0);
|
||||
view_file (vpath, FALSE, use_internal_view);
|
||||
vfs_path_free (vpath);
|
||||
}
|
||||
|
||||
@ -1592,7 +1592,8 @@ void
|
||||
change_listing_cmd (void)
|
||||
{
|
||||
int list_type;
|
||||
int use_msformat, brief_cols;
|
||||
gboolean use_msformat;
|
||||
int brief_cols;
|
||||
char *user, *status;
|
||||
WPanel *p = NULL;
|
||||
|
||||
|
@ -168,7 +168,7 @@ statfs (char const *filename, struct fs_info *buf)
|
||||
|
||||
/*** global variables ****************************************************************************/
|
||||
|
||||
int classic_progressbar = 1;
|
||||
gboolean classic_progressbar = TRUE;
|
||||
|
||||
/*** file scope macro definitions ****************************************************************/
|
||||
|
||||
@ -1170,7 +1170,7 @@ file_mask_dialog (file_op_context_t * ctx, FileOperation operation,
|
||||
{
|
||||
size_t fmd_xlen;
|
||||
vfs_path_t *vpath;
|
||||
int source_easy_patterns = easy_patterns;
|
||||
gboolean source_easy_patterns = easy_patterns;
|
||||
char fmd_buf[BUF_MEDIUM];
|
||||
char *dest_dir, *tmp;
|
||||
char *def_text_secure;
|
||||
|
@ -1446,10 +1446,10 @@ find_do_view_edit (gboolean unparsed_view, gboolean edit, char *dir, char *file,
|
||||
|
||||
fullname_vpath = vfs_path_build_filename (dir, filename, (char *) NULL);
|
||||
if (edit)
|
||||
edit_file_at_line (fullname_vpath, use_internal_edit != 0, line);
|
||||
edit_file_at_line (fullname_vpath, use_internal_edit, line);
|
||||
else
|
||||
view_file_at_line (fullname_vpath, unparsed_view, use_internal_view != 0, line,
|
||||
search_start, search_end);
|
||||
view_file_at_line (fullname_vpath, unparsed_view, use_internal_view, line, search_start,
|
||||
search_end);
|
||||
vfs_path_free (fullname_vpath);
|
||||
g_free (fullname);
|
||||
}
|
||||
|
@ -82,7 +82,7 @@ panels_layout_t panels_layout = {
|
||||
};
|
||||
|
||||
/* Controls the display of the rotating dash on the verbose mode */
|
||||
int nice_rotating_dash = 1;
|
||||
gboolean nice_rotating_dash = TRUE;
|
||||
|
||||
/* The number of output lines shown (if available) */
|
||||
int output_lines = 0;
|
||||
|
@ -46,7 +46,7 @@ extern int menubar_visible;
|
||||
extern int output_start_y;
|
||||
extern gboolean xterm_title;
|
||||
extern int free_space;
|
||||
extern int nice_rotating_dash;
|
||||
extern gboolean nice_rotating_dash;
|
||||
|
||||
extern int ok_to_refresh;
|
||||
|
||||
|
@ -368,7 +368,7 @@ init_menu (void)
|
||||
static void
|
||||
menu_last_selected_cmd (void)
|
||||
{
|
||||
menubar_activate (the_menubar, drop_menus != 0, -1);
|
||||
menubar_activate (the_menubar, drop_menus, -1);
|
||||
}
|
||||
|
||||
/* --------------------------------------------------------------------------------------------- */
|
||||
@ -383,7 +383,7 @@ menu_cmd (void)
|
||||
else
|
||||
selected = g_list_length (the_menubar->menu) - 1;
|
||||
|
||||
menubar_activate (the_menubar, drop_menus != 0, selected);
|
||||
menubar_activate (the_menubar, drop_menus, selected);
|
||||
}
|
||||
|
||||
/* --------------------------------------------------------------------------------------------- */
|
||||
@ -880,7 +880,7 @@ setup_mc (void)
|
||||
#endif /* !ENABLE_SUBSHELL */
|
||||
|
||||
if ((tty_baudrate () < 9600) || mc_global.tty.slow_terminal)
|
||||
verbose = 0;
|
||||
verbose = FALSE;
|
||||
}
|
||||
|
||||
/* --------------------------------------------------------------------------------------------- */
|
||||
|
@ -2513,9 +2513,9 @@ static void
|
||||
panel_select_unselect_files (WPanel * panel, const char *title, const char *history_name,
|
||||
gboolean do_select)
|
||||
{
|
||||
int files_only = (panels_options.select_flags & SELECT_FILES_ONLY) != 0;
|
||||
int case_sens = (panels_options.select_flags & SELECT_MATCH_CASE) != 0;
|
||||
int shell_patterns = (panels_options.select_flags & SELECT_SHELL_PATTERNS) != 0;
|
||||
gboolean files_only = (panels_options.select_flags & SELECT_FILES_ONLY) != 0;
|
||||
gboolean case_sens = (panels_options.select_flags & SELECT_MATCH_CASE) != 0;
|
||||
gboolean shell_patterns = (panels_options.select_flags & SELECT_SHELL_PATTERNS) != 0;
|
||||
|
||||
char *reg_exp;
|
||||
mc_search_t *search;
|
||||
@ -2551,15 +2551,15 @@ panel_select_unselect_files (WPanel * panel, const char *title, const char *hist
|
||||
}
|
||||
|
||||
search = mc_search_new (reg_exp, NULL);
|
||||
search->search_type = (shell_patterns != 0) ? MC_SEARCH_T_GLOB : MC_SEARCH_T_REGEX;
|
||||
search->search_type = shell_patterns ? MC_SEARCH_T_GLOB : MC_SEARCH_T_REGEX;
|
||||
search->is_entire_line = TRUE;
|
||||
search->is_case_sensitive = case_sens != 0;
|
||||
search->is_case_sensitive = case_sens;
|
||||
|
||||
for (i = 0; i < panel->dir.len; i++)
|
||||
{
|
||||
if (DIR_IS_DOTDOT (panel->dir.list[i].fname))
|
||||
continue;
|
||||
if (S_ISDIR (panel->dir.list[i].st.st_mode) && files_only != 0)
|
||||
if (S_ISDIR (panel->dir.list[i].st.st_mode) && files_only)
|
||||
continue;
|
||||
|
||||
if (mc_search_run (search, panel->dir.list[i].fname, 0, panel->dir.list[i].fnamelen, NULL))
|
||||
@ -2571,11 +2571,11 @@ panel_select_unselect_files (WPanel * panel, const char *title, const char *hist
|
||||
|
||||
/* result flags */
|
||||
panels_options.select_flags = 0;
|
||||
if (case_sens != 0)
|
||||
if (case_sens)
|
||||
panels_options.select_flags |= SELECT_MATCH_CASE;
|
||||
if (files_only != 0)
|
||||
if (files_only)
|
||||
panels_options.select_flags |= SELECT_FILES_ONLY;
|
||||
if (shell_patterns != 0)
|
||||
if (shell_patterns)
|
||||
panels_options.select_flags |= SELECT_SHELL_PATTERNS;
|
||||
}
|
||||
|
||||
|
@ -117,7 +117,7 @@ typedef struct
|
||||
|
||||
int dirty; /* Should we redisplay the panel? */
|
||||
|
||||
int user_mini_status; /* Is user_status_format used */
|
||||
gboolean user_mini_status; /* Is user_status_format used */
|
||||
char *user_format; /* User format */
|
||||
char *user_status_format[LIST_TYPES]; /* User format for status line */
|
||||
|
||||
|
@ -115,9 +115,9 @@ check_patterns (char *p)
|
||||
|
||||
p += sizeof (def_name) - 1;
|
||||
if (*p == '1')
|
||||
easy_patterns = 1;
|
||||
easy_patterns = TRUE;
|
||||
else if (*p == '0')
|
||||
easy_patterns = 0;
|
||||
easy_patterns = FALSE;
|
||||
else
|
||||
return p0;
|
||||
|
||||
@ -922,7 +922,8 @@ user_menu_cmd (const WEdit * edit_widget, const char *menu_file, int selected_en
|
||||
int max_cols, menu_lines, menu_limit;
|
||||
int col, i;
|
||||
gboolean accept_entry = TRUE;
|
||||
int selected, old_patterns;
|
||||
int selected;
|
||||
gboolean old_patterns;
|
||||
gboolean res = FALSE;
|
||||
gboolean interactive = TRUE;
|
||||
|
||||
|
@ -387,7 +387,7 @@ learn_save (void)
|
||||
void
|
||||
learn_keys (void)
|
||||
{
|
||||
int save_old_esc_mode = old_esc_mode;
|
||||
gboolean save_old_esc_mode = old_esc_mode;
|
||||
gboolean save_alternate_plus_minus = mc_global.tty.alternate_plus_minus;
|
||||
int result;
|
||||
|
||||
|
38
src/setup.c
38
src/setup.c
@ -86,33 +86,33 @@ char *global_profile_name; /* mc.lib */
|
||||
gboolean boot_current_is_left = TRUE;
|
||||
|
||||
/* If on, default for "No" in delete operations */
|
||||
int safe_delete = 0;
|
||||
gboolean safe_delete = FALSE;
|
||||
|
||||
/* Controls screen clearing before an exec */
|
||||
int clear_before_exec = 1;
|
||||
|
||||
/* Asks for confirmation before deleting a file */
|
||||
int confirm_delete = 1;
|
||||
gboolean confirm_delete = TRUE;
|
||||
/* Asks for confirmation before deleting a hotlist entry */
|
||||
int confirm_directory_hotlist_delete = 1;
|
||||
gboolean confirm_directory_hotlist_delete = FALSE;
|
||||
/* Asks for confirmation before overwriting a file */
|
||||
int confirm_overwrite = 1;
|
||||
gboolean confirm_overwrite = TRUE;
|
||||
/* Asks for confirmation before executing a program by pressing enter */
|
||||
int confirm_execute = 0;
|
||||
gboolean confirm_execute = FALSE;
|
||||
/* Asks for confirmation before leaving the program */
|
||||
int confirm_exit = 0;
|
||||
gboolean confirm_exit = FALSE;
|
||||
|
||||
/* If true, at startup the user-menu is invoked */
|
||||
int auto_menu = 0;
|
||||
gboolean auto_menu = FALSE;
|
||||
/* This flag indicates if the pull down menus by default drop down */
|
||||
int drop_menus = 0;
|
||||
gboolean drop_menus = FALSE;
|
||||
|
||||
/* Asks for confirmation when using F3 to view a directory and there
|
||||
are tagged files */
|
||||
int confirm_view_dir = 0;
|
||||
|
||||
/* Ask file name before start the editor */
|
||||
int editor_ask_filename_before_edit = 0;
|
||||
gboolean editor_ask_filename_before_edit = FALSE;
|
||||
|
||||
panel_view_mode_t startup_left_mode;
|
||||
panel_view_mode_t startup_right_mode;
|
||||
@ -148,10 +148,10 @@ panels_options_t panels_options = {
|
||||
.select_flags = SELECT_MATCH_CASE | SELECT_SHELL_PATTERNS
|
||||
};
|
||||
|
||||
int easy_patterns = 1;
|
||||
gboolean easy_patterns = TRUE;
|
||||
|
||||
/* It true saves the setup when quitting */
|
||||
int auto_save_setup = 1;
|
||||
gboolean auto_save_setup = TRUE;
|
||||
|
||||
/* If true, then the +, - and \ keys have their special meaning only if the
|
||||
* command line is emtpy, otherwise they behave like regular letters
|
||||
@ -159,7 +159,7 @@ int auto_save_setup = 1;
|
||||
int only_leading_plus_minus = 1;
|
||||
|
||||
/* Automatically fills name with current selected item name on mkdir */
|
||||
int auto_fill_mkdir_name = 1;
|
||||
gboolean auto_fill_mkdir_name = TRUE;
|
||||
|
||||
/* If set and you don't have subshell support,then C-o will give you a shell */
|
||||
int output_starts_shell = 0;
|
||||
@ -167,19 +167,19 @@ int output_starts_shell = 0;
|
||||
/* If set, we execute the file command to check the file type */
|
||||
int use_file_to_check_type = 1;
|
||||
|
||||
int verbose = 1;
|
||||
gboolean verbose = TRUE;
|
||||
|
||||
/*
|
||||
* Whether the Midnight Commander tries to provide more
|
||||
* information about copy/move sizes and bytes transferred
|
||||
* at the expense of some speed
|
||||
*/
|
||||
int file_op_compute_totals = 1;
|
||||
gboolean file_op_compute_totals = TRUE;
|
||||
|
||||
/* If true use the internal viewer */
|
||||
int use_internal_view = 1;
|
||||
gboolean use_internal_view = TRUE;
|
||||
/* If set, use the builtin editor */
|
||||
int use_internal_edit = 1;
|
||||
gboolean use_internal_edit = TRUE;
|
||||
|
||||
#ifdef HAVE_CHARSET
|
||||
/* Numbers of (file I/O) and (input/display) codepages. -1 if not selected */
|
||||
@ -1037,7 +1037,7 @@ load_setup (void)
|
||||
*int_options[i].opt_addr);
|
||||
#ifndef USE_INTERNAL_EDIT
|
||||
/* reset forced in case of build without internal editor */
|
||||
use_internal_edit = 0;
|
||||
use_internal_edit = FALSE;
|
||||
#endif /* USE_INTERNAL_EDIT */
|
||||
|
||||
if (option_tab_spacing <= 0)
|
||||
@ -1468,7 +1468,7 @@ panel_load_setup (WPanel * panel, const char *section)
|
||||
}
|
||||
|
||||
panel->user_mini_status =
|
||||
mc_config_get_int (mc_global.panels_config, section, "user_mini_status", 0);
|
||||
mc_config_get_bool (mc_global.panels_config, section, "user_mini_status", FALSE);
|
||||
}
|
||||
|
||||
/* --------------------------------------------------------------------------------------------- */
|
||||
@ -1504,7 +1504,7 @@ panel_save_setup (WPanel * panel, const char *section)
|
||||
panel->user_status_format[i]);
|
||||
}
|
||||
|
||||
mc_config_set_int (mc_global.panels_config, section, "user_mini_status",
|
||||
mc_config_set_bool (mc_global.panels_config, section, "user_mini_status",
|
||||
panel->user_mini_status);
|
||||
}
|
||||
|
||||
|
34
src/setup.h
34
src/setup.h
@ -75,37 +75,37 @@ struct mc_fhl_struct;
|
||||
|
||||
/* global paremeters */
|
||||
extern char *global_profile_name;
|
||||
extern int confirm_delete;
|
||||
extern int confirm_directory_hotlist_delete;
|
||||
extern int confirm_execute;
|
||||
extern int confirm_exit;
|
||||
extern int confirm_overwrite;
|
||||
extern gboolean confirm_delete;
|
||||
extern gboolean confirm_directory_hotlist_delete;
|
||||
extern gboolean confirm_execute;
|
||||
extern gboolean confirm_exit;
|
||||
extern gboolean confirm_overwrite;
|
||||
extern int confirm_view_dir;
|
||||
extern int safe_delete;
|
||||
extern gboolean safe_delete;
|
||||
extern int clear_before_exec;
|
||||
extern int auto_menu;
|
||||
extern int drop_menus;
|
||||
extern int verbose;
|
||||
extern gboolean auto_menu;
|
||||
extern gboolean drop_menus;
|
||||
extern gboolean verbose;
|
||||
extern int setup_copymove_persistent_attr;
|
||||
extern int classic_progressbar;
|
||||
extern int easy_patterns;
|
||||
extern gboolean classic_progressbar;
|
||||
extern gboolean easy_patterns;
|
||||
extern int option_tab_spacing;
|
||||
extern int auto_save_setup;
|
||||
extern gboolean auto_save_setup;
|
||||
extern int only_leading_plus_minus;
|
||||
extern int cd_symlinks;
|
||||
extern int auto_fill_mkdir_name;
|
||||
extern gboolean auto_fill_mkdir_name;
|
||||
extern int output_starts_shell;
|
||||
extern int use_file_to_check_type;
|
||||
extern int file_op_compute_totals;
|
||||
extern int editor_ask_filename_before_edit;
|
||||
extern gboolean file_op_compute_totals;
|
||||
extern gboolean editor_ask_filename_before_edit;
|
||||
|
||||
extern panels_options_t panels_options;
|
||||
|
||||
extern panel_view_mode_t startup_left_mode;
|
||||
extern panel_view_mode_t startup_right_mode;
|
||||
extern gboolean boot_current_is_left;
|
||||
extern int use_internal_view;
|
||||
extern int use_internal_edit;
|
||||
extern gboolean use_internal_view;
|
||||
extern gboolean use_internal_edit;
|
||||
|
||||
#ifdef HAVE_CHARSET
|
||||
extern int default_source_codepage;
|
||||
|
@ -118,8 +118,8 @@ What to do with this?
|
||||
int ftpfs_retry_seconds = 30;
|
||||
|
||||
/* Method to use to connect to ftp sites */
|
||||
int ftpfs_use_passive_connections = 1;
|
||||
int ftpfs_use_passive_connections_over_proxy = 0;
|
||||
gboolean ftpfs_use_passive_connections = TRUE;
|
||||
gboolean ftpfs_use_passive_connections_over_proxy = FALSE;
|
||||
|
||||
/* Method used to get directory listings:
|
||||
* 1: try 'LIST -la <path>', if it fails
|
||||
@ -132,7 +132,7 @@ int ftpfs_use_unix_list_options = 1;
|
||||
int ftpfs_first_cd_then_ls = 1;
|
||||
|
||||
/* Use the ~/.netrc */
|
||||
int ftpfs_use_netrc = 1;
|
||||
gboolean ftpfs_use_netrc = TRUE;
|
||||
|
||||
/* Anonymous setup */
|
||||
char *ftpfs_anonymous_passwd = NULL;
|
||||
@ -142,7 +142,7 @@ int ftpfs_directory_timeout = 900;
|
||||
char *ftpfs_proxy_host = NULL;
|
||||
|
||||
/* whether we have to use proxy by default? */
|
||||
int ftpfs_always_use_proxy = 0;
|
||||
gboolean ftpfs_always_use_proxy = FALSE;
|
||||
|
||||
int ftpfs_ignore_chattr_errors = 1;
|
||||
|
||||
@ -206,7 +206,7 @@ typedef struct
|
||||
|
||||
char *proxy; /* proxy server, NULL if no proxy */
|
||||
int failed_on_login; /* used to pass the failure reason to upper levels */
|
||||
int use_passive_connection;
|
||||
gboolean use_passive_connection;
|
||||
int remote_is_amiga; /* No leading slash allowed for AmiTCP (Amiga) */
|
||||
int isbinary;
|
||||
int cwd_deferred; /* current_directory was changed but CWD command hasn't
|
||||
@ -1345,7 +1345,7 @@ ftpfs_initconn (struct vfs_class *me, struct vfs_s_super *super)
|
||||
return data_sock;
|
||||
|
||||
vfs_print_message ("%s", _("ftpfs: could not setup passive mode"));
|
||||
SUP->use_passive_connection = 0;
|
||||
SUP->use_passive_connection = FALSE;
|
||||
|
||||
close (data_sock);
|
||||
}
|
||||
|
@ -20,16 +20,16 @@
|
||||
|
||||
/*** global variables defined in .c file *********************************************************/
|
||||
|
||||
extern int ftpfs_use_netrc;
|
||||
extern gboolean ftpfs_use_netrc;
|
||||
extern char *ftpfs_anonymous_passwd;
|
||||
extern char *ftpfs_proxy_host;
|
||||
extern int ftpfs_directory_timeout;
|
||||
extern int ftpfs_always_use_proxy;
|
||||
extern gboolean ftpfs_always_use_proxy;
|
||||
extern int ftpfs_ignore_chattr_errors;
|
||||
|
||||
extern int ftpfs_retry_seconds;
|
||||
extern int ftpfs_use_passive_connections;
|
||||
extern int ftpfs_use_passive_connections_over_proxy;
|
||||
extern gboolean ftpfs_use_passive_connections;
|
||||
extern gboolean ftpfs_use_passive_connections_over_proxy;
|
||||
extern int ftpfs_use_unix_list_options;
|
||||
extern int ftpfs_first_cd_then_ls;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user