script: Hide private symbols
A bunch of private functions we use when parsing got exposed accidentaly to the list of public symbols by virtue of not having the leading '_' that we use to filter them out of the shared object — all the while the header that declares them is a private, non installed one. Let's rectify this situation with a bit of minor surgery on the code.
This commit is contained in:
parent
9f70ea8dee
commit
bcd37e2e3d
@ -303,7 +303,7 @@ clutter_alpha_parse_custom_node (ClutterScriptable *scriptable,
|
|||||||
{
|
{
|
||||||
gulong mode;
|
gulong mode;
|
||||||
|
|
||||||
mode = clutter_script_resolve_animation_mode (node);
|
mode = _clutter_script_resolve_animation_mode (node);
|
||||||
|
|
||||||
g_value_init (value, G_TYPE_ULONG);
|
g_value_init (value, G_TYPE_ULONG);
|
||||||
g_value_set_ulong (value, mode);
|
g_value_set_ulong (value, mode);
|
||||||
|
@ -431,7 +431,7 @@ clutter_animation_parse_custom_node (ClutterScriptable *scriptable,
|
|||||||
{
|
{
|
||||||
gulong mode;
|
gulong mode;
|
||||||
|
|
||||||
mode = clutter_script_resolve_animation_mode (node);
|
mode = _clutter_script_resolve_animation_mode (node);
|
||||||
|
|
||||||
g_value_init (value, G_TYPE_ULONG);
|
g_value_init (value, G_TYPE_ULONG);
|
||||||
g_value_set_ulong (value, mode);
|
g_value_set_ulong (value, mode);
|
||||||
|
@ -1513,7 +1513,7 @@ resolve_interpolation (JsonNode *node)
|
|||||||
gboolean res;
|
gboolean res;
|
||||||
gint enum_value;
|
gint enum_value;
|
||||||
|
|
||||||
res = clutter_script_enum_from_string (CLUTTER_TYPE_INTERPOLATION,
|
res = _clutter_script_enum_from_string (CLUTTER_TYPE_INTERPOLATION,
|
||||||
str,
|
str,
|
||||||
&enum_value);
|
&enum_value);
|
||||||
if (res)
|
if (res)
|
||||||
@ -1620,7 +1620,7 @@ parse_animator_property (JsonArray *array,
|
|||||||
gboolean res;
|
gboolean res;
|
||||||
|
|
||||||
progress = json_array_get_double_element (key, 0);
|
progress = json_array_get_double_element (key, 0);
|
||||||
mode = clutter_script_resolve_animation_mode (json_array_get_element (key, 1));
|
mode = _clutter_script_resolve_animation_mode (json_array_get_element (key, 1));
|
||||||
|
|
||||||
animator_key = clutter_animator_key_new (clos->animator,
|
animator_key = clutter_animator_key_new (clos->animator,
|
||||||
gobject,
|
gobject,
|
||||||
@ -1628,7 +1628,7 @@ parse_animator_property (JsonArray *array,
|
|||||||
progress,
|
progress,
|
||||||
mode);
|
mode);
|
||||||
|
|
||||||
res = clutter_script_parse_node (clos->script,
|
res = _clutter_script_parse_node (clos->script,
|
||||||
&(animator_key->value),
|
&(animator_key->value),
|
||||||
pname,
|
pname,
|
||||||
json_array_get_element (key, 2),
|
json_array_get_element (key, 2),
|
||||||
|
@ -680,7 +680,7 @@ clutter_model_set_custom_property (ClutterScriptable *scriptable,
|
|||||||
column_name = clutter_model_get_column_name (model, i);
|
column_name = clutter_model_get_column_name (model, i);
|
||||||
columns[i] = i;
|
columns[i] = i;
|
||||||
g_value_init (&v, column_type);
|
g_value_init (&v, column_type);
|
||||||
clutter_script_parse_node (script, &v, column_name,
|
_clutter_script_parse_node (script, &v, column_name,
|
||||||
json_array_get_element (array, i),
|
json_array_get_element (array, i),
|
||||||
NULL);
|
NULL);
|
||||||
g_value_array_append (values, &v);
|
g_value_array_append (values, &v);
|
||||||
@ -719,7 +719,7 @@ clutter_model_set_custom_property (ClutterScriptable *scriptable,
|
|||||||
columns[column] = i;
|
columns[column] = i;
|
||||||
g_value_init (&v, col_type);
|
g_value_init (&v, col_type);
|
||||||
member = json_object_get_member (object, mname);
|
member = json_object_get_member (object, mname);
|
||||||
clutter_script_parse_node (script, &v,
|
_clutter_script_parse_node (script, &v,
|
||||||
col_name, member,
|
col_name, member,
|
||||||
NULL);
|
NULL);
|
||||||
g_value_array_append (values, &v);
|
g_value_array_append (values, &v);
|
||||||
|
@ -66,7 +66,7 @@ clutter_script_parser_init (ClutterScriptParser *parser)
|
|||||||
}
|
}
|
||||||
|
|
||||||
GType
|
GType
|
||||||
clutter_script_get_type_from_symbol (const gchar *symbol)
|
_clutter_script_get_type_from_symbol (const gchar *symbol)
|
||||||
{
|
{
|
||||||
static GModule *module = NULL;
|
static GModule *module = NULL;
|
||||||
GTypeGetFunc func;
|
GTypeGetFunc func;
|
||||||
@ -82,7 +82,7 @@ clutter_script_get_type_from_symbol (const gchar *symbol)
|
|||||||
}
|
}
|
||||||
|
|
||||||
GType
|
GType
|
||||||
clutter_script_get_type_from_class (const gchar *name)
|
_clutter_script_get_type_from_class (const gchar *name)
|
||||||
{
|
{
|
||||||
static GModule *module = NULL;
|
static GModule *module = NULL;
|
||||||
GString *symbol_name = g_string_sized_new (64);
|
GString *symbol_name = g_string_sized_new (64);
|
||||||
@ -160,7 +160,7 @@ clutter_script_get_type_from_class (const gchar *name)
|
|||||||
* Return value: %TRUE if the conversion was successfull.
|
* Return value: %TRUE if the conversion was successfull.
|
||||||
*/
|
*/
|
||||||
gboolean
|
gboolean
|
||||||
clutter_script_enum_from_string (GType type,
|
_clutter_script_enum_from_string (GType type,
|
||||||
const gchar *string,
|
const gchar *string,
|
||||||
gint *enum_value)
|
gint *enum_value)
|
||||||
{
|
{
|
||||||
@ -195,7 +195,7 @@ clutter_script_enum_from_string (GType type,
|
|||||||
}
|
}
|
||||||
|
|
||||||
gboolean
|
gboolean
|
||||||
clutter_script_flags_from_string (GType type,
|
_clutter_script_flags_from_string (GType type,
|
||||||
const gchar *string,
|
const gchar *string,
|
||||||
gint *flags_value)
|
gint *flags_value)
|
||||||
{
|
{
|
||||||
@ -323,7 +323,7 @@ parse_knot_from_object (JsonObject *object,
|
|||||||
}
|
}
|
||||||
|
|
||||||
gboolean
|
gboolean
|
||||||
clutter_script_parse_knot (ClutterScript *script,
|
_clutter_script_parse_knot (ClutterScript *script,
|
||||||
JsonNode *node,
|
JsonNode *node,
|
||||||
ClutterKnot *knot)
|
ClutterKnot *knot)
|
||||||
{
|
{
|
||||||
@ -389,7 +389,7 @@ parse_geometry_from_object (JsonObject *object,
|
|||||||
}
|
}
|
||||||
|
|
||||||
gboolean
|
gboolean
|
||||||
clutter_script_parse_geometry (ClutterScript *script,
|
_clutter_script_parse_geometry (ClutterScript *script,
|
||||||
JsonNode *node,
|
JsonNode *node,
|
||||||
ClutterGeometry *geometry)
|
ClutterGeometry *geometry)
|
||||||
{
|
{
|
||||||
@ -460,7 +460,7 @@ parse_color_from_object (JsonObject *object,
|
|||||||
}
|
}
|
||||||
|
|
||||||
gboolean
|
gboolean
|
||||||
clutter_script_parse_color (ClutterScript *script,
|
_clutter_script_parse_color (ClutterScript *script,
|
||||||
JsonNode *node,
|
JsonNode *node,
|
||||||
ClutterColor *color)
|
ClutterColor *color)
|
||||||
{
|
{
|
||||||
@ -774,7 +774,7 @@ static const struct
|
|||||||
static const gint n_animation_modes = G_N_ELEMENTS (animation_modes);
|
static const gint n_animation_modes = G_N_ELEMENTS (animation_modes);
|
||||||
|
|
||||||
gulong
|
gulong
|
||||||
clutter_script_resolve_animation_mode (JsonNode *node)
|
_clutter_script_resolve_animation_mode (JsonNode *node)
|
||||||
{
|
{
|
||||||
gint i, res = CLUTTER_CUSTOM_MODE;
|
gint i, res = CLUTTER_CUSTOM_MODE;
|
||||||
|
|
||||||
@ -800,7 +800,7 @@ clutter_script_resolve_animation_mode (JsonNode *node)
|
|||||||
return animation_modes[i].mode;
|
return animation_modes[i].mode;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (clutter_script_enum_from_string (CLUTTER_TYPE_ANIMATION_MODE,
|
if (_clutter_script_enum_from_string (CLUTTER_TYPE_ANIMATION_MODE,
|
||||||
name,
|
name,
|
||||||
&res))
|
&res))
|
||||||
return res;
|
return res;
|
||||||
@ -869,7 +869,7 @@ _clutter_script_parse_alpha (ClutterScript *script,
|
|||||||
|
|
||||||
val = json_object_get_member (object, "mode");
|
val = json_object_get_member (object, "mode");
|
||||||
if (val != NULL)
|
if (val != NULL)
|
||||||
mode = clutter_script_resolve_animation_mode (val);
|
mode = _clutter_script_resolve_animation_mode (val);
|
||||||
|
|
||||||
if (mode == CLUTTER_CUSTOM_MODE)
|
if (mode == CLUTTER_CUSTOM_MODE)
|
||||||
{
|
{
|
||||||
@ -1083,7 +1083,7 @@ clutter_script_parser_parse_end (JsonParser *parser)
|
|||||||
}
|
}
|
||||||
|
|
||||||
gboolean
|
gboolean
|
||||||
clutter_script_parse_node (ClutterScript *script,
|
_clutter_script_parse_node (ClutterScript *script,
|
||||||
GValue *value,
|
GValue *value,
|
||||||
const gchar *name,
|
const gchar *name,
|
||||||
JsonNode *node,
|
JsonNode *node,
|
||||||
@ -1155,7 +1155,7 @@ clutter_script_parse_node (ClutterScript *script,
|
|||||||
|
|
||||||
/* knot := { "x" : (int), "y" : (int) } */
|
/* knot := { "x" : (int), "y" : (int) } */
|
||||||
|
|
||||||
if (clutter_script_parse_knot (script, node, &knot))
|
if (_clutter_script_parse_knot (script, node, &knot))
|
||||||
{
|
{
|
||||||
g_value_set_boxed (value, &knot);
|
g_value_set_boxed (value, &knot);
|
||||||
return TRUE;
|
return TRUE;
|
||||||
@ -1173,7 +1173,7 @@ clutter_script_parse_node (ClutterScript *script,
|
|||||||
* }
|
* }
|
||||||
*/
|
*/
|
||||||
|
|
||||||
if (clutter_script_parse_geometry (script, node, &geom))
|
if (_clutter_script_parse_geometry (script, node, &geom))
|
||||||
{
|
{
|
||||||
g_value_set_boxed (value, &geom);
|
g_value_set_boxed (value, &geom);
|
||||||
return TRUE;
|
return TRUE;
|
||||||
@ -1191,7 +1191,7 @@ clutter_script_parse_node (ClutterScript *script,
|
|||||||
* }
|
* }
|
||||||
*/
|
*/
|
||||||
|
|
||||||
if (clutter_script_parse_color (script, node, &color))
|
if (_clutter_script_parse_color (script, node, &color))
|
||||||
{
|
{
|
||||||
g_value_set_boxed (value, &color);
|
g_value_set_boxed (value, &color);
|
||||||
return TRUE;
|
return TRUE;
|
||||||
@ -1214,7 +1214,7 @@ clutter_script_parse_node (ClutterScript *script,
|
|||||||
|
|
||||||
/* knot := [ (int), (int) ] */
|
/* knot := [ (int), (int) ] */
|
||||||
|
|
||||||
if (clutter_script_parse_knot (script, node, &knot))
|
if (_clutter_script_parse_knot (script, node, &knot))
|
||||||
{
|
{
|
||||||
g_value_set_boxed (value, &knot);
|
g_value_set_boxed (value, &knot);
|
||||||
return TRUE;
|
return TRUE;
|
||||||
@ -1226,7 +1226,7 @@ clutter_script_parse_node (ClutterScript *script,
|
|||||||
|
|
||||||
/* geometry := [ (int), (int), (int), (int) ] */
|
/* geometry := [ (int), (int), (int), (int) ] */
|
||||||
|
|
||||||
if (clutter_script_parse_geometry (script, node, &geom))
|
if (_clutter_script_parse_geometry (script, node, &geom))
|
||||||
{
|
{
|
||||||
g_value_set_boxed (value, &geom);
|
g_value_set_boxed (value, &geom);
|
||||||
return TRUE;
|
return TRUE;
|
||||||
@ -1238,7 +1238,7 @@ clutter_script_parse_node (ClutterScript *script,
|
|||||||
|
|
||||||
/* color := [ (int), (int), (int), (int) ] */
|
/* color := [ (int), (int), (int), (int) ] */
|
||||||
|
|
||||||
if (clutter_script_parse_color (script, node, &color))
|
if (_clutter_script_parse_color (script, node, &color))
|
||||||
{
|
{
|
||||||
g_value_set_boxed (value, &color);
|
g_value_set_boxed (value, &color);
|
||||||
return TRUE;
|
return TRUE;
|
||||||
@ -1337,7 +1337,7 @@ clutter_script_parse_node (ClutterScript *script,
|
|||||||
{
|
{
|
||||||
gint enum_value;
|
gint enum_value;
|
||||||
|
|
||||||
retval = clutter_script_enum_from_string (G_VALUE_TYPE (value),
|
retval = _clutter_script_enum_from_string (G_VALUE_TYPE (value),
|
||||||
g_value_get_string (&node_value),
|
g_value_get_string (&node_value),
|
||||||
&enum_value);
|
&enum_value);
|
||||||
if (retval)
|
if (retval)
|
||||||
@ -1355,7 +1355,7 @@ clutter_script_parse_node (ClutterScript *script,
|
|||||||
{
|
{
|
||||||
gint flags_value;
|
gint flags_value;
|
||||||
|
|
||||||
retval = clutter_script_flags_from_string (G_VALUE_TYPE (value),
|
retval = _clutter_script_flags_from_string (G_VALUE_TYPE (value),
|
||||||
g_value_get_string (&node_value),
|
g_value_get_string (&node_value),
|
||||||
&flags_value);
|
&flags_value);
|
||||||
if (retval)
|
if (retval)
|
||||||
@ -1368,7 +1368,7 @@ clutter_script_parse_node (ClutterScript *script,
|
|||||||
{
|
{
|
||||||
ClutterColor color = { 0, };
|
ClutterColor color = { 0, };
|
||||||
|
|
||||||
retval = clutter_script_parse_color (script, node, &color);
|
retval = _clutter_script_parse_color (script, node, &color);
|
||||||
if (retval)
|
if (retval)
|
||||||
clutter_value_set_color (value, &color);
|
clutter_value_set_color (value, &color);
|
||||||
}
|
}
|
||||||
@ -1464,7 +1464,7 @@ clutter_script_translate_parameters (ClutterScript *script,
|
|||||||
pinfo->node);
|
pinfo->node);
|
||||||
|
|
||||||
if (!res)
|
if (!res)
|
||||||
res = clutter_script_parse_node (script, ¶m.value,
|
res = _clutter_script_parse_node (script, ¶m.value,
|
||||||
pinfo->name,
|
pinfo->name,
|
||||||
pinfo->node,
|
pinfo->node,
|
||||||
pinfo->pspec);
|
pinfo->pspec);
|
||||||
@ -1534,7 +1534,7 @@ clutter_script_construct_parameters (ClutterScript *script,
|
|||||||
|
|
||||||
param.name = g_strdup (pinfo->name);
|
param.name = g_strdup (pinfo->name);
|
||||||
|
|
||||||
if (!clutter_script_parse_node (script, ¶m.value,
|
if (!_clutter_script_parse_node (script, ¶m.value,
|
||||||
pinfo->name,
|
pinfo->name,
|
||||||
pinfo->node,
|
pinfo->node,
|
||||||
pinfo->pspec))
|
pinfo->pspec))
|
||||||
@ -1626,7 +1626,7 @@ apply_layout_properties (ClutterScript *script,
|
|||||||
pinfo->node);
|
pinfo->node);
|
||||||
|
|
||||||
if (!res)
|
if (!res)
|
||||||
res = clutter_script_parse_node (script, &value,
|
res = _clutter_script_parse_node (script, &value,
|
||||||
name,
|
name,
|
||||||
pinfo->node,
|
pinfo->node,
|
||||||
pinfo->pspec);
|
pinfo->pspec);
|
||||||
@ -1726,7 +1726,7 @@ apply_child_properties (ClutterScript *script,
|
|||||||
pinfo->node);
|
pinfo->node);
|
||||||
|
|
||||||
if (!res)
|
if (!res)
|
||||||
res = clutter_script_parse_node (script, &value,
|
res = _clutter_script_parse_node (script, &value,
|
||||||
name,
|
name,
|
||||||
pinfo->node,
|
pinfo->node,
|
||||||
pinfo->pspec);
|
pinfo->pspec);
|
||||||
@ -1952,7 +1952,7 @@ _clutter_script_construct_object (ClutterScript *script,
|
|||||||
if (oinfo->gtype == G_TYPE_INVALID)
|
if (oinfo->gtype == G_TYPE_INVALID)
|
||||||
{
|
{
|
||||||
if (G_UNLIKELY (oinfo->type_func))
|
if (G_UNLIKELY (oinfo->type_func))
|
||||||
oinfo->gtype = clutter_script_get_type_from_symbol (oinfo->type_func);
|
oinfo->gtype = _clutter_script_get_type_from_symbol (oinfo->type_func);
|
||||||
else
|
else
|
||||||
oinfo->gtype = clutter_script_get_type_from_name (script, oinfo->class_name);
|
oinfo->gtype = clutter_script_get_type_from_name (script, oinfo->class_name);
|
||||||
|
|
||||||
|
@ -101,31 +101,31 @@ void property_info_free (gpointer data);
|
|||||||
|
|
||||||
GType clutter_script_parser_get_type (void) G_GNUC_CONST;
|
GType clutter_script_parser_get_type (void) G_GNUC_CONST;
|
||||||
|
|
||||||
gboolean clutter_script_parse_node (ClutterScript *script,
|
gboolean _clutter_script_parse_node (ClutterScript *script,
|
||||||
GValue *value,
|
GValue *value,
|
||||||
const gchar *name,
|
const gchar *name,
|
||||||
JsonNode *node,
|
JsonNode *node,
|
||||||
GParamSpec *pspec);
|
GParamSpec *pspec);
|
||||||
|
|
||||||
GType clutter_script_get_type_from_symbol (const gchar *symbol);
|
GType _clutter_script_get_type_from_symbol (const gchar *symbol);
|
||||||
GType clutter_script_get_type_from_class (const gchar *name);
|
GType _clutter_script_get_type_from_class (const gchar *name);
|
||||||
|
|
||||||
gulong clutter_script_resolve_animation_mode (JsonNode *node);
|
gulong _clutter_script_resolve_animation_mode (JsonNode *node);
|
||||||
|
|
||||||
gboolean clutter_script_enum_from_string (GType gtype,
|
gboolean _clutter_script_enum_from_string (GType gtype,
|
||||||
const gchar *string,
|
const gchar *string,
|
||||||
gint *enum_value);
|
gint *enum_value);
|
||||||
gboolean clutter_script_flags_from_string (GType gtype,
|
gboolean _clutter_script_flags_from_string (GType gtype,
|
||||||
const gchar *string,
|
const gchar *string,
|
||||||
gint *flags_value);
|
gint *flags_value);
|
||||||
|
|
||||||
gboolean clutter_script_parse_knot (ClutterScript *script,
|
gboolean _clutter_script_parse_knot (ClutterScript *script,
|
||||||
JsonNode *node,
|
JsonNode *node,
|
||||||
ClutterKnot *knot);
|
ClutterKnot *knot);
|
||||||
gboolean clutter_script_parse_geometry (ClutterScript *script,
|
gboolean _clutter_script_parse_geometry (ClutterScript *script,
|
||||||
JsonNode *node,
|
JsonNode *node,
|
||||||
ClutterGeometry *geometry);
|
ClutterGeometry *geometry);
|
||||||
gboolean clutter_script_parse_color (ClutterScript *script,
|
gboolean _clutter_script_parse_color (ClutterScript *script,
|
||||||
JsonNode *node,
|
JsonNode *node,
|
||||||
ClutterColor *color);
|
ClutterColor *color);
|
||||||
GObject *_clutter_script_parse_alpha (ClutterScript *script,
|
GObject *_clutter_script_parse_alpha (ClutterScript *script,
|
||||||
|
@ -294,7 +294,7 @@ clutter_script_real_get_type_from_name (ClutterScript *script,
|
|||||||
if (gtype != G_TYPE_INVALID)
|
if (gtype != G_TYPE_INVALID)
|
||||||
return gtype;
|
return gtype;
|
||||||
|
|
||||||
return clutter_script_get_type_from_class (type_name);
|
return _clutter_script_get_type_from_class (type_name);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
@ -2136,13 +2136,13 @@ parse_state_transition (JsonArray *array,
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
mode = clutter_script_resolve_animation_mode (json_array_get_element (key, 2));
|
mode = _clutter_script_resolve_animation_mode (json_array_get_element (key, 2));
|
||||||
|
|
||||||
state_key = clutter_state_key_new (target_state,
|
state_key = clutter_state_key_new (target_state,
|
||||||
gobject, property, pspec,
|
gobject, property, pspec,
|
||||||
mode);
|
mode);
|
||||||
|
|
||||||
res = clutter_script_parse_node (clos->script,
|
res = _clutter_script_parse_node (clos->script,
|
||||||
&(state_key->value),
|
&(state_key->value),
|
||||||
property,
|
property,
|
||||||
json_array_get_element (key, 3),
|
json_array_get_element (key, 3),
|
||||||
|
Loading…
Reference in New Issue
Block a user