MCPcopy Create free account
hub / github.com/HandBrake/HandBrake / queue_open_log_action_cb

Function queue_open_log_action_cb

gtk/src/queuehandler.c:2197–2226  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2195}
2196
2197G_MODULE_EXPORT void
2198queue_open_log_action_cb (GSimpleAction *action, GVariant *param,
2199 signal_user_data_t *ud)
2200{
2201 GtkListBox * lb;
2202 GtkListBoxRow * row;
2203 gint index;
2204 GhbValue * queueDict, * uiDict;
2205 const char * path;
2206
2207 lb = GTK_LIST_BOX(ghb_builder_widget("queue_list"));
2208 row = gtk_list_box_get_selected_row(lb);
2209 if (row != NULL)
2210 {
2211 index = gtk_list_box_row_get_index(row);
2212 if (index < 0 || index >= ghb_array_len(ud->queue))
2213 {
2214 return;
2215 }
2216 queueDict = ghb_array_get(ud->queue, index);
2217 uiDict = ghb_dict_get(queueDict, "uiSettings");
2218 path = ghb_dict_get_string(uiDict, "ActivityFilename");
2219 if (path == NULL)
2220 {
2221 return;
2222 }
2223 g_autoptr(GFile) file = g_file_new_for_path(path);
2224 ghb_file_open(file);
2225 }
2226}
2227
2228G_MODULE_EXPORT void
2229queue_open_log_dir_action_cb (GSimpleAction *action, GVariant *param,

Callers

nothing calls this directly

Calls 3

ghb_builder_widgetFunction · 0.85
ghb_dict_get_stringFunction · 0.85
ghb_file_openFunction · 0.85

Tested by

no test coverage detected