mirror of
https://github.com/brl/mutter.git
synced 2024-12-24 12:02:04 +00:00
Bug 1137 - Setting the anchor point does not trigger a re-paint
* clutter/clutter-actor.c (clutter_actor_set_property): When changing the anchor point properties, use set_anchor_pointu instead of changing the value directly so that a redraw will be queued. (clutter_actor_set_anchor_pointu): Queue a redraw when the anchor point is changed. Thanks to Johan Bilien.
This commit is contained in:
parent
0515ee22c2
commit
b83470366c
11
ChangeLog
11
ChangeLog
@ -1,3 +1,14 @@
|
|||||||
|
2008-09-10 Neil Roberts <neil@o-hand.com>
|
||||||
|
|
||||||
|
Bug 1137 - Setting the anchor point does not trigger a re-paint
|
||||||
|
|
||||||
|
* clutter/clutter-actor.c (clutter_actor_set_property): When
|
||||||
|
changing the anchor point properties, use set_anchor_pointu
|
||||||
|
instead of changing the value directly so that a redraw will be
|
||||||
|
queued.
|
||||||
|
(clutter_actor_set_anchor_pointu): Queue a redraw when the anchor
|
||||||
|
point is changed. Thanks to Johan Bilien.
|
||||||
|
|
||||||
2008-08-27 Emmanuele Bassi <ebassi@openedhand.com>
|
2008-08-27 Emmanuele Bassi <ebassi@openedhand.com>
|
||||||
|
|
||||||
Bug 1082 - Texture bitmap is destroyed in wrong way
|
Bug 1082 - Texture bitmap is destroyed in wrong way
|
||||||
|
@ -1708,10 +1708,20 @@ clutter_actor_set_property (GObject *object,
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case PROP_ANCHOR_X:
|
case PROP_ANCHOR_X:
|
||||||
priv->anchor_x = CLUTTER_UNITS_FROM_DEVICE (g_value_get_int (value));
|
{
|
||||||
|
int anchor_x = g_value_get_int (value);
|
||||||
|
clutter_actor_set_anchor_pointu (actor,
|
||||||
|
CLUTTER_UNITS_FROM_DEVICE (anchor_x),
|
||||||
|
priv->anchor_y);
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case PROP_ANCHOR_Y:
|
case PROP_ANCHOR_Y:
|
||||||
priv->anchor_y = CLUTTER_UNITS_FROM_DEVICE (g_value_get_int (value));
|
{
|
||||||
|
int anchor_y = g_value_get_int (value);
|
||||||
|
clutter_actor_set_anchor_pointu (actor,
|
||||||
|
priv->anchor_x,
|
||||||
|
CLUTTER_UNITS_FROM_DEVICE (anchor_y));
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case PROP_SHOW_ON_SET_PARENT:
|
case PROP_SHOW_ON_SET_PARENT:
|
||||||
priv->show_on_set_parent = g_value_get_boolean (value);
|
priv->show_on_set_parent = g_value_get_boolean (value);
|
||||||
@ -6155,6 +6165,7 @@ clutter_actor_set_anchor_pointu (ClutterActor *self,
|
|||||||
ClutterUnit anchor_y)
|
ClutterUnit anchor_y)
|
||||||
{
|
{
|
||||||
ClutterActorPrivate *priv;
|
ClutterActorPrivate *priv;
|
||||||
|
gboolean changed = FALSE;
|
||||||
|
|
||||||
g_return_if_fail (CLUTTER_IS_ACTOR (self));
|
g_return_if_fail (CLUTTER_IS_ACTOR (self));
|
||||||
|
|
||||||
@ -6166,15 +6177,20 @@ clutter_actor_set_anchor_pointu (ClutterActor *self,
|
|||||||
{
|
{
|
||||||
priv->anchor_x = anchor_x;
|
priv->anchor_x = anchor_x;
|
||||||
g_object_notify (G_OBJECT (self), "anchor-x");
|
g_object_notify (G_OBJECT (self), "anchor-x");
|
||||||
|
changed = TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (priv->anchor_y != anchor_y)
|
if (priv->anchor_y != anchor_y)
|
||||||
{
|
{
|
||||||
priv->anchor_y = anchor_y;
|
priv->anchor_y = anchor_y;
|
||||||
g_object_notify (G_OBJECT (self), "anchor-y");
|
g_object_notify (G_OBJECT (self), "anchor-y");
|
||||||
|
changed = TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
g_object_thaw_notify (G_OBJECT (self));
|
g_object_thaw_notify (G_OBJECT (self));
|
||||||
|
|
||||||
|
if (changed && CLUTTER_ACTOR_IS_VISIBLE (self))
|
||||||
|
clutter_actor_queue_redraw (self);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user