[libdazzle] animation: add some warnings
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libdazzle] animation: add some warnings
- Date: Thu, 14 Jun 2018 10:43:15 +0000 (UTC)
commit 221604bccad327c2c1ef004bf118ac58dd9cc037
Author: Christian Hergert <chergert redhat com>
Date: Thu Jun 14 03:42:59 2018 -0700
animation: add some warnings
I'd like to make sure we've successfully tracked down a weird error, so
adding this warning in case we find anything new.
src/animation/dzl-animation.c | 6 ++++++
1 file changed, 6 insertions(+)
---
diff --git a/src/animation/dzl-animation.c b/src/animation/dzl-animation.c
index 629f679..745aafd 100644
--- a/src/animation/dzl-animation.c
+++ b/src/animation/dzl-animation.c
@@ -63,6 +63,7 @@ struct _DzlAnimation
GdkFrameClock *frame_clock; /* An optional frame-clock for sync. */
GDestroyNotify notify; /* Notify callback */
gpointer notify_data; /* Data for notify */
+ guint stop_called : 1;
};
G_DEFINE_TYPE (DzlAnimation, dzl_animation, G_TYPE_INITIALLY_UNOWNED)
@@ -687,6 +688,11 @@ dzl_animation_stop (DzlAnimation *animation)
if (animation == NULL)
return;
+ g_return_if_fail (DZL_IS_ANIMATION (animation));
+ g_return_if_fail (animation->stop_called == FALSE);
+
+ animation->stop_called = TRUE;
+
if (animation->tween_handler)
{
if (animation->frame_clock)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]