예제 #1
0
static void
saver_completed_cb (GthTask  *task,
		    GError   *error,
		    gpointer  user_data)
{
	DialogData *data = user_data;
	GthMonitor *monitor;
	GList      *scan;

	monitor = gth_main_get_default_monitor ();
	for (scan = data->parents; scan; scan = scan->next)
		gth_monitor_resume (monitor, (GFile *) scan->data);

	if (error != NULL) {
		if (! g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED))
			_gtk_error_dialog_from_gerror_show (GTK_WINDOW (data->dialog), _("Could not save the file metadata"), error);
	}
	else {
		for (scan = data->file_list; scan; scan = scan->next) {
			GthFileData *file_data = scan->data;
			GList       *files;

			files = g_list_prepend (NULL, g_object_ref (file_data->file));
			gth_monitor_metadata_changed (monitor, file_data);

			_g_object_list_unref (files);
		}
	}

	if (data->close_dialog)
		close_dialog (data);

	dialog_data_unref (data);
}
예제 #2
0
파일: main.c 프로젝트: ChingezKhan/gthumb
gboolean
all_windows_add_monitor (void)
{
	gth_monitor_resume (gth_monitor);
	return FALSE;
}