Cleanup: use function instead of extern variable
Quiet undeclared variable warning.
This commit is contained in:
@@ -85,6 +85,7 @@ void WM_init_state_size_set (int stax, int stay, int sizx, int sizy);
|
|||||||
void WM_init_state_fullscreen_set(void);
|
void WM_init_state_fullscreen_set(void);
|
||||||
void WM_init_state_normal_set(void);
|
void WM_init_state_normal_set(void);
|
||||||
void WM_init_state_maximized_set(void);
|
void WM_init_state_maximized_set(void);
|
||||||
|
void WM_init_state_start_with_console_set(bool value);
|
||||||
void WM_init_window_focus_set(bool do_it);
|
void WM_init_window_focus_set(bool do_it);
|
||||||
void WM_init_native_pixels(bool do_it);
|
void WM_init_native_pixels(bool do_it);
|
||||||
void WM_init_tablet_api(void);
|
void WM_init_tablet_api(void);
|
||||||
|
@@ -152,7 +152,12 @@ static void wm_free_reports(bContext *C)
|
|||||||
BKE_reports_clear(reports);
|
BKE_reports_clear(reports);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool wm_start_with_console = false; /* used in creator.c */
|
static bool wm_start_with_console = false;
|
||||||
|
|
||||||
|
void WM_init_state_start_with_console_set(bool value)
|
||||||
|
{
|
||||||
|
wm_start_with_console = value;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Since we cannot know in advance if we will require the draw manager
|
* Since we cannot know in advance if we will require the draw manager
|
||||||
|
@@ -1177,14 +1177,12 @@ static int arg_handle_no_window_focus(int UNUSED(argc), const char **UNUSED(argv
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
extern bool wm_start_with_console; /* wm_init_exit.c */
|
|
||||||
|
|
||||||
static const char arg_handle_start_with_console_doc[] =
|
static const char arg_handle_start_with_console_doc[] =
|
||||||
"\n\tStart with the console window open (ignored if -b is set), (Windows only)."
|
"\n\tStart with the console window open (ignored if -b is set), (Windows only)."
|
||||||
;
|
;
|
||||||
static int arg_handle_start_with_console(int UNUSED(argc), const char **UNUSED(argv), void *UNUSED(data))
|
static int arg_handle_start_with_console(int UNUSED(argc), const char **UNUSED(argv), void *UNUSED(data))
|
||||||
{
|
{
|
||||||
wm_start_with_console = true;
|
WM_init_state_start_with_console_set(true);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user