ges: Fix how we handle layer vs layer-priority in the structured interface
authorThibault Saunier <tsaunier@gnome.org>
Thu, 23 Jul 2015 09:40:57 +0000 (11:40 +0200)
committerThibault Saunier <tsaunier@gnome.org>
Thu, 23 Jul 2015 10:28:14 +0000 (12:28 +0200)
ges/ges-structured-interface.c

index b54a921..11ff2bc 100644 (file)
@@ -346,7 +346,8 @@ _ges_add_clip_from_struct (GESTimeline * timeline, GstStructure * structure,
   TRY_GET ("pattern", G_TYPE_STRING, &pattern, NULL);
   TRY_GET ("name", G_TYPE_STRING, &name, NULL);
   TRY_GET ("layer-priority", G_TYPE_INT, &layer_priority, -1);
-  TRY_GET ("layer", G_TYPE_INT, &layer_priority, -1);
+  if (layer_priority == -1)
+    TRY_GET ("layer", G_TYPE_INT, &layer_priority, -1);
   TRY_GET ("type", G_TYPE_STRING, &type_string, "GESUriClip");
   TRY_GET ("start", GST_TYPE_CLOCK_TIME, &start, GST_CLOCK_TIME_NONE);
   TRY_GET ("inpoint", GST_TYPE_CLOCK_TIME, &inpoint, 0);