Commit 76b06955 authored by Paolo Borelli's avatar Paolo Borelli Committed by Paolo Borelli

Avoid runtime warning with buggy gtk.

2008-09-07  Paolo Borelli  <pborelli@katamail.com>

	* gedit/gedit-file-chooser-dialog.c: Avoid runtime warning with
	buggy gtk.


svn path=/trunk/; revision=6505
parent d27f9fda
2008-09-07 Paolo Borelli <pborelli@katamail.com>
* gedit/gedit-file-chooser-dialog.c: Avoid runtime warning with
buggy gtk.
2008-09-07 Paolo Borelli <pborelli@katamail.com>
* data/gedit.schemas.in: add ftp since it seems to work pretty well
......
......@@ -133,22 +133,26 @@ filter_changed (GeditFileChooserDialog *dialog,
gpointer data)
{
GtkFileFilter *filter;
const gchar *name;
gint id = 0;
if (!gedit_prefs_manager_active_file_filter_can_set ())
return;
filter = gtk_file_chooser_get_filter (GTK_FILE_CHOOSER (dialog));
name = gtk_file_filter_get_name (filter);
g_return_if_fail (name != NULL);
if (filter != NULL)
{
const gchar *name;
gint id = 0;
name = gtk_file_filter_get_name (filter);
g_return_if_fail (name != NULL);
if (strcmp (name, ALL_TEXT_FILES) == 0)
id = 1;
if (strcmp (name, ALL_TEXT_FILES) == 0)
id = 1;
gedit_debug_message (DEBUG_COMMANDS, "Active filter: %s (%d)", name, id);
gedit_debug_message (DEBUG_COMMANDS, "Active filter: %s (%d)", name, id);
gedit_prefs_manager_set_active_file_filter (id);
gedit_prefs_manager_set_active_file_filter (id);
}
}
/* FIXME: use globs too - Paolo (Aug. 27, 2007) */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment