cogl: Remove cogl_get_option_group

It's unused.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2355>
This commit is contained in:
Georges Basile Stavracas Neto 2022-03-30 15:46:05 -03:00
parent f772b4cde6
commit 20bfd10f0c
2 changed files with 0 additions and 80 deletions

View File

@ -211,40 +211,6 @@ _cogl_parse_debug_string (const char *value,
}
}
#ifdef COGL_ENABLE_DEBUG
static gboolean
cogl_arg_debug_cb (const char *key,
const char *value,
void *user_data)
{
_cogl_parse_debug_string (value,
TRUE /* enable the flags */,
FALSE /* don't ignore help */);
return TRUE;
}
static gboolean
cogl_arg_no_debug_cb (const char *key,
const char *value,
void *user_data)
{
_cogl_parse_debug_string (value,
FALSE, /* disable the flags */
TRUE /* ignore help */);
return TRUE;
}
#endif /* COGL_ENABLE_DEBUG */
static GOptionEntry cogl_args[] = {
#ifdef COGL_ENABLE_DEBUG
{ "cogl-debug", 0, 0, G_OPTION_ARG_CALLBACK, cogl_arg_debug_cb,
N_("Cogl debugging flags to set"), "FLAGS" },
{ "cogl-no-debug", 0, 0, G_OPTION_ARG_CALLBACK, cogl_arg_no_debug_cb,
N_("Cogl debugging flags to unset"), "FLAGS" },
#endif /* COGL_ENABLE_DEBUG */
{ NULL, },
};
void
_cogl_debug_check_environment (void)
{
@ -268,33 +234,3 @@ _cogl_debug_check_environment (void)
env_string = NULL;
}
}
static gboolean
pre_parse_hook (GOptionContext *context,
GOptionGroup *group,
void *data,
GError **error)
{
_cogl_init ();
return TRUE;
}
/* XXX: GOption based library initialization is not reliable because the
* GOption API has no way to represent dependencies between libraries.
*/
GOptionGroup *
cogl_get_option_group (void)
{
GOptionGroup *group;
group = g_option_group_new ("cogl",
_("Cogl Options"),
_("Show Cogl options"),
NULL, NULL);
g_option_group_set_parse_hooks (group, pre_parse_hook, NULL);
g_option_group_add_entries (group, cogl_args);
return group;
}

View File

@ -44,22 +44,6 @@
G_BEGIN_DECLS
/**
* cogl_get_option_group:
*
* Retrieves the #GOptionGroup used by Cogl to parse the command
* line options. Clutter uses this to handle the Cogl command line
* options during its initialization process.
*
* Return value: a #GOptionGroup
*
* Since: 1.0
* Deprecated: 1.16: Not replaced
*/
COGL_DEPRECATED
COGL_EXPORT GOptionGroup *
cogl_get_option_group (void);
/* Misc */
/**
* cogl_get_proc_address: (skip)