diff options
author | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2016-08-20 15:11:08 +0200 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2016-08-20 15:11:08 +0200 |
commit | cb612a12b952e349b96d427645aaeb55d15f509a (patch) | |
tree | f29298f41d2a7ea2a976616243aca64c2c2547ce /src/slideshow/TransitionEffects.c | |
parent | e7be93745e4a2ff3aa255227bef7b9d3b733aafa (diff) | |
parent | 143bfc9f801c84428074312d661f8e08803df83b (diff) |
Merge tag 'upstream/0.23.5'
Upstream version 0.23.5
Diffstat (limited to 'src/slideshow/TransitionEffects.c')
-rw-r--r-- | src/slideshow/TransitionEffects.c | 2658 |
1 files changed, 2658 insertions, 0 deletions
diff --git a/src/slideshow/TransitionEffects.c b/src/slideshow/TransitionEffects.c new file mode 100644 index 0000000..292187e --- /dev/null +++ b/src/slideshow/TransitionEffects.c @@ -0,0 +1,2658 @@ +/* TransitionEffects.c generated by valac 0.32.1, the Vala compiler + * generated from TransitionEffects.vala, do not modify */ + +/* Copyright 2010 Maxim Kartashev + * Copyright 2016 Software Freedom Conservancy Inc. + * + * This software is licensed under the GNU LGPL (version 2.1 or later). + * See the COPYING file in this distribution. + */ + +#include <glib.h> +#include <glib-object.h> +#include <gee.h> +#include <stdlib.h> +#include <string.h> +#include "shotwell-plugin-dev-1.0.h" +#include <glib/gi18n-lib.h> +#include <float.h> +#include <math.h> +#include <cairo.h> +#include <gobject/gvaluecollector.h> + + +#define TYPE_TRANSITION_EFFECTS_MANAGER (transition_effects_manager_get_type ()) +#define TRANSITION_EFFECTS_MANAGER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_TRANSITION_EFFECTS_MANAGER, TransitionEffectsManager)) +#define TRANSITION_EFFECTS_MANAGER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_TRANSITION_EFFECTS_MANAGER, TransitionEffectsManagerClass)) +#define IS_TRANSITION_EFFECTS_MANAGER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_TRANSITION_EFFECTS_MANAGER)) +#define IS_TRANSITION_EFFECTS_MANAGER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_TRANSITION_EFFECTS_MANAGER)) +#define TRANSITION_EFFECTS_MANAGER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_TRANSITION_EFFECTS_MANAGER, TransitionEffectsManagerClass)) + +typedef struct _TransitionEffectsManager TransitionEffectsManager; +typedef struct _TransitionEffectsManagerClass TransitionEffectsManagerClass; +typedef struct _TransitionEffectsManagerPrivate TransitionEffectsManagerPrivate; + +#define PLUGINS_TYPE_NOTIFIER (plugins_notifier_get_type ()) +#define PLUGINS_NOTIFIER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), PLUGINS_TYPE_NOTIFIER, PluginsNotifier)) +#define PLUGINS_NOTIFIER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), PLUGINS_TYPE_NOTIFIER, PluginsNotifierClass)) +#define PLUGINS_IS_NOTIFIER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), PLUGINS_TYPE_NOTIFIER)) +#define PLUGINS_IS_NOTIFIER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), PLUGINS_TYPE_NOTIFIER)) +#define PLUGINS_NOTIFIER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), PLUGINS_TYPE_NOTIFIER, PluginsNotifierClass)) + +typedef struct _PluginsNotifier PluginsNotifier; +typedef struct _PluginsNotifierClass PluginsNotifierClass; +#define _plugins_notifier_unref0(var) ((var == NULL) ? NULL : (var = (plugins_notifier_unref (var), NULL))) +#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL))) + +#define TYPE_NULL_TRANSITION_DESCRIPTOR (null_transition_descriptor_get_type ()) +#define NULL_TRANSITION_DESCRIPTOR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_NULL_TRANSITION_DESCRIPTOR, NullTransitionDescriptor)) +#define NULL_TRANSITION_DESCRIPTOR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_NULL_TRANSITION_DESCRIPTOR, NullTransitionDescriptorClass)) +#define IS_NULL_TRANSITION_DESCRIPTOR(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_NULL_TRANSITION_DESCRIPTOR)) +#define IS_NULL_TRANSITION_DESCRIPTOR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_NULL_TRANSITION_DESCRIPTOR)) +#define NULL_TRANSITION_DESCRIPTOR_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_NULL_TRANSITION_DESCRIPTOR, NullTransitionDescriptorClass)) + +typedef struct _NullTransitionDescriptor NullTransitionDescriptor; +typedef struct _NullTransitionDescriptorClass NullTransitionDescriptorClass; + +#define TYPE_RANDOM_EFFECT_DESCRIPTOR (random_effect_descriptor_get_type ()) +#define RANDOM_EFFECT_DESCRIPTOR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_RANDOM_EFFECT_DESCRIPTOR, RandomEffectDescriptor)) +#define RANDOM_EFFECT_DESCRIPTOR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_RANDOM_EFFECT_DESCRIPTOR, RandomEffectDescriptorClass)) +#define IS_RANDOM_EFFECT_DESCRIPTOR(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_RANDOM_EFFECT_DESCRIPTOR)) +#define IS_RANDOM_EFFECT_DESCRIPTOR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_RANDOM_EFFECT_DESCRIPTOR)) +#define RANDOM_EFFECT_DESCRIPTOR_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_RANDOM_EFFECT_DESCRIPTOR, RandomEffectDescriptorClass)) + +typedef struct _RandomEffectDescriptor RandomEffectDescriptor; +typedef struct _RandomEffectDescriptorClass RandomEffectDescriptorClass; +#define _g_free0(var) (var = (g_free (var), NULL)) +#define _transition_effects_manager_unref0(var) ((var == NULL) ? NULL : (var = (transition_effects_manager_unref (var), NULL))) + +#define TYPE_TRANSITION_CLOCK (transition_clock_get_type ()) +#define TRANSITION_CLOCK(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_TRANSITION_CLOCK, TransitionClock)) +#define TRANSITION_CLOCK_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_TRANSITION_CLOCK, TransitionClockClass)) +#define IS_TRANSITION_CLOCK(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_TRANSITION_CLOCK)) +#define IS_TRANSITION_CLOCK_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_TRANSITION_CLOCK)) +#define TRANSITION_CLOCK_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_TRANSITION_CLOCK, TransitionClockClass)) + +typedef struct _TransitionClock TransitionClock; +typedef struct _TransitionClockClass TransitionClockClass; +#define _transition_clock_unref0(var) ((var == NULL) ? NULL : (var = (transition_clock_unref (var), NULL))) +typedef struct _ParamSpecTransitionEffectsManager ParamSpecTransitionEffectsManager; +typedef struct _TransitionClockPrivate TransitionClockPrivate; + +#define TYPE_OP_TIMER (op_timer_get_type ()) +#define OP_TIMER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_OP_TIMER, OpTimer)) +#define OP_TIMER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_OP_TIMER, OpTimerClass)) +#define IS_OP_TIMER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_OP_TIMER)) +#define IS_OP_TIMER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_OP_TIMER)) +#define OP_TIMER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_OP_TIMER, OpTimerClass)) + +typedef struct _OpTimer OpTimer; +typedef struct _OpTimerClass OpTimerClass; +#define _op_timer_unref0(var) ((var == NULL) ? NULL : (var = (op_timer_unref (var), NULL))) + +#define PLUGINS_TYPE_STANDARD_HOST_INTERFACE (plugins_standard_host_interface_get_type ()) +#define PLUGINS_STANDARD_HOST_INTERFACE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), PLUGINS_TYPE_STANDARD_HOST_INTERFACE, PluginsStandardHostInterface)) +#define PLUGINS_STANDARD_HOST_INTERFACE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), PLUGINS_TYPE_STANDARD_HOST_INTERFACE, PluginsStandardHostInterfaceClass)) +#define PLUGINS_IS_STANDARD_HOST_INTERFACE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), PLUGINS_TYPE_STANDARD_HOST_INTERFACE)) +#define PLUGINS_IS_STANDARD_HOST_INTERFACE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), PLUGINS_TYPE_STANDARD_HOST_INTERFACE)) +#define PLUGINS_STANDARD_HOST_INTERFACE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), PLUGINS_TYPE_STANDARD_HOST_INTERFACE, PluginsStandardHostInterfaceClass)) + +typedef struct _PluginsStandardHostInterface PluginsStandardHostInterface; +typedef struct _PluginsStandardHostInterfaceClass PluginsStandardHostInterfaceClass; +typedef struct _ParamSpecTransitionClock ParamSpecTransitionClock; +typedef struct _NullTransitionDescriptorPrivate NullTransitionDescriptorPrivate; + +#define TYPE_NULL_EFFECT (null_effect_get_type ()) +#define NULL_EFFECT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_NULL_EFFECT, NullEffect)) +#define NULL_EFFECT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_NULL_EFFECT, NullEffectClass)) +#define IS_NULL_EFFECT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_NULL_EFFECT)) +#define IS_NULL_EFFECT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_NULL_EFFECT)) +#define NULL_EFFECT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_NULL_EFFECT, NullEffectClass)) + +typedef struct _NullEffect NullEffect; +typedef struct _NullEffectClass NullEffectClass; +typedef struct _NullEffectPrivate NullEffectPrivate; +typedef struct _RandomEffectDescriptorPrivate RandomEffectDescriptorPrivate; +#define _vala_assert(expr, msg) if G_LIKELY (expr) ; else g_assertion_message_expr (G_LOG_DOMAIN, __FILE__, __LINE__, G_STRFUNC, msg); +#define _vala_return_if_fail(expr, msg) if G_LIKELY (expr) ; else { g_return_if_fail_warning (G_LOG_DOMAIN, G_STRFUNC, msg); return; } +#define _vala_return_val_if_fail(expr, msg, val) if G_LIKELY (expr) ; else { g_return_if_fail_warning (G_LOG_DOMAIN, G_STRFUNC, msg); return val; } +#define _vala_warn_if_fail(expr, msg) if G_LIKELY (expr) ; else g_warn_message (G_LOG_DOMAIN, __FILE__, __LINE__, G_STRFUNC, msg); + +struct _TransitionEffectsManager { + GTypeInstance parent_instance; + volatile int ref_count; + TransitionEffectsManagerPrivate * priv; +}; + +struct _TransitionEffectsManagerClass { + GTypeClass parent_class; + void (*finalize) (TransitionEffectsManager *self); +}; + +struct _TransitionEffectsManagerPrivate { + GeeMap* effects; + SpitTransitionsDescriptor* null_descriptor; + SpitTransitionsDescriptor* random_descriptor; +}; + +struct _ParamSpecTransitionEffectsManager { + GParamSpec parent_instance; +}; + +struct _TransitionClock { + GTypeInstance parent_instance; + volatile int ref_count; + TransitionClockPrivate * priv; +}; + +struct _TransitionClockClass { + GTypeClass parent_class; + void (*finalize) (TransitionClock *self); +}; + +typedef void (*TransitionClockRepaintCallback) (void* user_data); +struct _TransitionClockPrivate { + SpitTransitionsDescriptor* desc; + SpitTransitionsEffect* effect; + gint desired_fps; + gint min_fps; + gint current_fps; + OpTimer* paint_timer; + SpitTransitionsVisuals* visuals; + SpitTransitionsMotion* motion; + TransitionClockRepaintCallback repaint; + gpointer repaint_target; + guint timer_id; + gulong time_started; + gint frame_number; + gboolean cancelled; +}; + +struct _ParamSpecTransitionClock { + GParamSpec parent_instance; +}; + +struct _NullTransitionDescriptor { + GObject parent_instance; + NullTransitionDescriptorPrivate * priv; +}; + +struct _NullTransitionDescriptorClass { + GObjectClass parent_class; +}; + +struct _NullEffect { + GObject parent_instance; + NullEffectPrivate * priv; +}; + +struct _NullEffectClass { + GObjectClass parent_class; +}; + +struct _RandomEffectDescriptor { + GObject parent_instance; + RandomEffectDescriptorPrivate * priv; +}; + +struct _RandomEffectDescriptorClass { + GObjectClass parent_class; +}; + + +static gpointer transition_effects_manager_parent_class = NULL; +static TransitionEffectsManager* transition_effects_manager_instance; +static TransitionEffectsManager* transition_effects_manager_instance = NULL; +static gpointer transition_clock_parent_class = NULL; +static gpointer null_transition_descriptor_parent_class = NULL; +static SpitPluggableIface* null_transition_descriptor_spit_pluggable_parent_iface = NULL; +static SpitTransitionsDescriptorIface* null_transition_descriptor_spit_transitions_descriptor_parent_iface = NULL; +static gpointer null_effect_parent_class = NULL; +static SpitTransitionsEffectIface* null_effect_spit_transitions_effect_parent_iface = NULL; +static gpointer random_effect_descriptor_parent_class = NULL; +static SpitPluggableIface* random_effect_descriptor_spit_pluggable_parent_iface = NULL; +static SpitTransitionsDescriptorIface* random_effect_descriptor_spit_transitions_descriptor_parent_iface = NULL; + +gpointer transition_effects_manager_ref (gpointer instance); +void transition_effects_manager_unref (gpointer instance); +GParamSpec* param_spec_transition_effects_manager (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); +void value_set_transition_effects_manager (GValue* value, gpointer v_object); +void value_take_transition_effects_manager (GValue* value, gpointer v_object); +gpointer value_get_transition_effects_manager (const GValue* value); +GType transition_effects_manager_get_type (void) G_GNUC_CONST; +#define TRANSITION_EFFECTS_MANAGER_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_TRANSITION_EFFECTS_MANAGER, TransitionEffectsManagerPrivate)) +enum { + TRANSITION_EFFECTS_MANAGER_DUMMY_PROPERTY +}; +gpointer plugins_notifier_ref (gpointer instance); +void plugins_notifier_unref (gpointer instance); +GParamSpec* plugins_param_spec_notifier (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); +void plugins_value_set_notifier (GValue* value, gpointer v_object); +void plugins_value_take_notifier (GValue* value, gpointer v_object); +gpointer plugins_value_get_notifier (const GValue* value); +GType plugins_notifier_get_type (void) G_GNUC_CONST; +PluginsNotifier* plugins_notifier_get_instance (void); +static void transition_effects_manager_load_transitions (TransitionEffectsManager* self); +static void _transition_effects_manager_load_transitions_plugins_notifier_pluggable_activation (PluginsNotifier* _sender, SpitPluggable* pluggable, gboolean enabled, gpointer self); +NullTransitionDescriptor* null_transition_descriptor_new (void); +NullTransitionDescriptor* null_transition_descriptor_construct (GType object_type); +GType null_transition_descriptor_get_type (void) G_GNUC_CONST; +RandomEffectDescriptor* random_effect_descriptor_new (void); +RandomEffectDescriptor* random_effect_descriptor_construct (GType object_type); +GType random_effect_descriptor_get_type (void) G_GNUC_CONST; +#define NULL_TRANSITION_DESCRIPTOR_EFFECT_ID "org.yorba.shotwell.transitions.null" +#define TRANSITION_EFFECTS_MANAGER_NULL_EFFECT_ID NULL_TRANSITION_DESCRIPTOR_EFFECT_ID +#define RANDOM_EFFECT_DESCRIPTOR_EFFECT_ID "org.yorba.shotwell.transitions.random" +#define TRANSITION_EFFECTS_MANAGER_RANDOM_EFFECT_ID RANDOM_EFFECT_DESCRIPTOR_EFFECT_ID +static TransitionEffectsManager* transition_effects_manager_new (void); +static TransitionEffectsManager* transition_effects_manager_construct (GType object_type); +GeeCollection* plugins_get_pluggables_for_type (GType type, GCompareDataFunc compare_func, void* compare_func_target, GDestroyNotify compare_func_target_destroy_notify, gboolean include_disabled); +gchar* plugins_get_pluggable_module_id (SpitPluggable* needle); +void transition_effects_manager_init (void); +void transition_effects_manager_terminate (void); +TransitionEffectsManager* transition_effects_manager_get_instance (void); +GeeCollection* transition_effects_manager_get_effect_ids (TransitionEffectsManager* self); +GeeCollection* transition_effects_manager_get_effect_names (TransitionEffectsManager* self, GCompareDataFunc comparator, void* comparator_target, GDestroyNotify comparator_target_destroy_notify); +gchar* transition_effects_manager_get_id_for_effect_name (TransitionEffectsManager* self, const gchar* effect_name); +SpitTransitionsDescriptor* transition_effects_manager_get_effect_descriptor (TransitionEffectsManager* self, const gchar* effect_id); +gchar* transition_effects_manager_get_effect_name (TransitionEffectsManager* self, const gchar* effect_id); +SpitTransitionsDescriptor* transition_effects_manager_get_null_descriptor (TransitionEffectsManager* self); +gpointer transition_clock_ref (gpointer instance); +void transition_clock_unref (gpointer instance); +GParamSpec* param_spec_transition_clock (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); +void value_set_transition_clock (GValue* value, gpointer v_object); +void value_take_transition_clock (GValue* value, gpointer v_object); +gpointer value_get_transition_clock (const GValue* value); +GType transition_clock_get_type (void) G_GNUC_CONST; +TransitionClock* transition_effects_manager_create_transition_clock (TransitionEffectsManager* self, const gchar* effect_id); +TransitionClock* transition_clock_new (SpitTransitionsDescriptor* desc); +TransitionClock* transition_clock_construct (GType object_type, SpitTransitionsDescriptor* desc); +TransitionClock* transition_effects_manager_create_null_transition_clock (TransitionEffectsManager* self); +static void transition_effects_manager_finalize (TransitionEffectsManager* obj); +gpointer op_timer_ref (gpointer instance); +void op_timer_unref (gpointer instance); +GParamSpec* param_spec_op_timer (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags); +void value_set_op_timer (GValue* value, gpointer v_object); +void value_take_op_timer (GValue* value, gpointer v_object); +gpointer value_get_op_timer (const GValue* value); +GType op_timer_get_type (void) G_GNUC_CONST; +#define TRANSITION_CLOCK_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_TRANSITION_CLOCK, TransitionClockPrivate)) +enum { + TRANSITION_CLOCK_DUMMY_PROPERTY +}; +static void transition_clock_cancel_timer (TransitionClock* self); +gchar* op_timer_to_string (OpTimer* self); +PluginsStandardHostInterface* plugins_standard_host_interface_new (SpitPluggable* pluggable, const gchar* config_domain); +PluginsStandardHostInterface* plugins_standard_host_interface_construct (GType object_type, SpitPluggable* pluggable, const gchar* config_domain); +GType plugins_standard_host_interface_get_type (void) G_GNUC_CONST; +OpTimer* op_timer_new (const gchar* name); +OpTimer* op_timer_construct (GType object_type, const gchar* name); +gboolean transition_clock_is_in_progress (TransitionClock* self); +void transition_clock_start (TransitionClock* self, SpitTransitionsVisuals* visuals, SpitTransitionsDirection direction, gint duration_msec, TransitionClockRepaintCallback repaint, void* repaint_target); +static void transition_clock_reset (TransitionClock* self); +gulong now_ms (void); +static gboolean transition_clock_tick (TransitionClock* self); +static gboolean _transition_clock_tick_gsource_func (gpointer self); +static gboolean transition_clock_is_fps_ok (TransitionClock* self); +void transition_clock_cancel (TransitionClock* self); +gboolean transition_clock_paint (TransitionClock* self, cairo_t* ctx, gint width, gint height); +void op_timer_start (OpTimer* self); +void op_timer_stop (OpTimer* self); +static void transition_clock_finalize (TransitionClock* obj); +enum { + NULL_TRANSITION_DESCRIPTOR_DUMMY_PROPERTY +}; +static gint null_transition_descriptor_real_get_pluggable_interface (SpitPluggable* base, gint min_host_version, gint max_host_version); +static const gchar* null_transition_descriptor_real_get_id (SpitPluggable* base); +static const gchar* null_transition_descriptor_real_get_pluggable_name (SpitPluggable* base); +static void null_transition_descriptor_real_get_info (SpitPluggable* base, SpitPluggableInfo* info); +static void null_transition_descriptor_real_activation (SpitPluggable* base, gboolean enabled); +static SpitTransitionsEffect* null_transition_descriptor_real_create (SpitTransitionsDescriptor* base, SpitHostInterface* host); +NullEffect* null_effect_new (void); +NullEffect* null_effect_construct (GType object_type); +GType null_effect_get_type (void) G_GNUC_CONST; +enum { + NULL_EFFECT_DUMMY_PROPERTY +}; +static void null_effect_real_get_fps (SpitTransitionsEffect* base, gint* desired_fps, gint* min_fps); +static void null_effect_real_start (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion); +static gboolean null_effect_real_needs_clear_background (SpitTransitionsEffect* base); +static void null_effect_real_paint (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion, cairo_t* ctx, gint width, gint height, gint frame_number); +static void null_effect_real_advance (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion, gint frame_number); +static void null_effect_real_cancel (SpitTransitionsEffect* base); +enum { + RANDOM_EFFECT_DESCRIPTOR_DUMMY_PROPERTY +}; +static gint random_effect_descriptor_real_get_pluggable_interface (SpitPluggable* base, gint min_host_version, gint max_host_version); +static const gchar* random_effect_descriptor_real_get_id (SpitPluggable* base); +static const gchar* random_effect_descriptor_real_get_pluggable_name (SpitPluggable* base); +static void random_effect_descriptor_real_get_info (SpitPluggable* base, SpitPluggableInfo* info); +static void random_effect_descriptor_real_activation (SpitPluggable* base, gboolean enabled); +static SpitTransitionsEffect* random_effect_descriptor_real_create (SpitTransitionsDescriptor* base, SpitHostInterface* host); + + +static void _transition_effects_manager_load_transitions_plugins_notifier_pluggable_activation (PluginsNotifier* _sender, SpitPluggable* pluggable, gboolean enabled, gpointer self) { +#line 25 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_effects_manager_load_transitions ((TransitionEffectsManager*) self); +#line 338 "TransitionEffects.c" +} + + +static TransitionEffectsManager* transition_effects_manager_construct (GType object_type) { + TransitionEffectsManager* self = NULL; + PluginsNotifier* _tmp0_ = NULL; + PluginsNotifier* _tmp1_ = NULL; +#line 19 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = (TransitionEffectsManager*) g_type_create_instance (object_type); +#line 20 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_effects_manager_load_transitions (self); +#line 21 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = plugins_notifier_get_instance (); +#line 21 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = _tmp0_; +#line 21 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_signal_connect (_tmp1_, "pluggable-activation", (GCallback) _transition_effects_manager_load_transitions_plugins_notifier_pluggable_activation, self); +#line 21 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _plugins_notifier_unref0 (_tmp1_); +#line 19 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return self; +#line 360 "TransitionEffects.c" +} + + +static TransitionEffectsManager* transition_effects_manager_new (void) { +#line 19 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return transition_effects_manager_construct (TYPE_TRANSITION_EFFECTS_MANAGER); +#line 367 "TransitionEffects.c" +} + + +static gpointer _g_object_ref0 (gpointer self) { +#line 48 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return self ? g_object_ref (self) : NULL; +#line 374 "TransitionEffects.c" +} + + +static void transition_effects_manager_load_transitions (TransitionEffectsManager* self) { + GeeMap* _tmp0_ = NULL; + GeeMap* _tmp1_ = NULL; + SpitTransitionsDescriptor* _tmp2_ = NULL; + const gchar* _tmp3_ = NULL; + SpitTransitionsDescriptor* _tmp4_ = NULL; + GeeMap* _tmp5_ = NULL; + SpitTransitionsDescriptor* _tmp6_ = NULL; + const gchar* _tmp7_ = NULL; + SpitTransitionsDescriptor* _tmp8_ = NULL; + GeeCollection* pluggables = NULL; + GeeCollection* _tmp9_ = NULL; +#line 28 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (IS_TRANSITION_EFFECTS_MANAGER (self)); +#line 29 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = self->priv->effects; +#line 29 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + gee_map_clear (_tmp0_); +#line 32 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = self->priv->effects; +#line 32 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp2_ = self->priv->null_descriptor; +#line 32 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp3_ = spit_pluggable_get_id (G_TYPE_CHECK_INSTANCE_CAST (_tmp2_, SPIT_TYPE_PLUGGABLE, SpitPluggable)); +#line 32 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp4_ = self->priv->null_descriptor; +#line 32 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + gee_map_set (_tmp1_, _tmp3_, _tmp4_); +#line 33 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp5_ = self->priv->effects; +#line 33 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp6_ = self->priv->random_descriptor; +#line 33 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp7_ = spit_pluggable_get_id (G_TYPE_CHECK_INSTANCE_CAST (_tmp6_, SPIT_TYPE_PLUGGABLE, SpitPluggable)); +#line 33 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp8_ = self->priv->random_descriptor; +#line 33 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + gee_map_set (_tmp5_, _tmp7_, _tmp8_); +#line 36 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp9_ = plugins_get_pluggables_for_type (SPIT_TRANSITIONS_TYPE_DESCRIPTOR, NULL, NULL, NULL, FALSE); +#line 36 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + pluggables = _tmp9_; +#line 420 "TransitionEffects.c" + { + GeeIterator* _pluggable_it = NULL; + GeeCollection* _tmp10_ = NULL; + GeeIterator* _tmp11_ = NULL; +#line 38 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp10_ = pluggables; +#line 38 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp11_ = gee_iterable_iterator (G_TYPE_CHECK_INSTANCE_CAST (_tmp10_, GEE_TYPE_ITERABLE, GeeIterable)); +#line 38 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _pluggable_it = _tmp11_; +#line 38 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + while (TRUE) { +#line 433 "TransitionEffects.c" + GeeIterator* _tmp12_ = NULL; + gboolean _tmp13_ = FALSE; + SpitPluggable* pluggable = NULL; + GeeIterator* _tmp14_ = NULL; + gpointer _tmp15_ = NULL; + gint pluggable_interface = 0; + SpitPluggable* _tmp16_ = NULL; + gint _tmp17_ = 0; + gint _tmp18_ = 0; + SpitTransitionsDescriptor* desc = NULL; + SpitPluggable* _tmp23_ = NULL; + SpitTransitionsDescriptor* _tmp24_ = NULL; + GeeMap* _tmp25_ = NULL; + SpitTransitionsDescriptor* _tmp26_ = NULL; + const gchar* _tmp27_ = NULL; + gboolean _tmp28_ = FALSE; +#line 38 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp12_ = _pluggable_it; +#line 38 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp13_ = gee_iterator_next (_tmp12_); +#line 38 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (!_tmp13_) { +#line 38 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + break; +#line 458 "TransitionEffects.c" + } +#line 38 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp14_ = _pluggable_it; +#line 38 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp15_ = gee_iterator_get (_tmp14_); +#line 38 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + pluggable = (SpitPluggable*) _tmp15_; +#line 39 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp16_ = pluggable; +#line 39 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp17_ = spit_pluggable_get_pluggable_interface (_tmp16_, SPIT_TRANSITIONS_CURRENT_INTERFACE, SPIT_TRANSITIONS_CURRENT_INTERFACE); +#line 39 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + pluggable_interface = _tmp17_; +#line 41 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp18_ = pluggable_interface; +#line 41 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (_tmp18_ != SPIT_TRANSITIONS_CURRENT_INTERFACE) { +#line 476 "TransitionEffects.c" + SpitPluggable* _tmp19_ = NULL; + gchar* _tmp20_ = NULL; + gchar* _tmp21_ = NULL; + gint _tmp22_ = 0; +#line 42 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp19_ = pluggable; +#line 42 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp20_ = plugins_get_pluggable_module_id (_tmp19_); +#line 42 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp21_ = _tmp20_; +#line 42 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp22_ = pluggable_interface; +#line 42 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_warning ("TransitionEffects.vala:42: Unable to load transitions plug-in %s: repo" \ +"rted interface %d", _tmp21_, _tmp22_); +#line 42 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_free0 (_tmp21_); +#line 45 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (pluggable); +#line 45 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + continue; +#line 497 "TransitionEffects.c" + } +#line 48 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp23_ = pluggable; +#line 48 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp24_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_CAST (_tmp23_, SPIT_TRANSITIONS_TYPE_DESCRIPTOR, SpitTransitionsDescriptor)); +#line 48 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + desc = _tmp24_; +#line 49 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp25_ = self->priv->effects; +#line 49 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp26_ = desc; +#line 49 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp27_ = spit_pluggable_get_id (G_TYPE_CHECK_INSTANCE_CAST (_tmp26_, SPIT_TYPE_PLUGGABLE, SpitPluggable)); +#line 49 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp28_ = gee_map_has_key (_tmp25_, _tmp27_); +#line 49 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (_tmp28_) { +#line 515 "TransitionEffects.c" + SpitTransitionsDescriptor* _tmp29_ = NULL; + const gchar* _tmp30_ = NULL; +#line 50 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp29_ = desc; +#line 50 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp30_ = spit_pluggable_get_id (G_TYPE_CHECK_INSTANCE_CAST (_tmp29_, SPIT_TYPE_PLUGGABLE, SpitPluggable)); +#line 50 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_warning ("TransitionEffects.vala:50: Multiple transitions loaded with same effec" \ +"t ID %s", _tmp30_); +#line 524 "TransitionEffects.c" + } else { + GeeMap* _tmp31_ = NULL; + SpitTransitionsDescriptor* _tmp32_ = NULL; + const gchar* _tmp33_ = NULL; + SpitTransitionsDescriptor* _tmp34_ = NULL; +#line 52 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp31_ = self->priv->effects; +#line 52 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp32_ = desc; +#line 52 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp33_ = spit_pluggable_get_id (G_TYPE_CHECK_INSTANCE_CAST (_tmp32_, SPIT_TYPE_PLUGGABLE, SpitPluggable)); +#line 52 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp34_ = desc; +#line 52 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + gee_map_set (_tmp31_, _tmp33_, _tmp34_); +#line 540 "TransitionEffects.c" + } +#line 38 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (desc); +#line 38 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (pluggable); +#line 546 "TransitionEffects.c" + } +#line 38 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (_pluggable_it); +#line 550 "TransitionEffects.c" + } +#line 28 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (pluggables); +#line 554 "TransitionEffects.c" +} + + +void transition_effects_manager_init (void) { + TransitionEffectsManager* _tmp0_ = NULL; +#line 57 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = transition_effects_manager_new (); +#line 57 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _transition_effects_manager_unref0 (transition_effects_manager_instance); +#line 57 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_effects_manager_instance = _tmp0_; +#line 566 "TransitionEffects.c" +} + + +void transition_effects_manager_terminate (void) { +#line 61 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _transition_effects_manager_unref0 (transition_effects_manager_instance); +#line 61 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_effects_manager_instance = NULL; +#line 575 "TransitionEffects.c" +} + + +static gpointer _transition_effects_manager_ref0 (gpointer self) { +#line 67 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return self ? transition_effects_manager_ref (self) : NULL; +#line 582 "TransitionEffects.c" +} + + +TransitionEffectsManager* transition_effects_manager_get_instance (void) { + TransitionEffectsManager* result = NULL; + TransitionEffectsManager* _tmp0_ = NULL; + TransitionEffectsManager* _tmp1_ = NULL; + TransitionEffectsManager* _tmp2_ = NULL; +#line 65 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = transition_effects_manager_instance; +#line 65 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _vala_assert (_tmp0_ != NULL, "instance != null"); +#line 67 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = transition_effects_manager_instance; +#line 67 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp2_ = _transition_effects_manager_ref0 (_tmp1_); +#line 67 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = _tmp2_; +#line 67 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 603 "TransitionEffects.c" +} + + +GeeCollection* transition_effects_manager_get_effect_ids (TransitionEffectsManager* self) { + GeeCollection* result = NULL; + GeeMap* _tmp0_ = NULL; + GeeSet* _tmp1_ = NULL; + GeeSet* _tmp2_ = NULL; +#line 70 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (IS_TRANSITION_EFFECTS_MANAGER (self), NULL); +#line 71 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = self->priv->effects; +#line 71 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = gee_map_get_keys (_tmp0_); +#line 71 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp2_ = _tmp1_; +#line 71 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = G_TYPE_CHECK_INSTANCE_CAST (_tmp2_, GEE_TYPE_COLLECTION, GeeCollection); +#line 71 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 624 "TransitionEffects.c" +} + + +GeeCollection* transition_effects_manager_get_effect_names (TransitionEffectsManager* self, GCompareDataFunc comparator, void* comparator_target, GDestroyNotify comparator_target_destroy_notify) { + GeeCollection* result = NULL; + GeeCollection* effect_names = NULL; + GCompareDataFunc _tmp0_ = NULL; + void* _tmp0__target = NULL; + GDestroyNotify _tmp0__target_destroy_notify = NULL; + GeeTreeSet* _tmp1_ = NULL; +#line 74 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (IS_TRANSITION_EFFECTS_MANAGER (self), NULL); +#line 75 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = comparator; +#line 75 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0__target = comparator_target; +#line 75 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0__target_destroy_notify = comparator_target_destroy_notify; +#line 75 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + comparator_target_destroy_notify = NULL; +#line 75 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = gee_tree_set_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, g_free, _tmp0_, _tmp0__target, _tmp0__target_destroy_notify); +#line 75 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + effect_names = G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, GEE_TYPE_COLLECTION, GeeCollection); +#line 649 "TransitionEffects.c" + { + GeeIterator* _desc_it = NULL; + GeeMap* _tmp2_ = NULL; + GeeCollection* _tmp3_ = NULL; + GeeCollection* _tmp4_ = NULL; + GeeCollection* _tmp5_ = NULL; + GeeIterator* _tmp6_ = NULL; + GeeIterator* _tmp7_ = NULL; +#line 76 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp2_ = self->priv->effects; +#line 76 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp3_ = gee_map_get_values (_tmp2_); +#line 76 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp4_ = _tmp3_; +#line 76 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp5_ = _tmp4_; +#line 76 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp6_ = gee_iterable_iterator (G_TYPE_CHECK_INSTANCE_CAST (_tmp5_, GEE_TYPE_ITERABLE, GeeIterable)); +#line 76 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp7_ = _tmp6_; +#line 76 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (_tmp5_); +#line 76 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _desc_it = _tmp7_; +#line 76 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + while (TRUE) { +#line 676 "TransitionEffects.c" + GeeIterator* _tmp8_ = NULL; + gboolean _tmp9_ = FALSE; + SpitTransitionsDescriptor* desc = NULL; + GeeIterator* _tmp10_ = NULL; + gpointer _tmp11_ = NULL; + GeeCollection* _tmp12_ = NULL; + SpitTransitionsDescriptor* _tmp13_ = NULL; + const gchar* _tmp14_ = NULL; +#line 76 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp8_ = _desc_it; +#line 76 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp9_ = gee_iterator_next (_tmp8_); +#line 76 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (!_tmp9_) { +#line 76 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + break; +#line 693 "TransitionEffects.c" + } +#line 76 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp10_ = _desc_it; +#line 76 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp11_ = gee_iterator_get (_tmp10_); +#line 76 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + desc = (SpitTransitionsDescriptor*) _tmp11_; +#line 77 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp12_ = effect_names; +#line 77 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp13_ = desc; +#line 77 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp14_ = spit_pluggable_get_pluggable_name (G_TYPE_CHECK_INSTANCE_CAST (_tmp13_, SPIT_TYPE_PLUGGABLE, SpitPluggable)); +#line 77 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + gee_collection_add (_tmp12_, _tmp14_); +#line 76 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (desc); +#line 711 "TransitionEffects.c" + } +#line 76 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (_desc_it); +#line 715 "TransitionEffects.c" + } +#line 79 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = effect_names; +#line 79 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + (comparator_target_destroy_notify == NULL) ? NULL : (comparator_target_destroy_notify (comparator_target), NULL); +#line 79 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + comparator = NULL; +#line 79 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + comparator_target = NULL; +#line 79 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + comparator_target_destroy_notify = NULL; +#line 79 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 729 "TransitionEffects.c" +} + + +gchar* transition_effects_manager_get_id_for_effect_name (TransitionEffectsManager* self, const gchar* effect_name) { + gchar* result = NULL; +#line 82 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (IS_TRANSITION_EFFECTS_MANAGER (self), NULL); +#line 82 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (effect_name != NULL, NULL); +#line 739 "TransitionEffects.c" + { + GeeIterator* _desc_it = NULL; + GeeMap* _tmp0_ = NULL; + GeeCollection* _tmp1_ = NULL; + GeeCollection* _tmp2_ = NULL; + GeeCollection* _tmp3_ = NULL; + GeeIterator* _tmp4_ = NULL; + GeeIterator* _tmp5_ = NULL; +#line 83 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = self->priv->effects; +#line 83 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = gee_map_get_values (_tmp0_); +#line 83 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp2_ = _tmp1_; +#line 83 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp3_ = _tmp2_; +#line 83 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp4_ = gee_iterable_iterator (G_TYPE_CHECK_INSTANCE_CAST (_tmp3_, GEE_TYPE_ITERABLE, GeeIterable)); +#line 83 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp5_ = _tmp4_; +#line 83 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (_tmp3_); +#line 83 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _desc_it = _tmp5_; +#line 83 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + while (TRUE) { +#line 766 "TransitionEffects.c" + GeeIterator* _tmp6_ = NULL; + gboolean _tmp7_ = FALSE; + SpitTransitionsDescriptor* desc = NULL; + GeeIterator* _tmp8_ = NULL; + gpointer _tmp9_ = NULL; + SpitTransitionsDescriptor* _tmp10_ = NULL; + const gchar* _tmp11_ = NULL; + const gchar* _tmp12_ = NULL; +#line 83 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp6_ = _desc_it; +#line 83 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp7_ = gee_iterator_next (_tmp6_); +#line 83 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (!_tmp7_) { +#line 83 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + break; +#line 783 "TransitionEffects.c" + } +#line 83 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp8_ = _desc_it; +#line 83 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp9_ = gee_iterator_get (_tmp8_); +#line 83 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + desc = (SpitTransitionsDescriptor*) _tmp9_; +#line 84 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp10_ = desc; +#line 84 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp11_ = spit_pluggable_get_pluggable_name (G_TYPE_CHECK_INSTANCE_CAST (_tmp10_, SPIT_TYPE_PLUGGABLE, SpitPluggable)); +#line 84 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp12_ = effect_name; +#line 84 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (g_strcmp0 (_tmp11_, _tmp12_) == 0) { +#line 799 "TransitionEffects.c" + SpitTransitionsDescriptor* _tmp13_ = NULL; + const gchar* _tmp14_ = NULL; + gchar* _tmp15_ = NULL; +#line 85 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp13_ = desc; +#line 85 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp14_ = spit_pluggable_get_id (G_TYPE_CHECK_INSTANCE_CAST (_tmp13_, SPIT_TYPE_PLUGGABLE, SpitPluggable)); +#line 85 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp15_ = g_strdup (_tmp14_); +#line 85 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = _tmp15_; +#line 85 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (desc); +#line 85 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (_desc_it); +#line 85 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 817 "TransitionEffects.c" + } +#line 83 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (desc); +#line 821 "TransitionEffects.c" + } +#line 83 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (_desc_it); +#line 825 "TransitionEffects.c" + } +#line 88 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = NULL; +#line 88 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 831 "TransitionEffects.c" +} + + +SpitTransitionsDescriptor* transition_effects_manager_get_effect_descriptor (TransitionEffectsManager* self, const gchar* effect_id) { + SpitTransitionsDescriptor* result = NULL; + GeeMap* _tmp0_ = NULL; + const gchar* _tmp1_ = NULL; + gpointer _tmp2_ = NULL; +#line 91 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (IS_TRANSITION_EFFECTS_MANAGER (self), NULL); +#line 91 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (effect_id != NULL, NULL); +#line 92 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = self->priv->effects; +#line 92 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = effect_id; +#line 92 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp2_ = gee_map_get (_tmp0_, _tmp1_); +#line 92 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = (SpitTransitionsDescriptor*) _tmp2_; +#line 92 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 854 "TransitionEffects.c" +} + + +gchar* transition_effects_manager_get_effect_name (TransitionEffectsManager* self, const gchar* effect_id) { + gchar* result = NULL; + SpitTransitionsDescriptor* desc = NULL; + const gchar* _tmp0_ = NULL; + SpitTransitionsDescriptor* _tmp1_ = NULL; + const gchar* _tmp2_ = NULL; + SpitTransitionsDescriptor* _tmp3_ = NULL; + gchar* _tmp7_ = NULL; +#line 95 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (IS_TRANSITION_EFFECTS_MANAGER (self), NULL); +#line 95 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (effect_id != NULL, NULL); +#line 96 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = effect_id; +#line 96 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = transition_effects_manager_get_effect_descriptor (self, _tmp0_); +#line 96 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + desc = _tmp1_; +#line 98 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp3_ = desc; +#line 98 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (_tmp3_ != NULL) { +#line 880 "TransitionEffects.c" + SpitTransitionsDescriptor* _tmp4_ = NULL; + const gchar* _tmp5_ = NULL; +#line 98 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp4_ = desc; +#line 98 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp5_ = spit_pluggable_get_pluggable_name (G_TYPE_CHECK_INSTANCE_CAST (_tmp4_, SPIT_TYPE_PLUGGABLE, SpitPluggable)); +#line 98 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp2_ = _tmp5_; +#line 889 "TransitionEffects.c" + } else { + const gchar* _tmp6_ = NULL; +#line 98 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp6_ = _ ("(None)"); +#line 98 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp2_ = _tmp6_; +#line 896 "TransitionEffects.c" + } +#line 98 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp7_ = g_strdup (_tmp2_); +#line 98 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = _tmp7_; +#line 98 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (desc); +#line 98 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 906 "TransitionEffects.c" +} + + +SpitTransitionsDescriptor* transition_effects_manager_get_null_descriptor (TransitionEffectsManager* self) { + SpitTransitionsDescriptor* result = NULL; + SpitTransitionsDescriptor* _tmp0_ = NULL; + SpitTransitionsDescriptor* _tmp1_ = NULL; +#line 101 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (IS_TRANSITION_EFFECTS_MANAGER (self), NULL); +#line 102 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = self->priv->null_descriptor; +#line 102 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = _g_object_ref0 (_tmp0_); +#line 102 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = _tmp1_; +#line 102 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 924 "TransitionEffects.c" +} + + +TransitionClock* transition_effects_manager_create_transition_clock (TransitionEffectsManager* self, const gchar* effect_id) { + TransitionClock* result = NULL; + SpitTransitionsDescriptor* desc = NULL; + const gchar* _tmp0_ = NULL; + SpitTransitionsDescriptor* _tmp1_ = NULL; + TransitionClock* _tmp2_ = NULL; + SpitTransitionsDescriptor* _tmp3_ = NULL; +#line 105 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (IS_TRANSITION_EFFECTS_MANAGER (self), NULL); +#line 105 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (effect_id != NULL, NULL); +#line 106 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = effect_id; +#line 106 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = transition_effects_manager_get_effect_descriptor (self, _tmp0_); +#line 106 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + desc = _tmp1_; +#line 108 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp3_ = desc; +#line 108 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (_tmp3_ != NULL) { +#line 949 "TransitionEffects.c" + SpitTransitionsDescriptor* _tmp4_ = NULL; + TransitionClock* _tmp5_ = NULL; +#line 108 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp4_ = desc; +#line 108 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp5_ = transition_clock_new (_tmp4_); +#line 108 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _transition_clock_unref0 (_tmp2_); +#line 108 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp2_ = _tmp5_; +#line 960 "TransitionEffects.c" + } else { +#line 108 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _transition_clock_unref0 (_tmp2_); +#line 108 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp2_ = NULL; +#line 966 "TransitionEffects.c" + } +#line 108 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = _tmp2_; +#line 108 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (desc); +#line 108 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 974 "TransitionEffects.c" +} + + +TransitionClock* transition_effects_manager_create_null_transition_clock (TransitionEffectsManager* self) { + TransitionClock* result = NULL; + SpitTransitionsDescriptor* _tmp0_ = NULL; + TransitionClock* _tmp1_ = NULL; +#line 111 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (IS_TRANSITION_EFFECTS_MANAGER (self), NULL); +#line 112 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = self->priv->null_descriptor; +#line 112 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = transition_clock_new (_tmp0_); +#line 112 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = _tmp1_; +#line 112 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 992 "TransitionEffects.c" +} + + +static void value_transition_effects_manager_init (GValue* value) { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + value->data[0].v_pointer = NULL; +#line 999 "TransitionEffects.c" +} + + +static void value_transition_effects_manager_free_value (GValue* value) { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (value->data[0].v_pointer) { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_effects_manager_unref (value->data[0].v_pointer); +#line 1008 "TransitionEffects.c" + } +} + + +static void value_transition_effects_manager_copy_value (const GValue* src_value, GValue* dest_value) { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (src_value->data[0].v_pointer) { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + dest_value->data[0].v_pointer = transition_effects_manager_ref (src_value->data[0].v_pointer); +#line 1018 "TransitionEffects.c" + } else { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + dest_value->data[0].v_pointer = NULL; +#line 1022 "TransitionEffects.c" + } +} + + +static gpointer value_transition_effects_manager_peek_pointer (const GValue* value) { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return value->data[0].v_pointer; +#line 1030 "TransitionEffects.c" +} + + +static gchar* value_transition_effects_manager_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (collect_values[0].v_pointer) { +#line 1037 "TransitionEffects.c" + TransitionEffectsManager* object; + object = collect_values[0].v_pointer; +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (object->parent_instance.g_class == NULL) { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); +#line 1044 "TransitionEffects.c" + } else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); +#line 1048 "TransitionEffects.c" + } +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + value->data[0].v_pointer = transition_effects_manager_ref (object); +#line 1052 "TransitionEffects.c" + } else { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + value->data[0].v_pointer = NULL; +#line 1056 "TransitionEffects.c" + } +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return NULL; +#line 1060 "TransitionEffects.c" +} + + +static gchar* value_transition_effects_manager_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { + TransitionEffectsManager** object_p; + object_p = collect_values[0].v_pointer; +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (!object_p) { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value)); +#line 1071 "TransitionEffects.c" + } +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (!value->data[0].v_pointer) { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + *object_p = NULL; +#line 1077 "TransitionEffects.c" + } else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + *object_p = value->data[0].v_pointer; +#line 1081 "TransitionEffects.c" + } else { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + *object_p = transition_effects_manager_ref (value->data[0].v_pointer); +#line 1085 "TransitionEffects.c" + } +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return NULL; +#line 1089 "TransitionEffects.c" +} + + +GParamSpec* param_spec_transition_effects_manager (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) { + ParamSpecTransitionEffectsManager* spec; +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (g_type_is_a (object_type, TYPE_TRANSITION_EFFECTS_MANAGER), NULL); +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags); +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + G_PARAM_SPEC (spec)->value_type = object_type; +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return G_PARAM_SPEC (spec); +#line 1103 "TransitionEffects.c" +} + + +gpointer value_get_transition_effects_manager (const GValue* value) { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_TRANSITION_EFFECTS_MANAGER), NULL); +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return value->data[0].v_pointer; +#line 1112 "TransitionEffects.c" +} + + +void value_set_transition_effects_manager (GValue* value, gpointer v_object) { + TransitionEffectsManager* old; +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_TRANSITION_EFFECTS_MANAGER)); +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + old = value->data[0].v_pointer; +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (v_object) { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_TRANSITION_EFFECTS_MANAGER)); +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + value->data[0].v_pointer = v_object; +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_effects_manager_ref (value->data[0].v_pointer); +#line 1132 "TransitionEffects.c" + } else { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + value->data[0].v_pointer = NULL; +#line 1136 "TransitionEffects.c" + } +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (old) { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_effects_manager_unref (old); +#line 1142 "TransitionEffects.c" + } +} + + +void value_take_transition_effects_manager (GValue* value, gpointer v_object) { + TransitionEffectsManager* old; +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_TRANSITION_EFFECTS_MANAGER)); +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + old = value->data[0].v_pointer; +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (v_object) { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_TRANSITION_EFFECTS_MANAGER)); +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + value->data[0].v_pointer = v_object; +#line 1161 "TransitionEffects.c" + } else { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + value->data[0].v_pointer = NULL; +#line 1165 "TransitionEffects.c" + } +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (old) { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_effects_manager_unref (old); +#line 1171 "TransitionEffects.c" + } +} + + +static void transition_effects_manager_class_init (TransitionEffectsManagerClass * klass) { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_effects_manager_parent_class = g_type_class_peek_parent (klass); +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + ((TransitionEffectsManagerClass *) klass)->finalize = transition_effects_manager_finalize; +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_type_class_add_private (klass, sizeof (TransitionEffectsManagerPrivate)); +#line 1183 "TransitionEffects.c" +} + + +static void transition_effects_manager_instance_init (TransitionEffectsManager * self) { + GeeHashMap* _tmp0_ = NULL; + NullTransitionDescriptor* _tmp1_ = NULL; + RandomEffectDescriptor* _tmp2_ = NULL; +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv = TRANSITION_EFFECTS_MANAGER_GET_PRIVATE (self); +#line 14 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = gee_hash_map_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, g_free, SPIT_TRANSITIONS_TYPE_DESCRIPTOR, (GBoxedCopyFunc) g_object_ref, g_object_unref, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL); +#line 14 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->effects = G_TYPE_CHECK_INSTANCE_CAST (_tmp0_, GEE_TYPE_MAP, GeeMap); +#line 16 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = null_transition_descriptor_new (); +#line 16 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->null_descriptor = G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, SPIT_TRANSITIONS_TYPE_DESCRIPTOR, SpitTransitionsDescriptor); +#line 17 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp2_ = random_effect_descriptor_new (); +#line 17 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->random_descriptor = G_TYPE_CHECK_INSTANCE_CAST (_tmp2_, SPIT_TRANSITIONS_TYPE_DESCRIPTOR, SpitTransitionsDescriptor); +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->ref_count = 1; +#line 1207 "TransitionEffects.c" +} + + +static void transition_effects_manager_finalize (TransitionEffectsManager* obj) { + TransitionEffectsManager * self; + PluginsNotifier* _tmp0_ = NULL; + PluginsNotifier* _tmp1_ = NULL; + guint _tmp2_ = 0U; +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_TRANSITION_EFFECTS_MANAGER, TransitionEffectsManager); +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_signal_handlers_destroy (self); +#line 25 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = plugins_notifier_get_instance (); +#line 25 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = _tmp0_; +#line 25 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_signal_parse_name ("pluggable-activation", PLUGINS_TYPE_NOTIFIER, &_tmp2_, NULL, FALSE); +#line 25 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_signal_handlers_disconnect_matched (_tmp1_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp2_, 0, NULL, (GCallback) _transition_effects_manager_load_transitions_plugins_notifier_pluggable_activation, self); +#line 25 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _plugins_notifier_unref0 (_tmp1_); +#line 14 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (self->priv->effects); +#line 16 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (self->priv->null_descriptor); +#line 17 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (self->priv->random_descriptor); +#line 1236 "TransitionEffects.c" +} + + +GType transition_effects_manager_get_type (void) { + static volatile gsize transition_effects_manager_type_id__volatile = 0; + if (g_once_init_enter (&transition_effects_manager_type_id__volatile)) { + static const GTypeValueTable g_define_type_value_table = { value_transition_effects_manager_init, value_transition_effects_manager_free_value, value_transition_effects_manager_copy_value, value_transition_effects_manager_peek_pointer, "p", value_transition_effects_manager_collect_value, "p", value_transition_effects_manager_lcopy_value }; + static const GTypeInfo g_define_type_info = { sizeof (TransitionEffectsManagerClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) transition_effects_manager_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (TransitionEffectsManager), 0, (GInstanceInitFunc) transition_effects_manager_instance_init, &g_define_type_value_table }; + static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) }; + GType transition_effects_manager_type_id; + transition_effects_manager_type_id = g_type_register_fundamental (g_type_fundamental_next (), "TransitionEffectsManager", &g_define_type_info, &g_define_type_fundamental_info, 0); + g_once_init_leave (&transition_effects_manager_type_id__volatile, transition_effects_manager_type_id); + } + return transition_effects_manager_type_id__volatile; +} + + +gpointer transition_effects_manager_ref (gpointer instance) { + TransitionEffectsManager* self; + self = instance; +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_atomic_int_inc (&self->ref_count); +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return instance; +#line 1261 "TransitionEffects.c" +} + + +void transition_effects_manager_unref (gpointer instance) { + TransitionEffectsManager* self; + self = instance; +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (g_atomic_int_dec_and_test (&self->ref_count)) { +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + TRANSITION_EFFECTS_MANAGER_GET_CLASS (self)->finalize (self); +#line 8 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_type_free_instance ((GTypeInstance *) self); +#line 1274 "TransitionEffects.c" + } +} + + +TransitionClock* transition_clock_construct (GType object_type, SpitTransitionsDescriptor* desc) { + TransitionClock* self = NULL; + SpitTransitionsDescriptor* _tmp0_ = NULL; + SpitTransitionsDescriptor* _tmp1_ = NULL; + SpitTransitionsDescriptor* _tmp2_ = NULL; + SpitTransitionsDescriptor* _tmp3_ = NULL; + PluginsStandardHostInterface* _tmp4_ = NULL; + PluginsStandardHostInterface* _tmp5_ = NULL; + SpitTransitionsEffect* _tmp6_ = NULL; + SpitTransitionsEffect* _tmp7_ = NULL; + gint _tmp8_ = 0; + gint _tmp9_ = 0; + SpitTransitionsDescriptor* _tmp10_ = NULL; + const gchar* _tmp11_ = NULL; + OpTimer* _tmp12_ = NULL; +#line 136 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (SPIT_TRANSITIONS_IS_DESCRIPTOR (desc), NULL); +#line 136 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = (TransitionClock*) g_type_create_instance (object_type); +#line 137 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = desc; +#line 137 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = _g_object_ref0 (_tmp0_); +#line 137 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (self->priv->desc); +#line 137 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->desc = _tmp1_; +#line 139 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp2_ = desc; +#line 139 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp3_ = desc; +#line 139 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp4_ = plugins_standard_host_interface_new (G_TYPE_CHECK_INSTANCE_CAST (_tmp3_, SPIT_TYPE_PLUGGABLE, SpitPluggable), "transitions"); +#line 139 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp5_ = _tmp4_; +#line 139 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp6_ = spit_transitions_descriptor_create (_tmp2_, G_TYPE_CHECK_INSTANCE_CAST (_tmp5_, SPIT_TYPE_HOST_INTERFACE, SpitHostInterface)); +#line 139 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (self->priv->effect); +#line 139 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->effect = _tmp6_; +#line 139 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (_tmp5_); +#line 140 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp7_ = self->priv->effect; +#line 140 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + spit_transitions_effect_get_fps (_tmp7_, &_tmp8_, &_tmp9_); +#line 140 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->desired_fps = _tmp8_; +#line 140 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->min_fps = _tmp9_; +#line 142 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp10_ = desc; +#line 142 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp11_ = spit_pluggable_get_pluggable_name (G_TYPE_CHECK_INSTANCE_CAST (_tmp10_, SPIT_TYPE_PLUGGABLE, SpitPluggable)); +#line 142 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp12_ = op_timer_new (_tmp11_); +#line 142 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _op_timer_unref0 (self->priv->paint_timer); +#line 142 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->paint_timer = _tmp12_; +#line 136 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return self; +#line 1342 "TransitionEffects.c" +} + + +TransitionClock* transition_clock_new (SpitTransitionsDescriptor* desc) { +#line 136 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return transition_clock_construct (TYPE_TRANSITION_CLOCK, desc); +#line 1349 "TransitionEffects.c" +} + + +gboolean transition_clock_is_in_progress (TransitionClock* self) { + gboolean result = FALSE; + gboolean _tmp0_ = FALSE; + gboolean _tmp1_ = FALSE; + gboolean _tmp2_ = FALSE; +#line 151 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (IS_TRANSITION_CLOCK (self), FALSE); +#line 152 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp2_ = self->priv->cancelled; +#line 152 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (!_tmp2_) { +#line 1364 "TransitionEffects.c" + SpitTransitionsMotion* _tmp3_ = NULL; +#line 152 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp3_ = self->priv->motion; +#line 152 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = _tmp3_ != NULL; +#line 1370 "TransitionEffects.c" + } else { +#line 152 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = FALSE; +#line 1374 "TransitionEffects.c" + } +#line 152 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (_tmp1_) { +#line 1378 "TransitionEffects.c" + gint _tmp4_ = 0; + SpitTransitionsMotion* _tmp5_ = NULL; + gint _tmp6_ = 0; + gint _tmp7_ = 0; +#line 152 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp4_ = self->priv->frame_number; +#line 152 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp5_ = self->priv->motion; +#line 152 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp6_ = spit_transitions_motion_get_total_frames (_tmp5_); +#line 152 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp7_ = _tmp6_; +#line 152 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = _tmp4_ < _tmp7_; +#line 1393 "TransitionEffects.c" + } else { +#line 152 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = FALSE; +#line 1397 "TransitionEffects.c" + } +#line 152 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = _tmp0_; +#line 152 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 1403 "TransitionEffects.c" +} + + +static gboolean _transition_clock_tick_gsource_func (gpointer self) { + gboolean result; + result = transition_clock_tick ((TransitionClock*) self); +#line 173 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 1412 "TransitionEffects.c" +} + + +void transition_clock_start (TransitionClock* self, SpitTransitionsVisuals* visuals, SpitTransitionsDirection direction, gint duration_msec, TransitionClockRepaintCallback repaint, void* repaint_target) { + gint _tmp0_ = 0; + SpitTransitionsVisuals* _tmp1_ = NULL; + SpitTransitionsVisuals* _tmp2_ = NULL; + TransitionClockRepaintCallback _tmp3_ = NULL; + void* _tmp3__target = NULL; + SpitTransitionsDirection _tmp4_ = 0; + gint _tmp5_ = 0; + gint _tmp6_ = 0; + SpitTransitionsMotion* _tmp7_ = NULL; + SpitTransitionsEffect* _tmp8_ = NULL; + SpitTransitionsVisuals* _tmp9_ = NULL; + SpitTransitionsMotion* _tmp10_ = NULL; + gulong _tmp11_ = 0UL; + SpitTransitionsMotion* _tmp12_ = NULL; + gint _tmp13_ = 0; + gint _tmp14_ = 0; + guint _tmp15_ = 0U; +#line 155 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (IS_TRANSITION_CLOCK (self)); +#line 155 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (SPIT_TRANSITIONS_IS_VISUALS (visuals)); +#line 157 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_clock_reset (self); +#line 160 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = self->priv->desired_fps; +#line 160 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (_tmp0_ == 0) { +#line 161 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return; +#line 1446 "TransitionEffects.c" + } +#line 163 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = visuals; +#line 163 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp2_ = _g_object_ref0 (_tmp1_); +#line 163 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (self->priv->visuals); +#line 163 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->visuals = _tmp2_; +#line 164 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp3_ = repaint; +#line 164 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp3__target = repaint_target; +#line 164 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->repaint = _tmp3_; +#line 164 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->repaint_target = _tmp3__target; +#line 165 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp4_ = direction; +#line 165 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp5_ = self->priv->desired_fps; +#line 165 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp6_ = duration_msec; +#line 165 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp7_ = spit_transitions_motion_new (_tmp4_, _tmp5_, _tmp6_); +#line 165 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (self->priv->motion); +#line 165 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->motion = _tmp7_; +#line 167 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp8_ = self->priv->effect; +#line 167 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp9_ = visuals; +#line 167 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp10_ = self->priv->motion; +#line 167 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + spit_transitions_effect_start (_tmp8_, _tmp9_, _tmp10_); +#line 172 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp11_ = now_ms (); +#line 172 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->time_started = _tmp11_; +#line 173 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp12_ = self->priv->motion; +#line 173 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp13_ = spit_transitions_motion_get_tick_msec (_tmp12_); +#line 173 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp14_ = _tmp13_; +#line 173 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp15_ = g_timeout_add_full (G_PRIORITY_HIGH, (guint) _tmp14_, _transition_clock_tick_gsource_func, transition_clock_ref (self), transition_clock_unref); +#line 173 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->timer_id = _tmp15_; +#line 1498 "TransitionEffects.c" +} + + +static void transition_clock_reset (TransitionClock* self) { +#line 177 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (IS_TRANSITION_CLOCK (self)); +#line 178 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (self->priv->visuals); +#line 178 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->visuals = NULL; +#line 179 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (self->priv->motion); +#line 179 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->motion = NULL; +#line 180 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->repaint = NULL; +#line 180 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->repaint_target = NULL; +#line 181 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_clock_cancel_timer (self); +#line 182 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->time_started = (gulong) 0; +#line 183 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->frame_number = 1; +#line 184 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->current_fps = 0; +#line 185 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->cancelled = FALSE; +#line 1527 "TransitionEffects.c" +} + + +static void transition_clock_cancel_timer (TransitionClock* self) { + guint _tmp0_ = 0U; +#line 188 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (IS_TRANSITION_CLOCK (self)); +#line 189 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = self->priv->timer_id; +#line 189 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (_tmp0_ != ((guint) 0)) { +#line 1539 "TransitionEffects.c" + guint _tmp1_ = 0U; +#line 190 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = self->priv->timer_id; +#line 190 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_source_remove (_tmp1_); +#line 191 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->timer_id = (guint) 0; +#line 1547 "TransitionEffects.c" + } +} + + +static gboolean transition_clock_is_fps_ok (TransitionClock* self) { + gboolean result = FALSE; + gulong _tmp0_ = 0UL; + gint _tmp1_ = 0; + gdouble elapsed_msec = 0.0; + gulong _tmp2_ = 0UL; + gulong _tmp3_ = 0UL; + gdouble _tmp4_ = 0.0; + gint _tmp5_ = 0; + gdouble _tmp6_ = 0.0; + gint _tmp7_ = 0; + gint _tmp8_ = 0; + gint _tmp13_ = 0; + gint _tmp14_ = 0; +#line 196 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (IS_TRANSITION_CLOCK (self), FALSE); +#line 197 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = self->priv->time_started; +#line 197 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _vala_assert (_tmp0_ > ((gulong) 0), "time_started > 0"); +#line 199 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = self->priv->frame_number; +#line 199 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (_tmp1_ <= 3) { +#line 200 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = TRUE; +#line 200 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 1580 "TransitionEffects.c" + } +#line 202 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp2_ = now_ms (); +#line 202 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp3_ = self->priv->time_started; +#line 202 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + elapsed_msec = (gdouble) (_tmp2_ - _tmp3_); +#line 203 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp4_ = elapsed_msec; +#line 203 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (_tmp4_ <= 0.0) { +#line 204 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = TRUE; +#line 204 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 1596 "TransitionEffects.c" + } +#line 206 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp5_ = self->priv->frame_number; +#line 206 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp6_ = elapsed_msec; +#line 206 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->current_fps = (gint) ((_tmp5_ * 1000.0) / _tmp6_); +#line 207 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp7_ = self->priv->current_fps; +#line 207 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp8_ = self->priv->min_fps; +#line 207 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (_tmp7_ < _tmp8_) { +#line 1610 "TransitionEffects.c" + gint _tmp9_ = 0; + gint _tmp10_ = 0; + gdouble _tmp11_ = 0.0; + gint _tmp12_ = 0; +#line 208 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp9_ = self->priv->current_fps; +#line 208 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp10_ = self->priv->min_fps; +#line 208 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp11_ = elapsed_msec; +#line 208 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp12_ = self->priv->frame_number; +#line 208 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_debug ("TransitionEffects.vala:208: Transition rate of %dfps below minimum of " \ +"%dfps (elapsed=%lf frames=%d)", _tmp9_, _tmp10_, _tmp11_, _tmp12_); +#line 1625 "TransitionEffects.c" + } +#line 212 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp13_ = self->priv->current_fps; +#line 212 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp14_ = self->priv->min_fps; +#line 212 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = _tmp13_ >= _tmp14_; +#line 212 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 1635 "TransitionEffects.c" +} + + +void transition_clock_cancel (TransitionClock* self) { + SpitTransitionsEffect* _tmp0_ = NULL; + TransitionClockRepaintCallback _tmp1_ = NULL; + void* _tmp1__target = NULL; +#line 216 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (IS_TRANSITION_CLOCK (self)); +#line 217 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->cancelled = TRUE; +#line 218 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_clock_cancel_timer (self); +#line 219 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = self->priv->effect; +#line 219 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + spit_transitions_effect_cancel (_tmp0_); +#line 222 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = self->priv->repaint; +#line 222 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1__target = self->priv->repaint_target; +#line 222 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ (_tmp1__target); +#line 1659 "TransitionEffects.c" +} + + +gboolean transition_clock_paint (TransitionClock* self, cairo_t* ctx, gint width, gint height) { + gboolean result = FALSE; + gboolean _tmp0_ = FALSE; + OpTimer* _tmp1_ = NULL; + cairo_t* _tmp2_ = NULL; + SpitTransitionsEffect* _tmp3_ = NULL; + gboolean _tmp4_ = FALSE; + SpitTransitionsEffect* _tmp26_ = NULL; + SpitTransitionsVisuals* _tmp27_ = NULL; + SpitTransitionsMotion* _tmp28_ = NULL; + cairo_t* _tmp29_ = NULL; + gint _tmp30_ = 0; + gint _tmp31_ = 0; + gint _tmp32_ = 0; + cairo_t* _tmp33_ = NULL; + OpTimer* _tmp34_ = NULL; +#line 227 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (IS_TRANSITION_CLOCK (self), FALSE); +#line 227 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (ctx != NULL, FALSE); +#line 228 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = transition_clock_is_in_progress (self); +#line 228 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (!_tmp0_) { +#line 229 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = FALSE; +#line 229 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 1691 "TransitionEffects.c" + } +#line 231 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = self->priv->paint_timer; +#line 231 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + op_timer_start (_tmp1_); +#line 233 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp2_ = ctx; +#line 233 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + cairo_save (_tmp2_); +#line 235 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp3_ = self->priv->effect; +#line 235 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp4_ = spit_transitions_effect_needs_clear_background (_tmp3_); +#line 235 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (_tmp4_) { +#line 1707 "TransitionEffects.c" + cairo_t* _tmp5_ = NULL; + SpitTransitionsVisuals* _tmp6_ = NULL; + GdkRGBA _tmp7_ = {0}; + GdkRGBA _tmp8_ = {0}; + gdouble _tmp9_ = 0.0; + SpitTransitionsVisuals* _tmp10_ = NULL; + GdkRGBA _tmp11_ = {0}; + GdkRGBA _tmp12_ = {0}; + gdouble _tmp13_ = 0.0; + SpitTransitionsVisuals* _tmp14_ = NULL; + GdkRGBA _tmp15_ = {0}; + GdkRGBA _tmp16_ = {0}; + gdouble _tmp17_ = 0.0; + SpitTransitionsVisuals* _tmp18_ = NULL; + GdkRGBA _tmp19_ = {0}; + GdkRGBA _tmp20_ = {0}; + gdouble _tmp21_ = 0.0; + cairo_t* _tmp22_ = NULL; + gint _tmp23_ = 0; + gint _tmp24_ = 0; + cairo_t* _tmp25_ = NULL; +#line 236 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp5_ = ctx; +#line 236 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp6_ = self->priv->visuals; +#line 236 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + spit_transitions_visuals_get_bg_color (_tmp6_, &_tmp7_); +#line 236 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp8_ = _tmp7_; +#line 236 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp9_ = _tmp8_.red; +#line 236 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp10_ = self->priv->visuals; +#line 236 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + spit_transitions_visuals_get_bg_color (_tmp10_, &_tmp11_); +#line 236 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp12_ = _tmp11_; +#line 236 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp13_ = _tmp12_.green; +#line 236 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp14_ = self->priv->visuals; +#line 236 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + spit_transitions_visuals_get_bg_color (_tmp14_, &_tmp15_); +#line 236 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp16_ = _tmp15_; +#line 236 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp17_ = _tmp16_.blue; +#line 236 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp18_ = self->priv->visuals; +#line 236 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + spit_transitions_visuals_get_bg_color (_tmp18_, &_tmp19_); +#line 236 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp20_ = _tmp19_; +#line 236 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp21_ = _tmp20_.alpha; +#line 236 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + cairo_set_source_rgba (_tmp5_, _tmp9_, _tmp13_, _tmp17_, _tmp21_); +#line 238 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp22_ = ctx; +#line 238 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp23_ = width; +#line 238 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp24_ = height; +#line 238 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + cairo_rectangle (_tmp22_, (gdouble) 0, (gdouble) 0, (gdouble) _tmp23_, (gdouble) _tmp24_); +#line 239 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp25_ = ctx; +#line 239 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + cairo_fill (_tmp25_); +#line 1777 "TransitionEffects.c" + } +#line 242 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp26_ = self->priv->effect; +#line 242 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp27_ = self->priv->visuals; +#line 242 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp28_ = self->priv->motion; +#line 242 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp29_ = ctx; +#line 242 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp30_ = width; +#line 242 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp31_ = height; +#line 242 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp32_ = self->priv->frame_number; +#line 242 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + spit_transitions_effect_paint (_tmp26_, _tmp27_, _tmp28_, _tmp29_, _tmp30_, _tmp31_, _tmp32_); +#line 244 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp33_ = ctx; +#line 244 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + cairo_restore (_tmp33_); +#line 246 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp34_ = self->priv->paint_timer; +#line 246 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + op_timer_stop (_tmp34_); +#line 248 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = TRUE; +#line 248 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 1807 "TransitionEffects.c" +} + + +static gboolean transition_clock_tick (TransitionClock* self) { + gboolean result = FALSE; + gboolean _tmp0_ = FALSE; + TransitionClockRepaintCallback _tmp1_ = NULL; + void* _tmp1__target = NULL; + gboolean _tmp2_ = FALSE; + gint _tmp3_ = 0; + SpitTransitionsMotion* _tmp4_ = NULL; + gint _tmp5_ = 0; + gint _tmp6_ = 0; +#line 251 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (IS_TRANSITION_CLOCK (self), FALSE); +#line 252 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = transition_clock_is_fps_ok (self); +#line 252 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (!_tmp0_) { +#line 253 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_debug ("TransitionEffects.vala:253: Cancelling transition: below minimum fps"); +#line 254 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_clock_cancel (self); +#line 1831 "TransitionEffects.c" + } +#line 259 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = self->priv->repaint; +#line 259 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1__target = self->priv->repaint_target; +#line 259 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ (_tmp1__target); +#line 261 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp2_ = transition_clock_is_in_progress (self); +#line 261 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (!_tmp2_) { +#line 262 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_clock_cancel_timer (self); +#line 264 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = FALSE; +#line 264 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 1849 "TransitionEffects.c" + } +#line 268 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp3_ = self->priv->frame_number; +#line 268 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp4_ = self->priv->motion; +#line 268 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp5_ = spit_transitions_motion_get_total_frames (_tmp4_); +#line 268 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp6_ = _tmp5_; +#line 268 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (_tmp3_ < _tmp6_) { +#line 1861 "TransitionEffects.c" + SpitTransitionsEffect* _tmp7_ = NULL; + SpitTransitionsVisuals* _tmp8_ = NULL; + SpitTransitionsMotion* _tmp9_ = NULL; + gint _tmp10_ = 0; + gint _tmp11_ = 0; +#line 269 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp7_ = self->priv->effect; +#line 269 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp8_ = self->priv->visuals; +#line 269 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp9_ = self->priv->motion; +#line 269 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp10_ = self->priv->frame_number; +#line 269 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->frame_number = _tmp10_ + 1; +#line 269 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp11_ = self->priv->frame_number; +#line 269 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + spit_transitions_effect_advance (_tmp7_, _tmp8_, _tmp9_, _tmp11_); +#line 1881 "TransitionEffects.c" + } +#line 271 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = TRUE; +#line 271 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 1887 "TransitionEffects.c" +} + + +static void value_transition_clock_init (GValue* value) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + value->data[0].v_pointer = NULL; +#line 1894 "TransitionEffects.c" +} + + +static void value_transition_clock_free_value (GValue* value) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (value->data[0].v_pointer) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_clock_unref (value->data[0].v_pointer); +#line 1903 "TransitionEffects.c" + } +} + + +static void value_transition_clock_copy_value (const GValue* src_value, GValue* dest_value) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (src_value->data[0].v_pointer) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + dest_value->data[0].v_pointer = transition_clock_ref (src_value->data[0].v_pointer); +#line 1913 "TransitionEffects.c" + } else { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + dest_value->data[0].v_pointer = NULL; +#line 1917 "TransitionEffects.c" + } +} + + +static gpointer value_transition_clock_peek_pointer (const GValue* value) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return value->data[0].v_pointer; +#line 1925 "TransitionEffects.c" +} + + +static gchar* value_transition_clock_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (collect_values[0].v_pointer) { +#line 1932 "TransitionEffects.c" + TransitionClock* object; + object = collect_values[0].v_pointer; +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (object->parent_instance.g_class == NULL) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); +#line 1939 "TransitionEffects.c" + } else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL); +#line 1943 "TransitionEffects.c" + } +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + value->data[0].v_pointer = transition_clock_ref (object); +#line 1947 "TransitionEffects.c" + } else { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + value->data[0].v_pointer = NULL; +#line 1951 "TransitionEffects.c" + } +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return NULL; +#line 1955 "TransitionEffects.c" +} + + +static gchar* value_transition_clock_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) { + TransitionClock** object_p; + object_p = collect_values[0].v_pointer; +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (!object_p) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value)); +#line 1966 "TransitionEffects.c" + } +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (!value->data[0].v_pointer) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + *object_p = NULL; +#line 1972 "TransitionEffects.c" + } else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + *object_p = value->data[0].v_pointer; +#line 1976 "TransitionEffects.c" + } else { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + *object_p = transition_clock_ref (value->data[0].v_pointer); +#line 1980 "TransitionEffects.c" + } +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return NULL; +#line 1984 "TransitionEffects.c" +} + + +GParamSpec* param_spec_transition_clock (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) { + ParamSpecTransitionClock* spec; +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (g_type_is_a (object_type, TYPE_TRANSITION_CLOCK), NULL); +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags); +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + G_PARAM_SPEC (spec)->value_type = object_type; +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return G_PARAM_SPEC (spec); +#line 1998 "TransitionEffects.c" +} + + +gpointer value_get_transition_clock (const GValue* value) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_TRANSITION_CLOCK), NULL); +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return value->data[0].v_pointer; +#line 2007 "TransitionEffects.c" +} + + +void value_set_transition_clock (GValue* value, gpointer v_object) { + TransitionClock* old; +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_TRANSITION_CLOCK)); +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + old = value->data[0].v_pointer; +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (v_object) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_TRANSITION_CLOCK)); +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + value->data[0].v_pointer = v_object; +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_clock_ref (value->data[0].v_pointer); +#line 2027 "TransitionEffects.c" + } else { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + value->data[0].v_pointer = NULL; +#line 2031 "TransitionEffects.c" + } +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (old) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_clock_unref (old); +#line 2037 "TransitionEffects.c" + } +} + + +void value_take_transition_clock (GValue* value, gpointer v_object) { + TransitionClock* old; +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_TRANSITION_CLOCK)); +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + old = value->data[0].v_pointer; +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (v_object) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_TRANSITION_CLOCK)); +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value))); +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + value->data[0].v_pointer = v_object; +#line 2056 "TransitionEffects.c" + } else { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + value->data[0].v_pointer = NULL; +#line 2060 "TransitionEffects.c" + } +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (old) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_clock_unref (old); +#line 2066 "TransitionEffects.c" + } +} + + +static void transition_clock_class_init (TransitionClockClass * klass) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_clock_parent_class = g_type_class_peek_parent (klass); +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + ((TransitionClockClass *) klass)->finalize = transition_clock_finalize; +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_type_class_add_private (klass, sizeof (TransitionClockPrivate)); +#line 2078 "TransitionEffects.c" +} + + +static void transition_clock_instance_init (TransitionClock * self) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv = TRANSITION_CLOCK_GET_PRIVATE (self); +#line 126 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->current_fps = 0; +#line 128 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->visuals = NULL; +#line 129 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->motion = NULL; +#line 130 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->repaint = NULL; +#line 131 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->timer_id = (guint) 0; +#line 132 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->time_started = (gulong) 0; +#line 133 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->frame_number = 0; +#line 134 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->priv->cancelled = FALSE; +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self->ref_count = 1; +#line 2103 "TransitionEffects.c" +} + + +static void transition_clock_finalize (TransitionClock* obj) { + TransitionClock * self; + gint _tmp0_ = 0; + SpitTransitionsMotion* _tmp1_ = NULL; + OpTimer* _tmp5_ = NULL; + gchar* _tmp6_ = NULL; + gchar* _tmp7_ = NULL; + gint _tmp8_ = 0; + gint _tmp9_ = 0; + gint _tmp10_ = 0; +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_TRANSITION_CLOCK, TransitionClock); +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_signal_handlers_destroy (self); +#line 146 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + transition_clock_cancel_timer (self); +#line 148 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp1_ = self->priv->motion; +#line 148 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (_tmp1_ != NULL) { +#line 2127 "TransitionEffects.c" + SpitTransitionsMotion* _tmp2_ = NULL; + gint _tmp3_ = 0; + gint _tmp4_ = 0; +#line 148 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp2_ = self->priv->motion; +#line 148 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp3_ = spit_transitions_motion_get_tick_msec (_tmp2_); +#line 148 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp4_ = _tmp3_; +#line 148 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = _tmp4_; +#line 2139 "TransitionEffects.c" + } else { +#line 148 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = 0; +#line 2143 "TransitionEffects.c" + } +#line 147 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp5_ = self->priv->paint_timer; +#line 147 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp6_ = op_timer_to_string (_tmp5_); +#line 147 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp7_ = _tmp6_; +#line 147 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp8_ = self->priv->min_fps; +#line 147 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp9_ = self->priv->desired_fps; +#line 147 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp10_ = self->priv->current_fps; +#line 147 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_debug ("TransitionEffects.vala:147: %s tick_msec=%d min/desired/current fps=%d" \ +"/%d/%d", _tmp7_, _tmp0_, _tmp8_, _tmp9_, _tmp10_); +#line 147 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_free0 (_tmp7_); +#line 122 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (self->priv->desc); +#line 123 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (self->priv->effect); +#line 127 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _op_timer_unref0 (self->priv->paint_timer); +#line 128 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (self->priv->visuals); +#line 129 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _g_object_unref0 (self->priv->motion); +#line 2171 "TransitionEffects.c" +} + + +GType transition_clock_get_type (void) { + static volatile gsize transition_clock_type_id__volatile = 0; + if (g_once_init_enter (&transition_clock_type_id__volatile)) { + static const GTypeValueTable g_define_type_value_table = { value_transition_clock_init, value_transition_clock_free_value, value_transition_clock_copy_value, value_transition_clock_peek_pointer, "p", value_transition_clock_collect_value, "p", value_transition_clock_lcopy_value }; + static const GTypeInfo g_define_type_info = { sizeof (TransitionClockClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) transition_clock_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (TransitionClock), 0, (GInstanceInitFunc) transition_clock_instance_init, &g_define_type_value_table }; + static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) }; + GType transition_clock_type_id; + transition_clock_type_id = g_type_register_fundamental (g_type_fundamental_next (), "TransitionClock", &g_define_type_info, &g_define_type_fundamental_info, 0); + g_once_init_leave (&transition_clock_type_id__volatile, transition_clock_type_id); + } + return transition_clock_type_id__volatile; +} + + +gpointer transition_clock_ref (gpointer instance) { + TransitionClock* self; + self = instance; +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_atomic_int_inc (&self->ref_count); +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return instance; +#line 2196 "TransitionEffects.c" +} + + +void transition_clock_unref (gpointer instance) { + TransitionClock* self; + self = instance; +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (g_atomic_int_dec_and_test (&self->ref_count)) { +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + TRANSITION_CLOCK_GET_CLASS (self)->finalize (self); +#line 116 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_type_free_instance ((GTypeInstance *) self); +#line 2209 "TransitionEffects.c" + } +} + + +static gint null_transition_descriptor_real_get_pluggable_interface (SpitPluggable* base, gint min_host_version, gint max_host_version) { + NullTransitionDescriptor * self; + gint result = 0; +#line 278 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_NULL_TRANSITION_DESCRIPTOR, NullTransitionDescriptor); +#line 279 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = SPIT_TRANSITIONS_CURRENT_INTERFACE; +#line 279 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 2223 "TransitionEffects.c" +} + + +static const gchar* null_transition_descriptor_real_get_id (SpitPluggable* base) { + NullTransitionDescriptor * self; + const gchar* result = NULL; +#line 282 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_NULL_TRANSITION_DESCRIPTOR, NullTransitionDescriptor); +#line 283 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = NULL_TRANSITION_DESCRIPTOR_EFFECT_ID; +#line 283 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 2236 "TransitionEffects.c" +} + + +static const gchar* null_transition_descriptor_real_get_pluggable_name (SpitPluggable* base) { + NullTransitionDescriptor * self; + const gchar* result = NULL; + const gchar* _tmp0_ = NULL; +#line 286 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_NULL_TRANSITION_DESCRIPTOR, NullTransitionDescriptor); +#line 287 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = _ ("None"); +#line 287 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = _tmp0_; +#line 287 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 2252 "TransitionEffects.c" +} + + +static void null_transition_descriptor_real_get_info (SpitPluggable* base, SpitPluggableInfo* info) { + NullTransitionDescriptor * self; +#line 290 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_NULL_TRANSITION_DESCRIPTOR, NullTransitionDescriptor); +#line 290 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (info != NULL); +#line 2262 "TransitionEffects.c" +} + + +static void null_transition_descriptor_real_activation (SpitPluggable* base, gboolean enabled) { + NullTransitionDescriptor * self; +#line 293 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_NULL_TRANSITION_DESCRIPTOR, NullTransitionDescriptor); +#line 2270 "TransitionEffects.c" +} + + +static SpitTransitionsEffect* null_transition_descriptor_real_create (SpitTransitionsDescriptor* base, SpitHostInterface* host) { + NullTransitionDescriptor * self; + SpitTransitionsEffect* result = NULL; + NullEffect* _tmp0_ = NULL; +#line 296 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_NULL_TRANSITION_DESCRIPTOR, NullTransitionDescriptor); +#line 296 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (SPIT_IS_HOST_INTERFACE (host), NULL); +#line 297 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = null_effect_new (); +#line 297 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = G_TYPE_CHECK_INSTANCE_CAST (_tmp0_, SPIT_TRANSITIONS_TYPE_EFFECT, SpitTransitionsEffect); +#line 297 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 2288 "TransitionEffects.c" +} + + +NullTransitionDescriptor* null_transition_descriptor_construct (GType object_type) { + NullTransitionDescriptor * self = NULL; +#line 275 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = (NullTransitionDescriptor*) g_object_new (object_type, NULL); +#line 275 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return self; +#line 2298 "TransitionEffects.c" +} + + +NullTransitionDescriptor* null_transition_descriptor_new (void) { +#line 275 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return null_transition_descriptor_construct (TYPE_NULL_TRANSITION_DESCRIPTOR); +#line 2305 "TransitionEffects.c" +} + + +static void null_transition_descriptor_class_init (NullTransitionDescriptorClass * klass) { +#line 275 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + null_transition_descriptor_parent_class = g_type_class_peek_parent (klass); +#line 2312 "TransitionEffects.c" +} + + +static void null_transition_descriptor_spit_pluggable_interface_init (SpitPluggableIface * iface) { +#line 275 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + null_transition_descriptor_spit_pluggable_parent_iface = g_type_interface_peek_parent (iface); +#line 275 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + iface->get_pluggable_interface = (gint (*)(SpitPluggable*, gint, gint)) null_transition_descriptor_real_get_pluggable_interface; +#line 275 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + iface->get_id = (const gchar* (*)(SpitPluggable*)) null_transition_descriptor_real_get_id; +#line 275 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + iface->get_pluggable_name = (const gchar* (*)(SpitPluggable*)) null_transition_descriptor_real_get_pluggable_name; +#line 275 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + iface->get_info = (void (*)(SpitPluggable*, SpitPluggableInfo*)) null_transition_descriptor_real_get_info; +#line 275 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + iface->activation = (void (*)(SpitPluggable*, gboolean)) null_transition_descriptor_real_activation; +#line 2329 "TransitionEffects.c" +} + + +static void null_transition_descriptor_spit_transitions_descriptor_interface_init (SpitTransitionsDescriptorIface * iface) { +#line 275 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + null_transition_descriptor_spit_transitions_descriptor_parent_iface = g_type_interface_peek_parent (iface); +#line 275 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + iface->create = (SpitTransitionsEffect* (*)(SpitTransitionsDescriptor*, SpitHostInterface*)) null_transition_descriptor_real_create; +#line 2338 "TransitionEffects.c" +} + + +static void null_transition_descriptor_instance_init (NullTransitionDescriptor * self) { +} + + +GType null_transition_descriptor_get_type (void) { + static volatile gsize null_transition_descriptor_type_id__volatile = 0; + if (g_once_init_enter (&null_transition_descriptor_type_id__volatile)) { + static const GTypeInfo g_define_type_info = { sizeof (NullTransitionDescriptorClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) null_transition_descriptor_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (NullTransitionDescriptor), 0, (GInstanceInitFunc) null_transition_descriptor_instance_init, NULL }; + static const GInterfaceInfo spit_pluggable_info = { (GInterfaceInitFunc) null_transition_descriptor_spit_pluggable_interface_init, (GInterfaceFinalizeFunc) NULL, NULL}; + static const GInterfaceInfo spit_transitions_descriptor_info = { (GInterfaceInitFunc) null_transition_descriptor_spit_transitions_descriptor_interface_init, (GInterfaceFinalizeFunc) NULL, NULL}; + GType null_transition_descriptor_type_id; + null_transition_descriptor_type_id = g_type_register_static (G_TYPE_OBJECT, "NullTransitionDescriptor", &g_define_type_info, 0); + g_type_add_interface_static (null_transition_descriptor_type_id, SPIT_TYPE_PLUGGABLE, &spit_pluggable_info); + g_type_add_interface_static (null_transition_descriptor_type_id, SPIT_TRANSITIONS_TYPE_DESCRIPTOR, &spit_transitions_descriptor_info); + g_once_init_leave (&null_transition_descriptor_type_id__volatile, null_transition_descriptor_type_id); + } + return null_transition_descriptor_type_id__volatile; +} + + +NullEffect* null_effect_construct (GType object_type) { + NullEffect * self = NULL; +#line 302 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = (NullEffect*) g_object_new (object_type, NULL); +#line 302 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return self; +#line 2368 "TransitionEffects.c" +} + + +NullEffect* null_effect_new (void) { +#line 302 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return null_effect_construct (TYPE_NULL_EFFECT); +#line 2375 "TransitionEffects.c" +} + + +static void null_effect_real_get_fps (SpitTransitionsEffect* base, gint* desired_fps, gint* min_fps) { + NullEffect * self; + gint _vala_desired_fps = 0; + gint _vala_min_fps = 0; +#line 305 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_NULL_EFFECT, NullEffect); +#line 306 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _vala_desired_fps = 0; +#line 307 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _vala_min_fps = 0; +#line 305 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (desired_fps) { +#line 305 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + *desired_fps = _vala_desired_fps; +#line 2393 "TransitionEffects.c" + } +#line 305 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + if (min_fps) { +#line 305 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + *min_fps = _vala_min_fps; +#line 2399 "TransitionEffects.c" + } +} + + +static void null_effect_real_start (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion) { + NullEffect * self; +#line 310 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_NULL_EFFECT, NullEffect); +#line 310 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (SPIT_TRANSITIONS_IS_VISUALS (visuals)); +#line 310 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (SPIT_TRANSITIONS_IS_MOTION (motion)); +#line 2412 "TransitionEffects.c" +} + + +static gboolean null_effect_real_needs_clear_background (SpitTransitionsEffect* base) { + NullEffect * self; + gboolean result = FALSE; +#line 313 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_NULL_EFFECT, NullEffect); +#line 314 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = FALSE; +#line 314 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 2425 "TransitionEffects.c" +} + + +static void null_effect_real_paint (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion, cairo_t* ctx, gint width, gint height, gint frame_number) { + NullEffect * self; +#line 317 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_NULL_EFFECT, NullEffect); +#line 317 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (SPIT_TRANSITIONS_IS_VISUALS (visuals)); +#line 317 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (SPIT_TRANSITIONS_IS_MOTION (motion)); +#line 317 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (ctx != NULL); +#line 2439 "TransitionEffects.c" +} + + +static void null_effect_real_advance (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion, gint frame_number) { + NullEffect * self; +#line 321 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_NULL_EFFECT, NullEffect); +#line 321 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (SPIT_TRANSITIONS_IS_VISUALS (visuals)); +#line 321 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (SPIT_TRANSITIONS_IS_MOTION (motion)); +#line 2451 "TransitionEffects.c" +} + + +static void null_effect_real_cancel (SpitTransitionsEffect* base) { + NullEffect * self; +#line 324 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_NULL_EFFECT, NullEffect); +#line 2459 "TransitionEffects.c" +} + + +static void null_effect_class_init (NullEffectClass * klass) { +#line 301 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + null_effect_parent_class = g_type_class_peek_parent (klass); +#line 2466 "TransitionEffects.c" +} + + +static void null_effect_spit_transitions_effect_interface_init (SpitTransitionsEffectIface * iface) { +#line 301 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + null_effect_spit_transitions_effect_parent_iface = g_type_interface_peek_parent (iface); +#line 301 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + iface->get_fps = (void (*)(SpitTransitionsEffect*, gint*, gint*)) null_effect_real_get_fps; +#line 301 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + iface->start = (void (*)(SpitTransitionsEffect*, SpitTransitionsVisuals*, SpitTransitionsMotion*)) null_effect_real_start; +#line 301 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + iface->needs_clear_background = (gboolean (*)(SpitTransitionsEffect*)) null_effect_real_needs_clear_background; +#line 301 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + iface->paint = (void (*)(SpitTransitionsEffect*, SpitTransitionsVisuals*, SpitTransitionsMotion*, cairo_t*, gint, gint, gint)) null_effect_real_paint; +#line 301 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + iface->advance = (void (*)(SpitTransitionsEffect*, SpitTransitionsVisuals*, SpitTransitionsMotion*, gint)) null_effect_real_advance; +#line 301 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + iface->cancel = (void (*)(SpitTransitionsEffect*)) null_effect_real_cancel; +#line 2485 "TransitionEffects.c" +} + + +static void null_effect_instance_init (NullEffect * self) { +} + + +GType null_effect_get_type (void) { + static volatile gsize null_effect_type_id__volatile = 0; + if (g_once_init_enter (&null_effect_type_id__volatile)) { + static const GTypeInfo g_define_type_info = { sizeof (NullEffectClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) null_effect_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (NullEffect), 0, (GInstanceInitFunc) null_effect_instance_init, NULL }; + static const GInterfaceInfo spit_transitions_effect_info = { (GInterfaceInitFunc) null_effect_spit_transitions_effect_interface_init, (GInterfaceFinalizeFunc) NULL, NULL}; + GType null_effect_type_id; + null_effect_type_id = g_type_register_static (G_TYPE_OBJECT, "NullEffect", &g_define_type_info, 0); + g_type_add_interface_static (null_effect_type_id, SPIT_TRANSITIONS_TYPE_EFFECT, &spit_transitions_effect_info); + g_once_init_leave (&null_effect_type_id__volatile, null_effect_type_id); + } + return null_effect_type_id__volatile; +} + + +static gint random_effect_descriptor_real_get_pluggable_interface (SpitPluggable* base, gint min_host_version, gint max_host_version) { + RandomEffectDescriptor * self; + gint result = 0; +#line 330 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_RANDOM_EFFECT_DESCRIPTOR, RandomEffectDescriptor); +#line 331 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = SPIT_TRANSITIONS_CURRENT_INTERFACE; +#line 331 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 2516 "TransitionEffects.c" +} + + +static const gchar* random_effect_descriptor_real_get_id (SpitPluggable* base) { + RandomEffectDescriptor * self; + const gchar* result = NULL; +#line 334 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_RANDOM_EFFECT_DESCRIPTOR, RandomEffectDescriptor); +#line 335 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = RANDOM_EFFECT_DESCRIPTOR_EFFECT_ID; +#line 335 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 2529 "TransitionEffects.c" +} + + +static const gchar* random_effect_descriptor_real_get_pluggable_name (SpitPluggable* base) { + RandomEffectDescriptor * self; + const gchar* result = NULL; + const gchar* _tmp0_ = NULL; +#line 338 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_RANDOM_EFFECT_DESCRIPTOR, RandomEffectDescriptor); +#line 339 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = _ ("Random"); +#line 339 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = _tmp0_; +#line 339 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 2545 "TransitionEffects.c" +} + + +static void random_effect_descriptor_real_get_info (SpitPluggable* base, SpitPluggableInfo* info) { + RandomEffectDescriptor * self; +#line 342 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_RANDOM_EFFECT_DESCRIPTOR, RandomEffectDescriptor); +#line 342 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_if_fail (info != NULL); +#line 2555 "TransitionEffects.c" +} + + +static void random_effect_descriptor_real_activation (SpitPluggable* base, gboolean enabled) { + RandomEffectDescriptor * self; +#line 345 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_RANDOM_EFFECT_DESCRIPTOR, RandomEffectDescriptor); +#line 2563 "TransitionEffects.c" +} + + +static SpitTransitionsEffect* random_effect_descriptor_real_create (SpitTransitionsDescriptor* base, SpitHostInterface* host) { + RandomEffectDescriptor * self; + SpitTransitionsEffect* result = NULL; + NullEffect* _tmp0_ = NULL; +#line 348 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_RANDOM_EFFECT_DESCRIPTOR, RandomEffectDescriptor); +#line 348 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + g_return_val_if_fail (SPIT_IS_HOST_INTERFACE (host), NULL); +#line 349 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + _tmp0_ = null_effect_new (); +#line 349 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + result = G_TYPE_CHECK_INSTANCE_CAST (_tmp0_, SPIT_TRANSITIONS_TYPE_EFFECT, SpitTransitionsEffect); +#line 349 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return result; +#line 2581 "TransitionEffects.c" +} + + +RandomEffectDescriptor* random_effect_descriptor_construct (GType object_type) { + RandomEffectDescriptor * self = NULL; +#line 327 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + self = (RandomEffectDescriptor*) g_object_new (object_type, NULL); +#line 327 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return self; +#line 2591 "TransitionEffects.c" +} + + +RandomEffectDescriptor* random_effect_descriptor_new (void) { +#line 327 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + return random_effect_descriptor_construct (TYPE_RANDOM_EFFECT_DESCRIPTOR); +#line 2598 "TransitionEffects.c" +} + + +static void random_effect_descriptor_class_init (RandomEffectDescriptorClass * klass) { +#line 327 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + random_effect_descriptor_parent_class = g_type_class_peek_parent (klass); +#line 2605 "TransitionEffects.c" +} + + +static void random_effect_descriptor_spit_pluggable_interface_init (SpitPluggableIface * iface) { +#line 327 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + random_effect_descriptor_spit_pluggable_parent_iface = g_type_interface_peek_parent (iface); +#line 327 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + iface->get_pluggable_interface = (gint (*)(SpitPluggable*, gint, gint)) random_effect_descriptor_real_get_pluggable_interface; +#line 327 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + iface->get_id = (const gchar* (*)(SpitPluggable*)) random_effect_descriptor_real_get_id; +#line 327 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + iface->get_pluggable_name = (const gchar* (*)(SpitPluggable*)) random_effect_descriptor_real_get_pluggable_name; +#line 327 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + iface->get_info = (void (*)(SpitPluggable*, SpitPluggableInfo*)) random_effect_descriptor_real_get_info; +#line 327 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + iface->activation = (void (*)(SpitPluggable*, gboolean)) random_effect_descriptor_real_activation; +#line 2622 "TransitionEffects.c" +} + + +static void random_effect_descriptor_spit_transitions_descriptor_interface_init (SpitTransitionsDescriptorIface * iface) { +#line 327 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + random_effect_descriptor_spit_transitions_descriptor_parent_iface = g_type_interface_peek_parent (iface); +#line 327 "/home/jens/Source/shotwell/src/slideshow/TransitionEffects.vala" + iface->create = (SpitTransitionsEffect* (*)(SpitTransitionsDescriptor*, SpitHostInterface*)) random_effect_descriptor_real_create; +#line 2631 "TransitionEffects.c" +} + + +static void random_effect_descriptor_instance_init (RandomEffectDescriptor * self) { +} + + +GType random_effect_descriptor_get_type (void) { + static volatile gsize random_effect_descriptor_type_id__volatile = 0; + if (g_once_init_enter (&random_effect_descriptor_type_id__volatile)) { + static const GTypeInfo g_define_type_info = { sizeof (RandomEffectDescriptorClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) random_effect_descriptor_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (RandomEffectDescriptor), 0, (GInstanceInitFunc) random_effect_descriptor_instance_init, NULL }; + static const GInterfaceInfo spit_pluggable_info = { (GInterfaceInitFunc) random_effect_descriptor_spit_pluggable_interface_init, (GInterfaceFinalizeFunc) NULL, NULL}; + static const GInterfaceInfo spit_transitions_descriptor_info = { (GInterfaceInitFunc) random_effect_descriptor_spit_transitions_descriptor_interface_init, (GInterfaceFinalizeFunc) NULL, NULL}; + GType random_effect_descriptor_type_id; + random_effect_descriptor_type_id = g_type_register_static (G_TYPE_OBJECT, "RandomEffectDescriptor", &g_define_type_info, 0); + g_type_add_interface_static (random_effect_descriptor_type_id, SPIT_TYPE_PLUGGABLE, &spit_pluggable_info); + g_type_add_interface_static (random_effect_descriptor_type_id, SPIT_TRANSITIONS_TYPE_DESCRIPTOR, &spit_transitions_descriptor_info); + g_once_init_leave (&random_effect_descriptor_type_id__volatile, random_effect_descriptor_type_id); + } + return random_effect_descriptor_type_id__volatile; +} + + + |