gimp r25213 - in trunk: . app/gui
- From: neo svn gnome org
- To: svn-commits-list gnome org
- Subject: gimp r25213 - in trunk: . app/gui
- Date: Mon, 24 Mar 2008 23:08:46 +0000 (GMT)
Author: neo
Date: Mon Mar 24 23:08:46 2008
New Revision: 25213
URL: http://svn.gnome.org/viewvc/gimp?rev=25213&view=rev
Log:
2008-03-25 Sven Neumann <sven gimp org>
* app/gui/gui-vtable.c (gui_recent_list_load): sort the list
into
MRU order on load.
Modified:
trunk/ChangeLog
trunk/app/gui/gui-vtable.c
Modified: trunk/app/gui/gui-vtable.c
==============================================================================
--- trunk/app/gui/gui-vtable.c (original)
+++ trunk/app/gui/gui-vtable.c Mon Mar 24 23:08:46 2008
@@ -620,6 +620,14 @@
uri, &recent);
}
+static gint
+gui_recent_list_compare (gconstpointer a,
+ gconstpointer b)
+{
+ return (gtk_recent_info_get_modified ((GtkRecentInfo *) a) -
+ gtk_recent_info_get_modified ((GtkRecentInfo *) b));
+}
+
static void
gui_recent_list_load (Gimp *gimp)
{
@@ -633,6 +641,8 @@
items = gtk_recent_manager_get_items (gtk_recent_manager_get_default ());
+ items = g_list_sort (items, gui_recent_list_compare);
+
for (list = items; list; list = list->next)
{
GtkRecentInfo *info = list->data;
@@ -657,6 +667,5 @@
g_list_free (items);
- gimp_list_reverse (GIMP_LIST (gimp->documents));
gimp_container_thaw (gimp->documents);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]