diff options
author | Jiří Techet <techet@gmail.com> | 2011-03-24 23:37:18 +0100 |
---|---|---|
committer | Jiří Techet <techet@gmail.com> | 2011-03-24 23:37:18 +0100 |
commit | 8634c7e6c41ad7e6f1c240a6e472022c7d9e4a2d (patch) | |
tree | 83e3f553d1cfb3dd908dc5091cbeacafa5e52e99 | |
parent | e081e968b42bf015d31a903a1281b1887dba374c (diff) | |
download | libchamplain-8634c7e6c41ad7e6f1c240a6e472022c7d9e4a2d.tar.gz |
Make custom implementation of pick for ChamplainPoint
-rw-r--r-- | champlain/champlain-point.c | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/champlain/champlain-point.c b/champlain/champlain-point.c index dae1f61..3da237b 100644 --- a/champlain/champlain-point.c +++ b/champlain/champlain-point.c @@ -139,10 +139,19 @@ pick (ClutterActor *self, const ClutterColor *color) { ChamplainPointPrivate *priv = GET_PRIVATE (self); + gdouble radius = priv->size / 2.0; - CLUTTER_ACTOR_CLASS (champlain_point_parent_class)->pick (self, color); + cogl_path_new (); - clutter_actor_paint (CLUTTER_ACTOR (priv->point_actor)); + cogl_set_source_color4ub (color->red, + color->green, + color->blue, + color->alpha); + + cogl_path_move_to (radius, radius); + cogl_path_arc (radius, radius, radius, radius, 0, 360.0); + cogl_path_close (); + cogl_path_fill (); } |