[gimp/wip/animation: 167/197] plug-ins: recreate the camera when cleaned-up.
- From: Jehan Pagès <jehanp src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp/wip/animation: 167/197] plug-ins: recreate the camera when cleaned-up.
- Date: Sat, 7 Oct 2017 03:12:28 +0000 (UTC)
commit 646ca41bcd0b610d8efbaa00e8857a0a0960dd5a
Author: Jehan <jehan girinstud io>
Date: Mon Jun 26 14:02:58 2017 +0200
plug-ins: recreate the camera when cleaned-up.
animation_cel_animation_reset_defaults() free most memory. The camera
has to be recreated as well.
plug-ins/animation-play/core/animation-camera.c | 3 ++-
.../animation-play/core/animation-celanimation.c | 1 +
2 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/plug-ins/animation-play/core/animation-camera.c b/plug-ins/animation-play/core/animation-camera.c
index f31c10a..b42a264 100644
--- a/plug-ins/animation-play/core/animation-camera.c
+++ b/plug-ins/animation-play/core/animation-camera.c
@@ -147,7 +147,8 @@ animation_camera_class_init (AnimationCameraClass *klass)
g_param_spec_object ("animation",
NULL, NULL,
ANIMATION_TYPE_ANIMATION,
- G_PARAM_READWRITE));
+ G_PARAM_READWRITE |
+ G_PARAM_CONSTRUCT_ONLY));
g_type_class_add_private (klass, sizeof (AnimationCameraPrivate));
}
diff --git a/plug-ins/animation-play/core/animation-celanimation.c
b/plug-ins/animation-play/core/animation-celanimation.c
index b7a5d70..00bdeb8 100644
--- a/plug-ins/animation-play/core/animation-celanimation.c
+++ b/plug-ins/animation-play/core/animation-celanimation.c
@@ -721,6 +721,7 @@ animation_cel_animation_reset_defaults (Animation *animation)
priv = ANIMATION_CEL_ANIMATION (animation)->priv;
animation_cel_animation_cleanup (ANIMATION_CEL_ANIMATION (animation));
+ priv->camera = animation_camera_new (animation);
/* Purely arbitrary value. User will anyway change it to suit one's needs. */
priv->duration = 240;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]