Revision: 3772 http://geany.svn.sourceforge.net/geany/?rev=3772&view=rev Author: eht16 Date: 2009-05-08 16:13:29 +0000 (Fri, 08 May 2009)
Log Message: ----------- When a filter is set, apply it only to files, not directories and apply the filter to the UTF-8 name of the file as the filter string itself is also UTF-8.
Modified Paths: -------------- trunk/ChangeLog trunk/plugins/filebrowser.c
Modified: trunk/ChangeLog =================================================================== --- trunk/ChangeLog 2009-05-04 20:40:11 UTC (rev 3771) +++ trunk/ChangeLog 2009-05-08 16:13:29 UTC (rev 3772) @@ -1,3 +1,11 @@ +2009-05-08 Enrico Tröger <enrico(dot)troeger(at)uvena(dot)de> + + * plugins/filebrowser.c: + When a filter is set, apply it only to files, not directories and + apply the filter to the UTF-8 name of the file as the filter string + itself is also UTF-8. + + 2009-05-03 Enrico Tröger <enrico(dot)troeger(at)uvena(dot)de>
* wscript, scintilla/*, scintilla/include/*, src/plugindata.h:
Modified: trunk/plugins/filebrowser.c =================================================================== --- trunk/plugins/filebrowser.c 2009-05-04 20:40:11 UTC (rev 3771) +++ trunk/plugins/filebrowser.c 2009-05-08 16:13:29 UTC (rev 3772) @@ -168,13 +168,11 @@ if (! show_hidden_files && check_hidden(name)) return;
- if (check_filtered(name)) - return; - sep = (utils_str_equal(current_dir, "/")) ? "" : G_DIR_SEPARATOR_S; fname = g_strconcat(current_dir, sep, name, NULL); dir = g_file_test(fname, G_FILE_TEST_IS_DIR); utf8_fullname = utils_get_locale_from_utf8(fname); + utf8_name = utils_get_utf8_from_locale(name); g_free(fname);
if (dir) @@ -189,9 +187,16 @@ last_dir_iter = gtk_tree_iter_copy(&iter); } else + { + if (check_filtered(utf8_name)) + { + g_free(utf8_name); + g_free(utf8_fullname); + return; + } gtk_list_store_append(file_store, &iter); + }
- utf8_name = utils_get_utf8_from_locale(name);
gtk_list_store_set(file_store, &iter, FILEVIEW_COLUMN_ICON, (dir) ? GTK_STOCK_DIRECTORY : GTK_STOCK_FILE,
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.