fix recent files issues

This commit is contained in:
Matthias Clasen 2006-08-18 15:30:57 +00:00
parent d9f077ff6b
commit a2cb34336a
4 changed files with 19 additions and 4 deletions

View File

@ -1,3 +1,11 @@
2006-08-18 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkrecentchooser.c (gtk_recent_chooser_get_uris): Behave as
documented and always return a NULL-terminated array.
* gtk/gtkrecentmanager.c (gtk_recent_manager_real_changed): Make sure
to reset write_in_progress.
2006-08-17 Matthias Clasen <mclasen@redhat.com>
* configure.in: Bump version

View File

@ -1,3 +1,11 @@
2006-08-18 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkrecentchooser.c (gtk_recent_chooser_get_uris): Behave as
documented and always return a NULL-terminated array.
* gtk/gtkrecentmanager.c (gtk_recent_manager_real_changed): Make sure
to reset write_in_progress.
2006-08-17 Matthias Clasen <mclasen@redhat.com>
* configure.in: Bump version

View File

@ -836,8 +836,6 @@ gtk_recent_chooser_get_uris (GtkRecentChooser *chooser,
gsize n_items, i;
items = gtk_recent_chooser_get_items (chooser);
if (!items)
return NULL;
n_items = g_list_length (items);
retval = g_new0 (gchar *, n_items + 1);

View File

@ -402,6 +402,7 @@ gtk_recent_manager_real_changed (GtkRecentManager *manager)
g_bookmark_file_to_file (priv->recent_items,
priv->filename,
&write_error);
if (write_error)
{
filename_warning ("Attempting to store changes into `%s', "
@ -411,6 +412,8 @@ gtk_recent_manager_real_changed (GtkRecentManager *manager)
g_error_free (write_error);
}
priv->write_in_progress = FALSE;
/* we have sync'ed our list with the storage file, so we
* update the file mtime in order to skip the timed check
* and spare us from a re-read.
@ -422,8 +425,6 @@ gtk_recent_manager_real_changed (GtkRecentManager *manager)
priv->filename,
g_strerror (errno));
priv->write_in_progress = FALSE;
g_object_thaw_notify (G_OBJECT (manager));
return;