klass->show_all (self);
}
-void
+static void
clutter_actor_real_hide (ClutterActor *self)
{
if (CLUTTER_ACTOR_IS_VISIBLE (self))
clutter_actor_update_map_state (self, MAP_STATE_CHECK);
}
-void
+static void
clutter_actor_real_unrealize (ClutterActor *self)
{
/* we must be unmapped (implying our children are also unmapped) */
}
}
-void
+static void
clutter_actor_real_queue_relayout (ClutterActor *self)
{
ClutterActorPrivate *priv = self->priv;
row += 1;
/* update the iterator and return it */
- clutter_model_iter_set_row (CLUTTER_MODEL_ITER (iter_default), row);
+ _clutter_model_iter_set_row (CLUTTER_MODEL_ITER (iter_default), row);
iter_default->seq_iter = filter_next;
return CLUTTER_MODEL_ITER (iter_default);
row -= 1;
/* update the iterator and return it */
- clutter_model_iter_set_row (CLUTTER_MODEL_ITER (iter_default), row);
+ _clutter_model_iter_set_row (CLUTTER_MODEL_ITER (iter_default), row);
iter_default->seq_iter = filter_prev;
return CLUTTER_MODEL_ITER (iter_default);
g_return_val_if_fail (n_columns > 0, NULL);
model = g_object_new (CLUTTER_TYPE_LIST_MODEL, NULL);
- clutter_model_set_n_columns (model, n_columns, TRUE, TRUE);
+ _clutter_model_set_n_columns (model, n_columns, TRUE, TRUE);
va_start (args, n_columns);
GType type = va_arg (args, GType);
const gchar *name = va_arg (args, gchar*);
- if (!clutter_model_check_type (type))
+ if (!_clutter_model_check_type (type))
{
g_warning ("%s: Invalid type %s\n", G_STRLOC, g_type_name (type));
g_object_unref (model);
return NULL;
}
- clutter_model_set_column_type (model, i, type);
- clutter_model_set_column_name (model, i, name);
+ _clutter_model_set_column_type (model, i, type);
+ _clutter_model_set_column_name (model, i, name);
}
va_end (args);
g_return_val_if_fail (n_columns > 0, NULL);
model = g_object_new (CLUTTER_TYPE_LIST_MODEL, NULL);
- clutter_model_set_n_columns (model, n_columns, TRUE, TRUE);
+ _clutter_model_set_n_columns (model, n_columns, TRUE, TRUE);
for (i = 0; i < n_columns; i++)
{
- if (!clutter_model_check_type (types[i]))
+ if (!_clutter_model_check_type (types[i]))
{
g_warning ("%s: Invalid type %s\n", G_STRLOC, g_type_name (types[i]));
g_object_unref (model);
return NULL;
}
- clutter_model_set_column_type (model, i, types[i]);
- clutter_model_set_column_name (model, i, names[i]);
+ _clutter_model_set_column_type (model, i, types[i]);
+ _clutter_model_set_column_name (model, i, names[i]);
}
return model;
NULL
};
+#define clutter_master_clock_get_type _clutter_master_clock_get_type
+
G_DEFINE_TYPE (ClutterMasterClock, clutter_master_clock, G_TYPE_OBJECT);
/*
G_BEGIN_DECLS
-#define CLUTTER_TYPE_MASTER_CLOCK (clutter_master_clock_get_type ())
+#define CLUTTER_TYPE_MASTER_CLOCK (_clutter_master_clock_get_type ())
#define CLUTTER_MASTER_CLOCK(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), CLUTTER_TYPE_MASTER_CLOCK, ClutterMasterClock))
#define CLUTTER_IS_MASTER_CLOCK(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), CLUTTER_TYPE_MASTER_CLOCK))
typedef struct _ClutterMasterClock ClutterMasterClock;
-GType clutter_master_clock_get_type (void) G_GNUC_CONST;
+GType _clutter_master_clock_get_type (void) G_GNUC_CONST;
ClutterMasterClock *_clutter_master_clock_get_default (void);
void _clutter_master_clock_add_timeline (ClutterMasterClock *master_clock,
+/*
+ * Clutter.
+ *
+ * An OpenGL based 'interactive canvas' library.
+ *
+ * Authored By Matthew Allum <mallum@openedhand.com>
+ * Neil Jagdish Patel <njp@o-hand.com>
+ * Emmanuele Bassi <ebassi@openedhand.com>
+ *
+ * Copyright (C) 2006 OpenedHand
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library. If not, see <http://www.gnu.org/licenses/>.
+ */
+
#ifndef __CLUTTER_MODEL_PRIVATE_H__
#define __CLUTTER_MODEL_PRIVATE_H__
-#include <glib.h>
-#include "clutter-model.h"
+#include <clutter/clutter-types.h>
+#include <clutter/clutter-model.h>
G_BEGIN_DECLS
-void clutter_model_set_n_columns (ClutterModel *model,
- gint n_columns,
- gboolean set_types,
- gboolean set_names);
-gboolean clutter_model_check_type (GType gtype);
-
-void clutter_model_set_column_type (ClutterModel *model,
- gint column,
- GType gtype);
-void clutter_model_set_column_name (ClutterModel *model,
- gint column,
- const gchar *name);
-
-void clutter_model_iter_set_row (ClutterModelIter *iter,
- guint row);
+void _clutter_model_set_n_columns (ClutterModel *model,
+ gint n_columns,
+ gboolean set_types,
+ gboolean set_names);
+gboolean _clutter_model_check_type (GType gtype);
+
+void _clutter_model_set_column_type (ClutterModel *model,
+ gint column,
+ GType gtype);
+void _clutter_model_set_column_name (ClutterModel *model,
+ gint column,
+ const gchar *name);
+
+void _clutter_model_iter_set_row (ClutterModelIter *iter,
+ guint row);
G_END_DECLS
* type.
*/
gboolean
-clutter_model_check_type (GType gtype)
+_clutter_model_check_type (GType gtype)
{
gint i = 0;
static const GType type_list[] =
columns = g_value_get_pointer (value);
n_columns = g_slist_length (columns);
- clutter_model_set_n_columns (model, n_columns, TRUE, TRUE);
+ _clutter_model_set_n_columns (model, n_columns, TRUE, TRUE);
for (i = 0, l = columns; l != NULL; l = l->next, i++)
{
ColumnInfo *cinfo = l->data;
- clutter_model_set_column_name (model, i, cinfo->name);
- clutter_model_set_column_type (model, i, cinfo->type);
+ _clutter_model_set_column_name (model, i, cinfo->name);
+ _clutter_model_set_column_type (model, i, cinfo->type);
g_free (cinfo->name);
g_slice_free (ColumnInfo, cinfo);
return priv->filter_func (model, iter, priv->filter_data);
}
-/*
+/*< private >
* clutter_model_set_n_columns:
* @model: a #ClutterModel
* @n_columns: number of columns
* This function can only be called once.
*/
void
-clutter_model_set_n_columns (ClutterModel *model,
- gint n_columns,
- gboolean set_types,
- gboolean set_names)
+_clutter_model_set_n_columns (ClutterModel *model,
+ gint n_columns,
+ gboolean set_types,
+ gboolean set_names)
{
ClutterModelPrivate *priv = model->priv;
priv->column_names = g_new0 (gchar*, n_columns);
}
-/*
- * clutter_model_set_column_type:
+/*< private >
+ * _clutter_model_set_column_type:
* @model: a #ClutterModel
* @column: column index
* @gtype: type of the column
* Sets the type of @column inside @model
*/
void
-clutter_model_set_column_type (ClutterModel *model,
- gint column,
- GType gtype)
+_clutter_model_set_column_type (ClutterModel *model,
+ gint column,
+ GType gtype)
{
ClutterModelPrivate *priv = model->priv;
priv->column_types[column] = gtype;
}
-/*
- * clutter_model_set_column_name:
+/*< private >
+ * _clutter_model_set_column_name:
* @model: a #ClutterModel
* @column: column index
* @name: name of the column, or %NULL
* Sets the name of @column inside @model
*/
void
-clutter_model_set_column_name (ClutterModel *model,
- gint column,
- const gchar *name)
+_clutter_model_set_column_name (ClutterModel *model,
+ gint column,
+ const gchar *name)
{
ClutterModelPrivate *priv = model->priv;
g_return_if_fail (priv->n_columns < 0 || priv->n_columns == n_columns);
g_return_if_fail (priv->column_types == NULL);
- clutter_model_set_n_columns (model, n_columns, TRUE, FALSE);
+ _clutter_model_set_n_columns (model, n_columns, TRUE, FALSE);
for (i = 0; i < n_columns; i++)
{
- if (!clutter_model_check_type (types[i]))
+ if (!_clutter_model_check_type (types[i]))
{
g_warning ("%s: Invalid type %s\n", G_STRLOC, g_type_name (types[i]));
return;
}
- clutter_model_set_column_type (model, i, types[i]);
+ _clutter_model_set_column_type (model, i, types[i]);
}
}
g_return_if_fail (priv->n_columns < 0 || priv->n_columns == n_columns);
g_return_if_fail (priv->column_names == NULL);
- clutter_model_set_n_columns (model, n_columns, FALSE, TRUE);
+ _clutter_model_set_n_columns (model, n_columns, FALSE, TRUE);
for (i = 0; i < n_columns; i++)
- clutter_model_set_column_name (model, i, names[i]);
+ _clutter_model_set_column_name (model, i, names[i]);
}
/**
/* private function */
void
-clutter_model_iter_set_row (ClutterModelIter *iter,
- guint row)
+_clutter_model_iter_set_row (ClutterModelIter *iter,
+ guint row)
{
iter->priv->row = row;
}
JsonObject *object);
static void clutter_script_parser_parse_end (JsonParser *parser);
+#define clutter_script_parser_get_type _clutter_script_parser_get_type
+
G_DEFINE_TYPE (ClutterScriptParser, clutter_script_parser, JSON_TYPE_PARSER);
static void
G_BEGIN_DECLS
-#define CLUTTER_TYPE_SCRIPT_PARSER (clutter_script_parser_get_type ())
+#define CLUTTER_TYPE_SCRIPT_PARSER (_clutter_script_parser_get_type ())
#define CLUTTER_SCRIPT_PARSER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), CLUTTER_TYPE_SCRIPT_PARSER, ClutterScriptParser))
#define CLUTTER_IS_SCRIPT_PARSER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), CLUTTER_TYPE_SCRIPT_PARSER))
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,
GValue *value,