On Tue, 12 Apr 2011 19:54:53 +0200 Enrico Tröger enrico.troeger@uvena.de wrote:
+gint document_sort_by_display_name(gconstpointer a, gconstpointer b)
I think this should be renamed document_cmp_by_display_name (or document_compare_by_display_name). The function doesn't actually sort anything.
Absolutely right. Changed it in SVN according to your patch.
Ok, thanks.
+/** Adds a list of document items to @a menu.
- @a sort_func might be NULL to not sort the documents in the
menu. In this case,
- the order of the document tabs is used.
...
+void ui_menu_add_document_items_sorted(GtkMenu *menu, GeanyDocument *active,
I think it would be better if when sort_func is NULL the items are sorted by display name, because in that case the function is the same as ui_menu_add_document_items, so no one would pass NULL.
I don't mind. Might be better.
I think rather than change the behaviour now I'll leave it.
Regards, Nick