mirror of
https://github.com/brl/mutter.git
synced 2025-02-16 21:34:09 +00:00
Eliminate G_CONST_RETURN
The G_CONST_RETURN define in GLib is, and has always been, a bit fuzzy. We always used it to conform to the platform, at least for public-facing API. At first I assumed it has something to do with brain-damaged compilers or with weird platforms where const was not really supported; sadly, it's something much, much worse: it's a define that can be toggled at compile-time to remove const from the signature of public API. This is a truly terrifying feature that I assume was added in the past century, and whose inception clearly had something to do with massive doses of absynthe and opium — because any other explanation would make the existence of such a feature even worse than assuming drugs had anything to do with it. Anyway, and pleasing the gods, this dubious feature is being removed/deprecated in GLib; see bug: https://bugzilla.gnome.org/show_bug.cgi?id=644611 Before deprecation, though, we should just remove its usage from the whole API. We should especially remove its usage from Cally's internals, since there it never made sense in the first place.
This commit is contained in:
parent
343f54e659
commit
2b81d90dd7
@ -147,7 +147,7 @@ static void cally_actor_finalize (GObject *obj);
|
||||
static AtkObject* cally_actor_get_parent (AtkObject *obj);
|
||||
static gint cally_actor_get_index_in_parent (AtkObject *obj);
|
||||
static AtkStateSet* cally_actor_ref_state_set (AtkObject *obj);
|
||||
static G_CONST_RETURN gchar* cally_actor_get_name (AtkObject *obj);
|
||||
static const gchar* cally_actor_get_name (AtkObject *obj);
|
||||
static gint cally_actor_get_n_children (AtkObject *obj);
|
||||
static AtkObject* cally_actor_ref_child (AtkObject *obj,
|
||||
gint i);
|
||||
@ -194,11 +194,11 @@ static gboolean cally_actor_action_do_action (AtkAction *acti
|
||||
gint i);
|
||||
static gboolean idle_do_action (gpointer data);
|
||||
static gint cally_actor_action_get_n_actions (AtkAction *action);
|
||||
static G_CONST_RETURN gchar* cally_actor_action_get_description (AtkAction *action,
|
||||
static const gchar* cally_actor_action_get_description (AtkAction *action,
|
||||
gint i);
|
||||
static G_CONST_RETURN gchar* cally_actor_action_get_keybinding (AtkAction *action,
|
||||
static const gchar* cally_actor_action_get_keybinding (AtkAction *action,
|
||||
gint i);
|
||||
static G_CONST_RETURN gchar* cally_actor_action_get_name (AtkAction *action,
|
||||
static const gchar* cally_actor_action_get_name (AtkAction *action,
|
||||
gint i);
|
||||
static gboolean cally_actor_action_set_description (AtkAction *action,
|
||||
gint i,
|
||||
@ -406,10 +406,10 @@ cally_actor_finalize (GObject *obj)
|
||||
|
||||
/* AtkObject */
|
||||
|
||||
static G_CONST_RETURN gchar*
|
||||
static const gchar*
|
||||
cally_actor_get_name (AtkObject *obj)
|
||||
{
|
||||
G_CONST_RETURN gchar* name = NULL;
|
||||
const gchar* name = NULL;
|
||||
|
||||
g_return_val_if_fail (CALLY_IS_ACTOR (obj), NULL);
|
||||
|
||||
@ -1043,7 +1043,7 @@ cally_actor_action_get_n_actions (AtkAction *action)
|
||||
return g_list_length (priv->action_list);
|
||||
}
|
||||
|
||||
static G_CONST_RETURN gchar*
|
||||
static const gchar*
|
||||
cally_actor_action_get_name (AtkAction *action,
|
||||
gint i)
|
||||
{
|
||||
@ -1060,7 +1060,7 @@ cally_actor_action_get_name (AtkAction *action,
|
||||
return info->name;
|
||||
}
|
||||
|
||||
static G_CONST_RETURN gchar*
|
||||
static const gchar*
|
||||
cally_actor_action_get_description (AtkAction *action,
|
||||
gint i)
|
||||
{
|
||||
@ -1098,7 +1098,7 @@ cally_actor_action_set_description (AtkAction *action,
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
static G_CONST_RETURN gchar*
|
||||
static const gchar*
|
||||
cally_actor_action_get_keybinding (AtkAction *action,
|
||||
gint i)
|
||||
{
|
||||
|
@ -80,7 +80,7 @@ static void cally_text_finalize (GObject *obj);
|
||||
/* AtkObject */
|
||||
static void cally_text_real_initialize (AtkObject *obj,
|
||||
gpointer data);
|
||||
static G_CONST_RETURN gchar * cally_text_get_name (AtkObject *obj);
|
||||
static const gchar * cally_text_get_name (AtkObject *obj);
|
||||
static AtkStateSet* cally_text_ref_state_set (AtkObject *obj);
|
||||
|
||||
/* atkaction */
|
||||
@ -327,10 +327,10 @@ cally_text_real_initialize(AtkObject *obj,
|
||||
obj->role = ATK_ROLE_TEXT;
|
||||
}
|
||||
|
||||
static G_CONST_RETURN gchar *
|
||||
static const gchar *
|
||||
cally_text_get_name (AtkObject *obj)
|
||||
{
|
||||
G_CONST_RETURN gchar *name;
|
||||
const gchar *name;
|
||||
|
||||
g_return_val_if_fail (CALLY_IS_ACTOR (obj), NULL);
|
||||
|
||||
|
@ -62,8 +62,8 @@ static guint cally_util_add_key_event_listener (AtkKeySnoopF
|
||||
gpointer data);
|
||||
static void cally_util_remove_key_event_listener (guint remove_listener);
|
||||
static AtkObject* cally_util_get_root (void);
|
||||
static G_CONST_RETURN gchar *cally_util_get_toolkit_name (void);
|
||||
static G_CONST_RETURN gchar *cally_util_get_toolkit_version (void);
|
||||
static const gchar * cally_util_get_toolkit_name (void);
|
||||
static const gchar * cally_util_get_toolkit_version (void);
|
||||
|
||||
/* private */
|
||||
static void _listener_info_destroy (gpointer data);
|
||||
@ -162,13 +162,13 @@ cally_util_get_root (void)
|
||||
return root;
|
||||
}
|
||||
|
||||
static G_CONST_RETURN gchar *
|
||||
static const gchar *
|
||||
cally_util_get_toolkit_name (void)
|
||||
{
|
||||
return "CALLY";
|
||||
}
|
||||
|
||||
static G_CONST_RETURN gchar *
|
||||
static const gchar *
|
||||
cally_util_get_toolkit_version (void)
|
||||
{
|
||||
/*
|
||||
|
@ -66,32 +66,29 @@ struct _ClutterMetaGroupClass
|
||||
|
||||
GType _clutter_meta_group_get_type (void) G_GNUC_CONST;
|
||||
|
||||
void _clutter_meta_group_add_meta (ClutterMetaGroup *group,
|
||||
ClutterActorMeta *meta);
|
||||
void _clutter_meta_group_remove_meta (ClutterMetaGroup *group,
|
||||
ClutterActorMeta *meta);
|
||||
G_CONST_RETURN GList *_clutter_meta_group_peek_metas (ClutterMetaGroup *group);
|
||||
void _clutter_meta_group_clear_metas (ClutterMetaGroup *group);
|
||||
ClutterActorMeta * _clutter_meta_group_get_meta (ClutterMetaGroup *group,
|
||||
const gchar *name);
|
||||
void _clutter_meta_group_add_meta (ClutterMetaGroup *group,
|
||||
ClutterActorMeta *meta);
|
||||
void _clutter_meta_group_remove_meta (ClutterMetaGroup *group,
|
||||
ClutterActorMeta *meta);
|
||||
const GList * _clutter_meta_group_peek_metas (ClutterMetaGroup *group);
|
||||
void _clutter_meta_group_clear_metas (ClutterMetaGroup *group);
|
||||
ClutterActorMeta * _clutter_meta_group_get_meta (ClutterMetaGroup *group,
|
||||
const gchar *name);
|
||||
|
||||
GList *
|
||||
_clutter_meta_group_get_metas_no_internal (ClutterMetaGroup *group);
|
||||
|
||||
void
|
||||
_clutter_meta_group_clear_metas_no_internal (ClutterMetaGroup *group);
|
||||
GList * _clutter_meta_group_get_metas_no_internal (ClutterMetaGroup *group);
|
||||
void _clutter_meta_group_clear_metas_no_internal (ClutterMetaGroup *group);
|
||||
|
||||
/* ActorMeta */
|
||||
void _clutter_actor_meta_set_actor (ClutterActorMeta *meta,
|
||||
ClutterActor *actor);
|
||||
void _clutter_actor_meta_set_actor (ClutterActorMeta *meta,
|
||||
ClutterActor *actor);
|
||||
|
||||
const gchar * _clutter_actor_meta_get_debug_name (ClutterActorMeta *meta);
|
||||
const gchar * _clutter_actor_meta_get_debug_name (ClutterActorMeta *meta);
|
||||
|
||||
void _clutter_actor_meta_set_priority (ClutterActorMeta *meta,
|
||||
gint priority);
|
||||
int _clutter_actor_meta_get_priority (ClutterActorMeta *meta);
|
||||
void _clutter_actor_meta_set_priority (ClutterActorMeta *meta,
|
||||
gint priority);
|
||||
int _clutter_actor_meta_get_priority (ClutterActorMeta *meta);
|
||||
|
||||
gboolean _clutter_actor_meta_is_internal (ClutterActorMeta *meta);
|
||||
gboolean _clutter_actor_meta_is_internal (ClutterActorMeta *meta);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
@ -282,7 +282,7 @@ clutter_actor_meta_set_name (ClutterActorMeta *meta,
|
||||
*
|
||||
* Since: 1.4
|
||||
*/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
clutter_actor_meta_get_name (ClutterActorMeta *meta)
|
||||
{
|
||||
g_return_val_if_fail (CLUTTER_IS_ACTOR_META (meta), NULL);
|
||||
@ -522,7 +522,7 @@ _clutter_meta_group_remove_meta (ClutterMetaGroup *group,
|
||||
*
|
||||
* Return value: a const pointer to the #GList of #ClutterActorMeta
|
||||
*/
|
||||
G_CONST_RETURN GList *
|
||||
const GList *
|
||||
_clutter_meta_group_peek_metas (ClutterMetaGroup *group)
|
||||
{
|
||||
return group->meta;
|
||||
|
@ -90,14 +90,14 @@ struct _ClutterActorMetaClass
|
||||
|
||||
GType clutter_actor_meta_get_type (void) G_GNUC_CONST;
|
||||
|
||||
void clutter_actor_meta_set_name (ClutterActorMeta *meta,
|
||||
const gchar *name);
|
||||
G_CONST_RETURN gchar *clutter_actor_meta_get_name (ClutterActorMeta *meta);
|
||||
void clutter_actor_meta_set_enabled (ClutterActorMeta *meta,
|
||||
gboolean is_enabled);
|
||||
gboolean clutter_actor_meta_get_enabled (ClutterActorMeta *meta);
|
||||
void clutter_actor_meta_set_name (ClutterActorMeta *meta,
|
||||
const gchar *name);
|
||||
const gchar * clutter_actor_meta_get_name (ClutterActorMeta *meta);
|
||||
void clutter_actor_meta_set_enabled (ClutterActorMeta *meta,
|
||||
gboolean is_enabled);
|
||||
gboolean clutter_actor_meta_get_enabled (ClutterActorMeta *meta);
|
||||
|
||||
ClutterActor * clutter_actor_meta_get_actor (ClutterActorMeta *meta);
|
||||
ClutterActor * clutter_actor_meta_get_actor (ClutterActorMeta *meta);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
@ -158,11 +158,11 @@ void _clutter_actor_set_queue_redraw_clip (ClutterActor *self,
|
||||
void _clutter_actor_finish_queue_redraw (ClutterActor *self,
|
||||
ClutterPaintVolume *clip);
|
||||
|
||||
gboolean _clutter_actor_set_default_paint_volume (ClutterActor *self,
|
||||
GType check_gtype,
|
||||
ClutterPaintVolume *volume);
|
||||
gboolean _clutter_actor_set_default_paint_volume (ClutterActor *self,
|
||||
GType check_gtype,
|
||||
ClutterPaintVolume *volume);
|
||||
|
||||
G_CONST_RETURN gchar *_clutter_actor_get_debug_name (ClutterActor *self);
|
||||
const gchar * _clutter_actor_get_debug_name (ClutterActor *self);
|
||||
|
||||
void _clutter_actor_push_clone_paint (void);
|
||||
void _clutter_actor_pop_clone_paint (void);
|
||||
|
@ -703,7 +703,15 @@ G_DEFINE_ABSTRACT_TYPE_WITH_CODE (ClutterActor,
|
||||
G_IMPLEMENT_INTERFACE (ATK_TYPE_IMPLEMENTOR,
|
||||
atk_implementor_iface_init));
|
||||
|
||||
G_CONST_RETURN gchar *
|
||||
/*< private >
|
||||
* clutter_actor_get_debug_name:
|
||||
* @actor: a #ClutterActor
|
||||
*
|
||||
* Retrieves a printable name of @actor for debugging messages
|
||||
*
|
||||
* Return value: a string with a printable name
|
||||
*/
|
||||
const gchar *
|
||||
_clutter_actor_get_debug_name (ClutterActor *actor)
|
||||
{
|
||||
return actor->priv->name != NULL ? actor->priv->name
|
||||
@ -7662,7 +7670,7 @@ clutter_actor_set_name (ClutterActor *self,
|
||||
* Return value: the name of the actor, or %NULL. The returned string is
|
||||
* owned by the actor and should not be modified or freed.
|
||||
*/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
clutter_actor_get_name (ClutterActor *self)
|
||||
{
|
||||
g_return_val_if_fail (CLUTTER_IS_ACTOR (self), NULL);
|
||||
|
@ -459,7 +459,7 @@ ClutterOffscreenRedirect
|
||||
|
||||
void clutter_actor_set_name (ClutterActor *self,
|
||||
const gchar *name);
|
||||
G_CONST_RETURN gchar *clutter_actor_get_name (ClutterActor *self);
|
||||
const gchar * clutter_actor_get_name (ClutterActor *self);
|
||||
|
||||
#ifndef CLUTTER_DISABLE_DEPRECATED
|
||||
guint32 clutter_actor_get_gid (ClutterActor *self);
|
||||
|
@ -2020,7 +2020,7 @@ clutter_animator_key_get_object (const ClutterAnimatorKey *key)
|
||||
*
|
||||
* Since: 1.2
|
||||
*/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
clutter_animator_key_get_property_name (const ClutterAnimatorKey *key)
|
||||
{
|
||||
g_return_val_if_fail (key != NULL, NULL);
|
||||
|
@ -159,14 +159,14 @@ void clutter_animator_property_set_interpolation (ClutterAnimato
|
||||
const gchar *property_name,
|
||||
ClutterInterpolation interpolation);
|
||||
|
||||
GType clutter_animator_key_get_type (void) G_GNUC_CONST;
|
||||
GObject * clutter_animator_key_get_object (const ClutterAnimatorKey *key);
|
||||
G_CONST_RETURN gchar *clutter_animator_key_get_property_name (const ClutterAnimatorKey *key);
|
||||
GType clutter_animator_key_get_property_type (const ClutterAnimatorKey *key);
|
||||
gulong clutter_animator_key_get_mode (const ClutterAnimatorKey *key);
|
||||
gdouble clutter_animator_key_get_progress (const ClutterAnimatorKey *key);
|
||||
gboolean clutter_animator_key_get_value (const ClutterAnimatorKey *key,
|
||||
GValue *value);
|
||||
GType clutter_animator_key_get_type (void) G_GNUC_CONST;
|
||||
GObject * clutter_animator_key_get_object (const ClutterAnimatorKey *key);
|
||||
const gchar * clutter_animator_key_get_property_name (const ClutterAnimatorKey *key);
|
||||
GType clutter_animator_key_get_property_type (const ClutterAnimatorKey *key);
|
||||
gulong clutter_animator_key_get_mode (const ClutterAnimatorKey *key);
|
||||
gdouble clutter_animator_key_get_progress (const ClutterAnimatorKey *key);
|
||||
gboolean clutter_animator_key_get_value (const ClutterAnimatorKey *key,
|
||||
GValue *value);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
@ -879,7 +879,7 @@ clutter_backend_set_font_name (ClutterBackend *backend,
|
||||
*
|
||||
* Deprecated: 1.4: Use #ClutterSettings:font-name instead
|
||||
*/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
clutter_backend_get_font_name (ClutterBackend *backend)
|
||||
{
|
||||
ClutterBackendPrivate *priv;
|
||||
|
@ -71,7 +71,7 @@ void clutter_backend_set_double_click_distance (ClutterBa
|
||||
guint clutter_backend_get_double_click_distance (ClutterBackend *backend);
|
||||
void clutter_backend_set_font_name (ClutterBackend *backend,
|
||||
const gchar *font_name);
|
||||
G_CONST_RETURN gchar * clutter_backend_get_font_name (ClutterBackend *backend);
|
||||
const gchar * clutter_backend_get_font_name (ClutterBackend *backend);
|
||||
#endif /* CLUTTER_DISABLE_DEPRECATED */
|
||||
|
||||
gdouble clutter_backend_get_resolution (ClutterBackend *backend);
|
||||
|
@ -723,7 +723,7 @@ clutter_binding_pool_override_closure (ClutterBindingPool *pool,
|
||||
*
|
||||
* Since: 1.0
|
||||
*/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
clutter_binding_pool_find_action (ClutterBindingPool *pool,
|
||||
guint key_val,
|
||||
ClutterModifierType modifiers)
|
||||
|
@ -98,7 +98,7 @@ void clutter_binding_pool_override_closure (ClutterBindingPool
|
||||
ClutterModifierType modifiers,
|
||||
GClosure *closure);
|
||||
|
||||
G_CONST_RETURN gchar *clutter_binding_pool_find_action (ClutterBindingPool *pool,
|
||||
const gchar * clutter_binding_pool_find_action (ClutterBindingPool *pool,
|
||||
guint key_val,
|
||||
ClutterModifierType modifiers);
|
||||
void clutter_binding_pool_remove_action (ClutterBindingPool *pool,
|
||||
|
@ -115,7 +115,7 @@ static const ClutterColor const static_colors[] = {
|
||||
*
|
||||
* Since: 1.6
|
||||
*/
|
||||
G_CONST_RETURN ClutterColor *
|
||||
const ClutterColor *
|
||||
clutter_color_get_static (ClutterStaticColor color)
|
||||
{
|
||||
g_return_val_if_fail (color >= CLUTTER_COLOR_WHITE &&
|
||||
@ -1055,7 +1055,7 @@ clutter_value_set_color (GValue *value,
|
||||
*
|
||||
* Since: 0.8.4
|
||||
*/
|
||||
G_CONST_RETURN ClutterColor *
|
||||
const ClutterColor *
|
||||
clutter_value_get_color (const GValue *value)
|
||||
{
|
||||
g_return_val_if_fail (CLUTTER_VALUE_HOLDS_COLOR (value), NULL);
|
||||
|
@ -138,9 +138,9 @@ struct _ClutterParamSpecColor
|
||||
ClutterColor *default_value;
|
||||
};
|
||||
|
||||
void clutter_value_set_color (GValue *value,
|
||||
const ClutterColor *color);
|
||||
G_CONST_RETURN ClutterColor *clutter_value_get_color (const GValue *value);
|
||||
void clutter_value_set_color (GValue *value,
|
||||
const ClutterColor *color);
|
||||
const ClutterColor * clutter_value_get_color (const GValue *value);
|
||||
|
||||
GType clutter_param_color_get_type (void) G_GNUC_CONST;
|
||||
GParamSpec *clutter_param_spec_color (const gchar *name,
|
||||
@ -254,7 +254,7 @@ typedef enum { /*< prefix=CLUTTER_COLOR >*/
|
||||
CLUTTER_COLOR_TRANSPARENT
|
||||
} ClutterStaticColor;
|
||||
|
||||
G_CONST_RETURN ClutterColor *clutter_color_get_static (ClutterStaticColor color);
|
||||
const ClutterColor *clutter_color_get_static (ClutterStaticColor color);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
@ -1203,7 +1203,7 @@ clutter_get_current_event_time (void)
|
||||
*
|
||||
* Since: 1.2
|
||||
*/
|
||||
G_CONST_RETURN ClutterEvent *
|
||||
const ClutterEvent *
|
||||
clutter_get_current_event (void)
|
||||
{
|
||||
ClutterMainContext *context = _clutter_context_get_default ();
|
||||
|
@ -454,8 +454,7 @@ ClutterScrollDirection clutter_event_get_scroll_direction (const ClutterEv
|
||||
guint32 clutter_keysym_to_unicode (guint keyval);
|
||||
|
||||
guint32 clutter_get_current_event_time (void);
|
||||
|
||||
G_CONST_RETURN ClutterEvent *clutter_get_current_event (void);
|
||||
const ClutterEvent * clutter_get_current_event (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
@ -786,7 +786,7 @@ clutter_input_device_get_pointer_stage (ClutterInputDevice *device)
|
||||
*
|
||||
* Since: 1.2
|
||||
*/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
clutter_input_device_get_device_name (ClutterInputDevice *device)
|
||||
{
|
||||
g_return_val_if_fail (CLUTTER_IS_INPUT_DEVICE (device), NULL);
|
||||
|
@ -135,7 +135,7 @@ void clutter_input_device_get_device_coords (ClutterInputDev
|
||||
gint *y);
|
||||
ClutterActor * clutter_input_device_get_pointer_actor (ClutterInputDevice *device);
|
||||
ClutterStage * clutter_input_device_get_pointer_stage (ClutterInputDevice *device);
|
||||
G_CONST_RETURN gchar * clutter_input_device_get_device_name (ClutterInputDevice *device);
|
||||
const gchar * clutter_input_device_get_device_name (ClutterInputDevice *device);
|
||||
ClutterInputMode clutter_input_device_get_device_mode (ClutterInputDevice *device);
|
||||
gboolean clutter_input_device_get_has_cursor (ClutterInputDevice *device);
|
||||
void clutter_input_device_set_enabled (ClutterInputDevice *device,
|
||||
|
@ -918,7 +918,7 @@ clutter_interval_compute_value (ClutterInterval *interval,
|
||||
*
|
||||
* Since: 1.4
|
||||
*/
|
||||
G_CONST_RETURN GValue *
|
||||
const GValue *
|
||||
clutter_interval_compute (ClutterInterval *interval,
|
||||
gdouble factor)
|
||||
{
|
||||
|
@ -154,7 +154,7 @@ gboolean clutter_interval_compute_value (ClutterInterval *interval,
|
||||
gdouble factor,
|
||||
GValue *value);
|
||||
|
||||
G_CONST_RETURN GValue *clutter_interval_compute (ClutterInterval *interval,
|
||||
const GValue * clutter_interval_compute (ClutterInterval *interval,
|
||||
gdouble factor);
|
||||
|
||||
void clutter_interval_register_progress_func (GType value_type,
|
||||
|
@ -1382,7 +1382,7 @@ clutter_model_remove (ClutterModel *model,
|
||||
*
|
||||
* Since: 0.6
|
||||
*/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
clutter_model_get_column_name (ClutterModel *model,
|
||||
guint column)
|
||||
{
|
||||
|
@ -226,7 +226,7 @@ void clutter_model_remove (ClutterModel *model,
|
||||
|
||||
guint clutter_model_get_n_rows (ClutterModel *model);
|
||||
guint clutter_model_get_n_columns (ClutterModel *model);
|
||||
G_CONST_RETURN gchar *clutter_model_get_column_name (ClutterModel *model,
|
||||
const gchar * clutter_model_get_column_name (ClutterModel *model,
|
||||
guint column);
|
||||
GType clutter_model_get_column_type (ClutterModel *model,
|
||||
guint column);
|
||||
|
@ -189,7 +189,7 @@ ClutterActor * _clutter_context_peek_shader_stack (void);
|
||||
guint32 _clutter_context_acquire_id (gpointer key);
|
||||
void _clutter_context_release_id (guint32 id_);
|
||||
|
||||
G_CONST_RETURN gchar *_clutter_gettext (const gchar *str);
|
||||
const gchar *_clutter_gettext (const gchar *str);
|
||||
|
||||
gboolean _clutter_feature_init (GError **error);
|
||||
|
||||
|
@ -795,7 +795,7 @@ clutter_script_get_type_from_name (ClutterScript *script,
|
||||
*
|
||||
* Since: 0.6
|
||||
*/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
clutter_get_script_id (GObject *gobject)
|
||||
{
|
||||
g_return_val_if_fail (G_IS_OBJECT (gobject), NULL);
|
||||
|
@ -168,7 +168,7 @@ void clutter_script_ensure_objects (ClutterScript *script);
|
||||
GType clutter_script_get_type_from_name (ClutterScript *script,
|
||||
const gchar *type_name);
|
||||
|
||||
G_CONST_RETURN gchar *clutter_get_script_id (GObject *gobject);
|
||||
const gchar * clutter_get_script_id (GObject *gobject);
|
||||
|
||||
void clutter_script_connect_signals (ClutterScript *script,
|
||||
gpointer user_data);
|
||||
|
@ -104,7 +104,7 @@ clutter_scriptable_set_id (ClutterScriptable *scriptable,
|
||||
*
|
||||
* Since: 0.6
|
||||
*/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
clutter_scriptable_get_id (ClutterScriptable *scriptable)
|
||||
{
|
||||
ClutterScriptableIface *iface;
|
||||
|
@ -91,7 +91,7 @@ GType clutter_scriptable_get_type (void) G_GNUC_CONST
|
||||
|
||||
void clutter_scriptable_set_id (ClutterScriptable *scriptable,
|
||||
const gchar *id_);
|
||||
G_CONST_RETURN gchar *clutter_scriptable_get_id (ClutterScriptable *scriptable);
|
||||
const gchar * clutter_scriptable_get_id (ClutterScriptable *scriptable);
|
||||
gboolean clutter_scriptable_parse_custom_node (ClutterScriptable *scriptable,
|
||||
ClutterScript *script,
|
||||
GValue *value,
|
||||
|
@ -485,7 +485,7 @@ clutter_value_set_shader_matrix (GValue *value,
|
||||
*
|
||||
* Since: 0.8
|
||||
*/
|
||||
G_CONST_RETURN gfloat *
|
||||
const gfloat *
|
||||
clutter_value_get_shader_float (const GValue *value,
|
||||
gsize *length)
|
||||
{
|
||||
@ -517,7 +517,7 @@ clutter_value_get_shader_float (const GValue *value,
|
||||
*
|
||||
* Since: 0.8
|
||||
*/
|
||||
G_CONST_RETURN gint *
|
||||
const gint *
|
||||
clutter_value_get_shader_int (const GValue *value,
|
||||
gsize *length)
|
||||
{
|
||||
@ -549,7 +549,7 @@ clutter_value_get_shader_int (const GValue *value,
|
||||
*
|
||||
* Since: 0.8
|
||||
*/
|
||||
G_CONST_RETURN gfloat *
|
||||
const gfloat *
|
||||
clutter_value_get_shader_matrix (const GValue *value,
|
||||
gsize *length)
|
||||
{
|
||||
|
@ -74,21 +74,21 @@ GType clutter_shader_float_get_type (void) G_GNUC_CONST;
|
||||
GType clutter_shader_int_get_type (void) G_GNUC_CONST;
|
||||
GType clutter_shader_matrix_get_type (void) G_GNUC_CONST;
|
||||
|
||||
void clutter_value_set_shader_float (GValue *value,
|
||||
gint size,
|
||||
const gfloat *floats);
|
||||
void clutter_value_set_shader_int (GValue *value,
|
||||
gint size,
|
||||
const gint *ints);
|
||||
void clutter_value_set_shader_matrix (GValue *value,
|
||||
gint size,
|
||||
const gfloat *matrix);
|
||||
G_CONST_RETURN gfloat * clutter_value_get_shader_float (const GValue *value,
|
||||
gsize *length);
|
||||
G_CONST_RETURN gint * clutter_value_get_shader_int (const GValue *value,
|
||||
gsize *length);
|
||||
G_CONST_RETURN gfloat * clutter_value_get_shader_matrix (const GValue *value,
|
||||
gsize *length);
|
||||
void clutter_value_set_shader_float (GValue *value,
|
||||
gint size,
|
||||
const gfloat *floats);
|
||||
void clutter_value_set_shader_int (GValue *value,
|
||||
gint size,
|
||||
const gint *ints);
|
||||
void clutter_value_set_shader_matrix (GValue *value,
|
||||
gint size,
|
||||
const gfloat *matrix);
|
||||
const gfloat * clutter_value_get_shader_float (const GValue *value,
|
||||
gsize *length);
|
||||
const gint * clutter_value_get_shader_int (const GValue *value,
|
||||
gsize *length);
|
||||
const gfloat * clutter_value_get_shader_matrix (const GValue *value,
|
||||
gsize *length);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
@ -847,7 +847,7 @@ _clutter_shader_release_all (void)
|
||||
*
|
||||
* Deprecated: 1.8: Use #ClutterShaderEffect instead.
|
||||
*/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
clutter_shader_get_fragment_source (ClutterShader *shader)
|
||||
{
|
||||
g_return_val_if_fail (CLUTTER_IS_SHADER (shader), NULL);
|
||||
@ -869,7 +869,7 @@ clutter_shader_get_fragment_source (ClutterShader *shader)
|
||||
*
|
||||
* Deprecated: 1.8: Use #ClutterShaderEffect instead.
|
||||
*/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
clutter_shader_get_vertex_source (ClutterShader *shader)
|
||||
{
|
||||
g_return_val_if_fail (CLUTTER_IS_SHADER (shader), NULL);
|
||||
|
@ -107,8 +107,8 @@ struct _ClutterShaderClass
|
||||
GObjectClass parent_class;
|
||||
};
|
||||
|
||||
GQuark clutter_shader_error_quark (void);
|
||||
GType clutter_shader_get_type (void) G_GNUC_CONST;
|
||||
GQuark clutter_shader_error_quark (void);
|
||||
GType clutter_shader_get_type (void) G_GNUC_CONST;
|
||||
|
||||
ClutterShader * clutter_shader_new (void);
|
||||
|
||||
@ -128,8 +128,8 @@ void clutter_shader_set_fragment_source (ClutterShader
|
||||
const gchar *data,
|
||||
gssize length);
|
||||
|
||||
G_CONST_RETURN gchar *clutter_shader_get_vertex_source (ClutterShader *shader);
|
||||
G_CONST_RETURN gchar *clutter_shader_get_fragment_source (ClutterShader *shader);
|
||||
const gchar * clutter_shader_get_vertex_source (ClutterShader *shader);
|
||||
const gchar * clutter_shader_get_fragment_source (ClutterShader *shader);
|
||||
|
||||
void clutter_shader_set_uniform (ClutterShader *shader,
|
||||
const gchar *name,
|
||||
|
@ -2726,7 +2726,7 @@ clutter_stage_set_title (ClutterStage *stage,
|
||||
*
|
||||
* Since: 0.4
|
||||
**/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
clutter_stage_get_title (ClutterStage *stage)
|
||||
{
|
||||
g_return_val_if_fail (CLUTTER_IS_STAGE (stage), NULL);
|
||||
|
@ -218,7 +218,7 @@ gboolean clutter_stage_event (ClutterStage *stage,
|
||||
|
||||
void clutter_stage_set_title (ClutterStage *stage,
|
||||
const gchar *title);
|
||||
G_CONST_RETURN gchar *clutter_stage_get_title (ClutterStage *stage);
|
||||
const gchar * clutter_stage_get_title (ClutterStage *stage);
|
||||
void clutter_stage_set_user_resizable (ClutterStage *stage,
|
||||
gboolean resizable);
|
||||
gboolean clutter_stage_get_user_resizable (ClutterStage *stage);
|
||||
|
@ -1730,7 +1730,7 @@ clutter_state_key_get_object (const ClutterStateKey *state_key)
|
||||
*
|
||||
* Since: 1.4
|
||||
*/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
clutter_state_key_get_property_name (const ClutterStateKey *state_key)
|
||||
{
|
||||
g_return_val_if_fail (state_key, NULL);
|
||||
@ -1751,7 +1751,7 @@ clutter_state_key_get_property_name (const ClutterStateKey *state_key)
|
||||
*
|
||||
* Since: 1.4
|
||||
*/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
clutter_state_key_get_source_state_name (const ClutterStateKey *state_key)
|
||||
{
|
||||
g_return_val_if_fail (state_key, NULL);
|
||||
@ -1775,7 +1775,7 @@ clutter_state_key_get_source_state_name (const ClutterStateKey *state_key)
|
||||
*
|
||||
* Since: 1.4
|
||||
*/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
clutter_state_key_get_target_state_name (const ClutterStateKey *state_key)
|
||||
{
|
||||
g_return_val_if_fail (state_key, NULL);
|
||||
@ -1934,7 +1934,7 @@ clutter_state_get_duration (ClutterState *state,
|
||||
*
|
||||
* Since: 1.4
|
||||
*/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
clutter_state_get_state (ClutterState *state)
|
||||
{
|
||||
g_return_val_if_fail (CLUTTER_IS_STATE (state), NULL);
|
||||
|
@ -138,7 +138,7 @@ void clutter_state_set_animator (ClutterState *state,
|
||||
ClutterAnimator * clutter_state_get_animator (ClutterState *state,
|
||||
const gchar *source_state_name,
|
||||
const gchar *target_state_name);
|
||||
G_CONST_RETURN gchar *clutter_state_get_state (ClutterState *state);
|
||||
const gchar * clutter_state_get_state (ClutterState *state);
|
||||
|
||||
/*
|
||||
* ClutterStateKey
|
||||
@ -152,9 +152,9 @@ gboolean clutter_state_key_get_value (const ClutterStat
|
||||
GValue *value);
|
||||
GType clutter_state_key_get_property_type (const ClutterStateKey *key);
|
||||
GObject * clutter_state_key_get_object (const ClutterStateKey *state_key);
|
||||
G_CONST_RETURN gchar *clutter_state_key_get_property_name (const ClutterStateKey *state_key);
|
||||
G_CONST_RETURN gchar *clutter_state_key_get_source_state_name (const ClutterStateKey *state_key);
|
||||
G_CONST_RETURN gchar *clutter_state_key_get_target_state_name (const ClutterStateKey *state_key);
|
||||
const gchar * clutter_state_key_get_property_name (const ClutterStateKey *state_key);
|
||||
const gchar * clutter_state_key_get_source_state_name (const ClutterStateKey *state_key);
|
||||
const gchar * clutter_state_key_get_target_state_name (const ClutterStateKey *state_key);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
@ -4010,7 +4010,7 @@ clutter_text_get_font_description (ClutterText *self)
|
||||
*
|
||||
* Since: 1.0
|
||||
*/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
clutter_text_get_font_name (ClutterText *text)
|
||||
{
|
||||
g_return_val_if_fail (CLUTTER_IS_TEXT (text), NULL);
|
||||
@ -4115,7 +4115,7 @@ out:
|
||||
*
|
||||
* Since: 1.0
|
||||
*/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
clutter_text_get_text (ClutterText *self)
|
||||
{
|
||||
g_return_val_if_fail (CLUTTER_IS_TEXT (self), NULL);
|
||||
|
@ -103,7 +103,7 @@ ClutterActor * clutter_text_new_full (const gchar *f
|
||||
ClutterActor * clutter_text_new_with_text (const gchar *font_name,
|
||||
const gchar *text);
|
||||
|
||||
G_CONST_RETURN gchar *clutter_text_get_text (ClutterText *self);
|
||||
const gchar * clutter_text_get_text (ClutterText *self);
|
||||
void clutter_text_set_text (ClutterText *self,
|
||||
const gchar *text);
|
||||
void clutter_text_set_markup (ClutterText *self,
|
||||
@ -114,7 +114,7 @@ void clutter_text_get_color (ClutterText *s
|
||||
ClutterColor *color);
|
||||
void clutter_text_set_font_name (ClutterText *self,
|
||||
const gchar *font_name);
|
||||
G_CONST_RETURN gchar *clutter_text_get_font_name (ClutterText *self);
|
||||
const gchar * clutter_text_get_font_name (ClutterText *self);
|
||||
void clutter_text_set_font_description (ClutterText *self,
|
||||
PangoFontDescription *font_desc);
|
||||
PangoFontDescription *clutter_text_get_font_description (ClutterText *self);
|
||||
|
@ -773,7 +773,7 @@ clutter_value_set_units (GValue *value,
|
||||
*
|
||||
* Since: 0.8
|
||||
*/
|
||||
G_CONST_RETURN ClutterUnits *
|
||||
const ClutterUnits *
|
||||
clutter_value_get_units (const GValue *value)
|
||||
{
|
||||
g_return_val_if_fail (CLUTTER_VALUE_HOLDS_UNITS (value), NULL);
|
||||
|
@ -179,9 +179,9 @@ GParamSpec * clutter_param_spec_units (const gchar *name,
|
||||
gfloat default_value,
|
||||
GParamFlags flags);
|
||||
|
||||
void clutter_value_set_units (GValue *value,
|
||||
const ClutterUnits *units);
|
||||
G_CONST_RETURN ClutterUnits *clutter_value_get_units (const GValue *value);
|
||||
void clutter_value_set_units (GValue *value,
|
||||
const ClutterUnits *units);
|
||||
const ClutterUnits * clutter_value_get_units (const GValue *value);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
@ -68,7 +68,7 @@ clutter_util_next_p2 (gint a)
|
||||
*
|
||||
* Return value: the translated string
|
||||
*/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
_clutter_gettext (const gchar *str)
|
||||
{
|
||||
return g_dgettext (GETTEXT_PACKAGE, str);
|
||||
|
@ -76,7 +76,7 @@ clutter_backend_at_exit (void)
|
||||
g_object_run_dispose (G_OBJECT (backend_singleton));
|
||||
}
|
||||
|
||||
G_CONST_RETURN gchar*
|
||||
const gchar*
|
||||
_clutter_backend_egl_get_vblank (void)
|
||||
{
|
||||
if (clutter_vblank && strcmp (clutter_vblank, "0") == 0)
|
||||
|
@ -98,8 +98,7 @@ GType _clutter_backend_egl_get_type (void) G_GNUC_CONST;
|
||||
void _clutter_events_egl_init (ClutterBackendEGL *backend);
|
||||
void _clutter_events_egl_uninit (ClutterBackendEGL *backend);
|
||||
|
||||
G_CONST_RETURN gchar*
|
||||
_clutter_backend_egl_get_vblank (void);
|
||||
const gchar *_clutter_backend_egl_get_vblank (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
@ -59,7 +59,7 @@ static ClutterBackendGLX *backend_singleton = NULL;
|
||||
|
||||
static gchar *clutter_vblank = NULL;
|
||||
|
||||
G_CONST_RETURN gchar*
|
||||
const gchar *
|
||||
_clutter_backend_glx_get_vblank (void)
|
||||
{
|
||||
if (clutter_vblank && strcmp (clutter_vblank, "0") == 0)
|
||||
|
@ -72,8 +72,7 @@ struct _ClutterBackendGLXClass
|
||||
|
||||
GType _clutter_backend_glx_get_type (void) G_GNUC_CONST;
|
||||
|
||||
G_CONST_RETURN gchar*
|
||||
_clutter_backend_glx_get_vblank (void);
|
||||
const gchar *_clutter_backend_glx_get_vblank (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
@ -54,7 +54,7 @@ static HINSTANCE clutter_hinst = NULL;
|
||||
/* various flags corresponding to pre init setup calls */
|
||||
static gboolean _no_event_retrieval = FALSE;
|
||||
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
_clutter_backend_win32_get_vblank (void)
|
||||
{
|
||||
if (clutter_vblank_name && strcmp (clutter_vblank_name, "0") == 0)
|
||||
|
@ -72,7 +72,7 @@ clutter_backend_win32_get_features (ClutterBackend *backend);
|
||||
|
||||
HCURSOR _clutter_backend_win32_get_invisible_cursor (ClutterBackend *backend);
|
||||
|
||||
G_CONST_RETURN gchar *_clutter_backend_win32_get_vblank (void);
|
||||
const gchar *_clutter_backend_win32_get_vblank (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
@ -1027,7 +1027,7 @@ clutter_x11_remove_filter (ClutterX11FilterFunc func,
|
||||
* pointer to the internal list of input devices; the returned list is
|
||||
* owned by Clutter and should not be modified or freed
|
||||
*/
|
||||
G_CONST_RETURN GSList *
|
||||
const GSList *
|
||||
clutter_x11_get_input_devices (void)
|
||||
{
|
||||
ClutterDeviceManager *manager;
|
||||
|
@ -127,7 +127,7 @@ gboolean clutter_x11_has_event_retrieval (void);
|
||||
ClutterStage *clutter_x11_get_stage_from_window (Window win);
|
||||
|
||||
#ifndef CLUTTER_DISABLE_DEPRECATED
|
||||
G_CONST_RETURN GSList* clutter_x11_get_input_devices (void) G_GNUC_DEPRECATED;
|
||||
const GSList* clutter_x11_get_input_devices (void) G_GNUC_DEPRECATED;
|
||||
#endif
|
||||
|
||||
void clutter_x11_enable_xinput (void);
|
||||
|
@ -406,10 +406,10 @@ definition should be vertically aligned in three columns:
|
||||
The maximum width of each column is given by the longest element in the
|
||||
column:
|
||||
|
||||
void clutter_type_set_property (ClutterType *type,
|
||||
const gchar *value,
|
||||
GError **error);
|
||||
G_CONST_RETURN gchar *clutter_type_get_property (ClutterType *type);
|
||||
void clutter_type_set_property (ClutterType *type,
|
||||
const gchar *value,
|
||||
GError **error);
|
||||
const gchar *clutter_type_get_property (ClutterType *type);
|
||||
|
||||
It is also possible to align the columns to the next tab:
|
||||
|
||||
|
@ -429,7 +429,7 @@ cb_button_set_text_color (CbButton *self,
|
||||
*
|
||||
* Returns: the button's text. This must not be freed by the application.
|
||||
*/
|
||||
G_CONST_RETURN gchar *
|
||||
const gchar *
|
||||
cb_button_get_text (CbButton *self)
|
||||
{
|
||||
g_return_val_if_fail (CB_IS_BUTTON (self), NULL);
|
||||
|
@ -67,7 +67,7 @@ struct _CbButtonClass
|
||||
ClutterActor *cb_button_new (void);
|
||||
|
||||
/* getter */
|
||||
G_CONST_RETURN gchar * cb_button_get_text (CbButton *self);
|
||||
const gchar *cb_button_get_text (CbButton *self);
|
||||
|
||||
/* setters - these are wrappers round functions
|
||||
* which change properties of the internal actors
|
||||
|
Loading…
x
Reference in New Issue
Block a user