summaryrefslogtreecommitdiffstats
path: root/gtk/src
diff options
context:
space:
mode:
authorjstebbins <[email protected]>2014-03-22 22:13:25 +0000
committerjstebbins <[email protected]>2014-03-22 22:13:25 +0000
commite308f3eacf1285298c976a5d966c1845816e7c18 (patch)
tree35ba40bca8463fc44b14eb943d3023e41001d27a /gtk/src
parent7e9a9983a1b8431089fe0a137c974a2e44d0b678 (diff)
LinGui: fix live preview generation
Preferences (where live preview duration is set) were not getting added to live peview job settings. Also, fix a compiler warning when using gstreamer 0.10. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@6127 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'gtk/src')
-rw-r--r--gtk/src/preview.c20
1 files changed, 8 insertions, 12 deletions
diff --git a/gtk/src/preview.c b/gtk/src/preview.c
index e5f697810..55249c463 100644
--- a/gtk/src/preview.c
+++ b/gtk/src/preview.c
@@ -371,25 +371,20 @@ update_stream_info(signal_user_data_t *ud)
static GList *
get_stream_info_objects_for_type (GstElement *play, const gchar *typestr)
{
- GValueArray *info_arr = NULL;
+ GList *info_list = NULL, *link;
GList *ret = NULL;
- guint ii;
if (play == NULL)
return NULL;
- g_object_get(play, "stream-info-value-array", &info_arr, NULL);
- if (info_arr == NULL)
+ g_object_get(play, "stream-info", &info_list, NULL);
+ if (info_list == NULL)
return NULL;
- for (ii = 0; ii < info_arr->n_values; ++ii)
+ link = info_list;
+ while (link)
{
- GObject *info_obj;
- GValue *val;
-
- val = g_value_array_get_nth(info_arr, ii);
- //val = &((GValue*)info_arr->values)[ii];
- info_obj = g_value_get_object(val);
+ GObject *info_obj = (GObject*)link->data;
if (info_obj)
{
GParamSpec *pspec;
@@ -410,8 +405,8 @@ get_stream_info_objects_for_type (GstElement *play, const gchar *typestr)
}
}
}
+ if (link) link = link->next;
}
- g_value_array_free (info_arr);
return g_list_reverse (ret);
}
@@ -764,6 +759,7 @@ live_preview_start_cb(GtkWidget *xwidget, signal_user_data_t *ud)
ghb_settings_set_string(js, "destination", name);
ghb_settings_set_int(js, "start_frame", ud->preview->frame);
ud->preview->live_id = 0;
+ ghb_settings_set_value(js, "Preferences", ud->prefs);
ghb_add_live_job(js, ud->preview->live_id);
ghb_start_live_encode();
ghb_value_free(js);