mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-11-10 03:16:17 +01:00
Simplify g_param_spec_get_redirect_target a bit more
It is enough to look for exact matches here, so no need to dive into g_type_instance_is_a and take locks, etc.
This commit is contained in:
parent
f1f80111c9
commit
44af2b1c17
@ -579,7 +579,9 @@ g_param_spec_steal_qdata (GParamSpec *pspec,
|
||||
GParamSpec*
|
||||
g_param_spec_get_redirect_target (GParamSpec *pspec)
|
||||
{
|
||||
if (G_IS_PARAM_SPEC_OVERRIDE (pspec))
|
||||
GTypeInstance *inst = (GTypeInstance *)pspec;
|
||||
|
||||
if (inst && inst->g_class && inst->g_class->g_type == G_TYPE_PARAM_OVERRIDE)
|
||||
return ((GParamSpecOverride*)pspec)->overridden;
|
||||
else
|
||||
return NULL;
|
||||
|
Loading…
Reference in New Issue
Block a user