[clutter/clutter-1.6] actor: Avoid queueing redraws during destruction



commit 486e7a990605d6b825342eb91421969008f55e2f
Author: Emmanuele Bassi <ebassi linux intel com>
Date:   Tue Jun 7 14:25:17 2011 +0100

    actor: Avoid queueing redraws during destruction
    
    If an actor or the stage to which it belongs are being destroyed then
    there is no point in queueing a redraw that will not be seen anyway.
    Bailing out early also avoids the case in which a redraw is queued
    during destruction wil cause redraw entries will be added to the Stage,
    which will take references on it and cause the Stage never to be
    finalized.
    
    http://bugzilla.clutter-project.org/show_bug.cgi?id=2652
    (cherry-picked from commit 19c986c0c6e0aa08ae76ab7d992fbf70ae5e44a0)
    
    Signed-off-by: Emmanuele Bassi <ebassi linux intel com>

 clutter/clutter-actor.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/clutter/clutter-actor.c b/clutter/clutter-actor.c
index 1d36e6f..5843e1d 100644
--- a/clutter/clutter-actor.c
+++ b/clutter/clutter-actor.c
@@ -5125,7 +5125,7 @@ clutter_actor_queue_redraw (ClutterActor *self)
 
   /* Ignore queuing a redraw for actors not descended from a stage */
   stage = _clutter_actor_get_stage_internal (self);
-  if (stage == NULL)
+  if (stage == NULL || CLUTTER_ACTOR_IN_DESTRUCTION (stage))
     return;
 
   self->priv->queue_redraw_entry =



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]