~oem-solutions-group/unity-2d/clutter-1.0

« back to all changes in this revision

Viewing changes to clutter/clutter-interval.c

  • Committer: Bazaar Package Importer
  • Author(s): Emilio Pozuelo Monfort
  • Date: 2010-03-21 13:27:56 UTC
  • mto: (2.1.3 experimental)
  • mto: This revision was merged to the branch mainline in revision 8.
  • Revision ID: james.westby@ubuntu.com-20100321132756-nf8yd30yxo3zzwcm
Tags: upstream-1.2.2
ImportĀ upstreamĀ versionĀ 1.2.2

Show diffs side-by-side

added added

removed removed

Lines of Context:
307
307
      break;
308
308
    }
309
309
 
 
310
  /* We're trying to animate a property without knowing how to do that. Issue
 
311
   * a warning with a hint to what could be done to fix that */
 
312
  if (G_UNLIKELY (retval == FALSE))
 
313
    {
 
314
      g_warning ("%s: Could not compute progress between two %ss. You can "
 
315
                 "register a progress function to instruct ClutterInterval "
 
316
                 "how to deal with this GType",
 
317
                 G_STRLOC,
 
318
                 g_type_name (value_type));
 
319
    }
 
320
 
310
321
  return retval;
311
322
}
312
323
 
411
422
  gchar *error;
412
423
 
413
424
  /* initial value */
 
425
#if GLIB_CHECK_VERSION (2, 23, 2)
 
426
  G_VALUE_COLLECT_INIT (&value, gtype, var_args, 0, &error);
 
427
#else
414
428
  g_value_init (&value, gtype);
415
429
  G_VALUE_COLLECT (&value, var_args, 0, &error);
 
430
#endif /* GLIB_CHECK_VERSION (2, 23, 2) */
 
431
 
416
432
  if (error)
417
433
    {
418
434
      g_warning ("%s: %s", G_STRLOC, error);
429
445
  g_value_unset (&value);
430
446
 
431
447
  /* final value */
 
448
#if GLIB_CHECK_VERSION (2, 23, 2)
 
449
  G_VALUE_COLLECT_INIT (&value, gtype, var_args, 0, &error);
 
450
#else
432
451
  g_value_init (&value, gtype);
433
452
  G_VALUE_COLLECT (&value, var_args, 0, &error);
 
453
#endif /* GLIB_CHECK_VERSION (2, 23, 2) */
 
454
 
434
455
  if (error)
435
456
    {
436
457
      g_warning ("%s: %s", G_STRLOC, error);
672
693
clutter_interval_get_initial_value (ClutterInterval *interval,
673
694
                                    GValue          *value)
674
695
{
675
 
  ClutterIntervalPrivate *priv;
676
 
 
677
696
  g_return_if_fail (CLUTTER_IS_INTERVAL (interval));
678
697
  g_return_if_fail (value != NULL);
679
698
 
680
 
  priv = interval->priv;
681
 
 
682
699
  clutter_interval_get_value_internal (interval, 0, value);
683
700
}
684
701
 
745
762
clutter_interval_get_final_value (ClutterInterval *interval,
746
763
                                  GValue          *value)
747
764
{
748
 
  ClutterIntervalPrivate *priv;
749
 
 
750
765
  g_return_if_fail (CLUTTER_IS_INTERVAL (interval));
751
766
  g_return_if_fail (value != NULL);
752
767
 
753
 
  priv = interval->priv;
754
 
 
755
768
  clutter_interval_get_value_internal (interval, 1, value);
756
769
}
757
770