[glide] Theme preview actor paints white rectangle now...just until we get the new chooser going
- From: Robert Carr <racarr src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glide] Theme preview actor paints white rectangle now...just until we get the new chooser going
- Date: Sat, 5 Jun 2010 22:30:06 +0000 (UTC)
commit 9e50a80cb1b2ffe38b2cbbbaf80acbec7172ebe3
Author: Robert Carr <racarr Valentine localdomain>
Date: Sat Jun 5 16:42:28 2010 -0400
Theme preview actor paints white rectangle now...just until we get the new chooser going
libglide/glide-theme-preview-actor-priv.h | 2 ++
libglide/glide-theme-preview-actor.c | 12 ++++++++++++
2 files changed, 14 insertions(+), 0 deletions(-)
---
diff --git a/libglide/glide-theme-preview-actor-priv.h b/libglide/glide-theme-preview-actor-priv.h
index abb186b..56f7177 100644
--- a/libglide/glide-theme-preview-actor-priv.h
+++ b/libglide/glide-theme-preview-actor-priv.h
@@ -27,6 +27,8 @@ G_BEGIN_DECLS
struct _GlideThemePreviewActorPrivate
{
GlideTheme *theme;
+
+ ClutterActor *preview_texture;
};
G_END_DECLS
diff --git a/libglide/glide-theme-preview-actor.c b/libglide/glide-theme-preview-actor.c
index 37d5f3a..0157976 100644
--- a/libglide/glide-theme-preview-actor.c
+++ b/libglide/glide-theme-preview-actor.c
@@ -82,13 +82,25 @@ glide_theme_preview_actor_set_property (GObject *object,
static void
glide_theme_preview_actor_init (GlideThemePreviewActor *preview)
{
+ cairo_t *cr;
preview->priv = GLIDE_THEME_PREVIEW_ACTOR_GET_PRIVATE (preview);
+
+ preview->priv->preview_texture = clutter_cairo_texture_new (100, 100);
+
+ clutter_container_add_actor (CLUTTER_CONTAINER (preview), preview->priv->preview_texture);
+ clutter_actor_set_position (preview->priv->preview_texture, 0, 0);
+
+ cr = clutter_cairo_texture_create (CLUTTER_CAIRO_TEXTURE (preview->priv->preview_texture));
+ cairo_set_source_rgba (cr, 1, 1, 1, 1);
+ cairo_paint (cr);
+ cairo_destroy (cr);
}
static void
glide_theme_preview_actor_class_init (GlideThemePreviewActorClass *klass)
{
GObjectClass *object_class = G_OBJECT_CLASS (klass);
+ ClutterActorClass *actor_class = CLUTTER_ACTOR_CLASS (klass);
object_class->finalize = glide_theme_preview_actor_finalize;
object_class->get_property = glide_theme_preview_actor_get_property;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]