- fix a couple ui widget size/position issues
- fix subtitle selection when no match is found in a title for a subtitle preset
- fix an error in generating strings that describe a subtitles type
git-svn-id: svn://localhost/HandBrake/trunk@2431
b64f7644-9d1e-0410-96f1-
a4d463321fa5
<object class="GtkAlignment" id="alignment57">
<property name="visible">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
+ <property name="xalign">0</property>
+ <property name="xscale">0</property>
<property name="top_padding">6</property>
<property name="bottom_padding">2</property>
<property name="left_padding">12</property>
</child>
<child>
<object class="GtkComboBox" id="SubtitleTrack">
- <property name="width_request">150</property>
<property name="visible">True</property>
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
<signal handler="subtitle_track_changed_cb" name="changed"/>
const gchar * name = "Unknown";
if (track == -2)
- return CC608SUB;
- if (track < 0)
- return VOBSUB;
- if (track < 0)
+ {
+ name = "Text";
goto done;
+ }
+ if (track == -1)
+ {
+ name = "Bitmap";
+ goto done;
+ }
titleindex = ghb_settings_combo_int(ud->settings, "title");
if (titleindex < 0)
hb_title_t * title;
hb_subtitle_t * sub;
- if (h_scan == NULL) return VOBSUB;
+ if (h_scan == NULL)
+ goto done;
list = hb_get_titles( h_scan );
if( !hb_list_count( list ) )
goto done;
// select sequential tracks for each. The hash keeps track
// of the tracks used for each language.
track = ghb_find_subtitle_track(titleindex, lang, track_indices);
- ghb_settings_set_int(subtitle, "SubtitleTrack", track);
- // Add to subtitle list
- add_pref(ud, subtitle);
- ghb_ui_update(ud, "SubtitleTrack", ghb_int64_value(track));
g_free(lang);
+ if (track >= 0)
+ {
+ ghb_settings_set_int(subtitle, "SubtitleTrack", track);
+ // Add to subtitle list
+ add_pref(ud, subtitle);
+ ghb_ui_update(ud, "SubtitleTrack", ghb_int64_value(track));
+ }
}
g_hash_table_destroy(track_indices);
}