Commit c1c42f19 authored by Martin Nordholts's avatar Martin Nordholts

app: Remove 'use_cpu_accel' from gimp_init_for_{,gui_}testing()

Remove silly 'use_cpu_accel' parameter from gimp_init_for_testing()
and gimp_init_for_gui_testing().
parent 9805ed7d
......@@ -49,7 +49,7 @@
* selected subset of the initialization happning in app_run().
**/
Gimp *
gimp_init_for_testing (gboolean use_cpu_accel)
gimp_init_for_testing (void)
{
Gimp *gimp = gimp_new ("Unit Tested GIMP", NULL, FALSE, TRUE, TRUE, TRUE,
FALSE, TRUE, TRUE, FALSE);
......@@ -58,7 +58,9 @@ gimp_init_for_testing (gboolean use_cpu_accel)
gimp_load_config (gimp, NULL, NULL);
base_init (GIMP_BASE_CONFIG (gimp->config), FALSE, use_cpu_accel);
base_init (GIMP_BASE_CONFIG (gimp->config),
FALSE /*be_verbose*/,
FALSE /*use_cpu_accel*/);
return gimp;
}
......@@ -83,7 +85,7 @@ gimp_status_func_dummy (const gchar *text1,
* Returns: The #Gimp instance.
**/
Gimp *
gimp_init_for_gui_testing (gboolean use_cpu_accel, gboolean show_gui)
gimp_init_for_gui_testing (gboolean show_gui)
{
GimpSessionInfoClass *klass;
Gimp *gimp;
......@@ -102,7 +104,9 @@ gimp_init_for_gui_testing (gboolean use_cpu_accel, gboolean show_gui)
gimp_set_show_gui (gimp, show_gui);
units_init (gimp);
gimp_load_config (gimp, NULL, NULL);
base_init (GIMP_BASE_CONFIG (gimp->config), FALSE, use_cpu_accel);
base_init (GIMP_BASE_CONFIG (gimp->config),
FALSE /*be_verbose*/,
FALSE /*use_cpu_accel*/);
gui_init (gimp, TRUE);
gimp_initialize (gimp, gimp_status_func_dummy);
gimp_restore (gimp, gimp_status_func_dummy);
......
......@@ -19,9 +19,8 @@
#define __TESTS_H__
Gimp * gimp_init_for_testing (gboolean use_cpu_accel);
Gimp * gimp_init_for_gui_testing (gboolean use_cpu_accel,
gboolean show_gui);
Gimp * gimp_init_for_testing (void);
Gimp * gimp_init_for_gui_testing (gboolean show_gui);
void gimp_test_run_temp_mainloop (guint32 running_time);
void gimp_test_run_mainloop_until_idle (void);
void gimp_test_bail_if_no_display (void);
......
......@@ -186,7 +186,7 @@ main (int argc,
"app/tests/gimpdir");
/* We share the same application instance across all tests */
gimp = gimp_init_for_testing (TRUE);
gimp = gimp_init_for_testing ();
/* Add tests */
ADD_IMAGE_TEST (add_layer);
......
......@@ -93,7 +93,7 @@ int main(int argc, char **argv)
result = -1;
/* Start up GIMP */
gimp = gimp_init_for_gui_testing (FALSE, TRUE);
gimp = gimp_init_for_gui_testing (TRUE /*show_gui*/);
/* Let the main loop run until idle to let things stabilize. This
* includes parsing sessionrc and dockrc
......
......@@ -846,7 +846,7 @@ int main(int argc, char **argv)
gimp_test_utils_setup_menus_dir ();
/* Start up GIMP */
gimp = gimp_init_for_gui_testing (FALSE, TRUE);
gimp = gimp_init_for_gui_testing (TRUE /*show_gui*/);
gimp_test_run_mainloop_until_idle ();
/* Add tests. Note that the order matters. For example,
......
......@@ -977,7 +977,7 @@ main (int argc,
/* We share the same application instance across all tests. We need
* the GUI variant for the file procs
*/
gimp = gimp_init_for_gui_testing (TRUE, FALSE);
gimp = gimp_init_for_gui_testing (FALSE /*show_gui*/);
/* Add tests */
ADD_TEST (write_and_read_gimp_2_6_format);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment