mirror of
https://github.com/MidnightCommander/mc
synced 2025-01-03 18:14:25 +03:00
option_auto_syntax: change type to gboolean.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
This commit is contained in:
parent
cd3a5ee373
commit
d078ae4713
@ -113,7 +113,7 @@ edit_syntax_dialog (WEdit * edit)
|
|||||||
{
|
{
|
||||||
gboolean force_reload = FALSE;
|
gboolean force_reload = FALSE;
|
||||||
char *current_syntax;
|
char *current_syntax;
|
||||||
int old_auto_syntax;
|
gboolean old_auto_syntax;
|
||||||
|
|
||||||
current_syntax = g_strdup (edit->syntax_type);
|
current_syntax = g_strdup (edit->syntax_type);
|
||||||
old_auto_syntax = option_auto_syntax;
|
old_auto_syntax = option_auto_syntax;
|
||||||
@ -121,13 +121,13 @@ edit_syntax_dialog (WEdit * edit)
|
|||||||
switch (syntax)
|
switch (syntax)
|
||||||
{
|
{
|
||||||
case 0: /* auto syntax */
|
case 0: /* auto syntax */
|
||||||
option_auto_syntax = 1;
|
option_auto_syntax = TRUE;
|
||||||
break;
|
break;
|
||||||
case 1: /* reload current syntax */
|
case 1: /* reload current syntax */
|
||||||
force_reload = TRUE;
|
force_reload = TRUE;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
option_auto_syntax = 0;
|
option_auto_syntax = FALSE;
|
||||||
g_free (edit->syntax_type);
|
g_free (edit->syntax_type);
|
||||||
edit->syntax_type = g_strdup (g_ptr_array_index (names, syntax - N_DFLT_ENTRIES));
|
edit->syntax_type = g_strdup (g_ptr_array_index (names, syntax - N_DFLT_ENTRIES));
|
||||||
}
|
}
|
||||||
|
@ -127,7 +127,7 @@ extern edit_stack_type edit_history_moveto[MAX_HISTORY_MOVETO];
|
|||||||
extern int option_line_state_width;
|
extern int option_line_state_width;
|
||||||
|
|
||||||
extern int option_max_undo;
|
extern int option_max_undo;
|
||||||
extern int option_auto_syntax;
|
extern gboolean option_auto_syntax;
|
||||||
|
|
||||||
extern gboolean search_create_bookmark;
|
extern gboolean search_create_bookmark;
|
||||||
|
|
||||||
|
@ -2082,7 +2082,7 @@ edit_init (WEdit * edit, int y, int x, int lines, int cols, const vfs_path_t * f
|
|||||||
{
|
{
|
||||||
gboolean to_free = FALSE;
|
gboolean to_free = FALSE;
|
||||||
|
|
||||||
option_auto_syntax = 1; /* Resetting to auto on every invokation */
|
option_auto_syntax = TRUE; /* Resetting to auto on every invokation */
|
||||||
option_line_state_width = option_line_state ? LINE_STATE_WIDTH : 0;
|
option_line_state_width = option_line_state ? LINE_STATE_WIDTH : 0;
|
||||||
|
|
||||||
if (edit != NULL)
|
if (edit != NULL)
|
||||||
|
@ -67,7 +67,7 @@
|
|||||||
/*** global variables ****************************************************************************/
|
/*** global variables ****************************************************************************/
|
||||||
|
|
||||||
gboolean option_syntax_highlighting = TRUE;
|
gboolean option_syntax_highlighting = TRUE;
|
||||||
int option_auto_syntax = 1;
|
gboolean option_auto_syntax = TRUE;
|
||||||
|
|
||||||
/*** file scope macro definitions ****************************************************************/
|
/*** file scope macro definitions ****************************************************************/
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user