Hello community,
here is the log from the commit of package libgnomeui
checked in at Mon Oct 8 12:23:19 CEST 2007.
--------
--- GNOME/libgnomeui/libgnomeui.changes 2007-09-19 16:38:06.000000000 +0200
+++ /mounts/work_src_done/STABLE/libgnomeui/libgnomeui.changes 2007-10-05 19:12:01.258970000 +0200
@@ -1,0 +2,9 @@
+Fri Oct 5 19:11:28 CEST 2007 - federico@novell.com
+
+- Removed libgnomeui-155010-filechooser-show-drives.diff.
+- Added libgnomeui-330187-file-chooser-drive-volume-policy.diff to fix
+ https://bugzilla.novell.com/show_bug.cgi?id=330187 - CD-ROMs do not
+ appear in the file chooser. Now the file chooser follows the same policy as
+ Nautilus to show its drives/volumes.
+
+-------------------------------------------------------------------
Old:
----
libgnomeui-155010-filechooser-show-drives.diff
New:
----
libgnomeui-330187-file-chooser-drive-volume-policy.diff
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ libgnomeui.spec ++++++
--- /var/tmp/diff_new_pack.Qa1527/_old 2007-10-08 12:23:07.000000000 +0200
+++ /var/tmp/diff_new_pack.Qa1527/_new 2007-10-08 12:23:07.000000000 +0200
@@ -12,15 +12,15 @@
Name: libgnomeui
BuildRequires: fdupes gnome-common gnome-keyring-devel gtk-doc intltool libbonoboui-devel libglade2-devel libjpeg-devel perl-XML-Parser
-License: GPL v2 or later, LGPL v2 or later
+License: GPL v2 or later; LGPL v2 or later
Group: Development/Libraries/GNOME
AutoReqProv: on
Requires: gnome-icon-theme shared-mime-info
Version: 2.20.0
-Release: 1
+Release: 7
Summary: The GNOME User Interface Library
Source: %{name}-%{version}.tar.bz2
-Patch0: libgnomeui-155010-filechooser-show-drives.diff
+Patch1: libgnomeui-330187-file-chooser-drive-volume-policy.diff
BuildRoot: %{_tmppath}/%{name}-%{version}-build
Requires: %{name}-lang = %{version}
@@ -77,7 +77,7 @@
%lang_package
%prep
%setup -q
-%patch0 -p0
+%patch1 -p1
%build
autoreconf -f -i
@@ -123,8 +123,13 @@
%files doc
%defattr(-,root,root)
%{_datadir}/gtk-doc/html/libgnomeui
-
%changelog
+* Fri Oct 05 2007 - federico@novell.com
+- Removed libgnomeui-155010-filechooser-show-drives.diff.
+- Added libgnomeui-330187-file-chooser-drive-volume-policy.diff to fix
+ https://bugzilla.novell.com/show_bug.cgi?id=330187 - CD-ROMs do not
+ appear in the file chooser. Now the file chooser follows the same policy as
+ Nautilus to show its drives/volumes.
* Wed Sep 19 2007 - sbrabec@suse.cz
- Updated to version 2.20.0:
* create tar.bz2 in dist
++++++ libgnomeui-330187-file-chooser-drive-volume-policy.diff ++++++
2007-10-02 Federico Mena Quintero
Fix https://bugzilla.novell.com/show_bug.cgi?id=330187 - CD-ROMs
do not appear in the file chooser.
* file-chooser/gtkfilesystemgnomevfs.c
(gtk_file_system_gnome_vfs_list_volumes): Use the same code as in
Nautilus to populate the drive/volume list in the file chooser.
This way we have the same results, in the same order as Nautilus.
diff --git a/file-chooser/gtkfilesystemgnomevfs.c b/file-chooser/gtkfilesystemgnomevfs.c
index 18a1902..42ce37e 100644
--- a/file-chooser/gtkfilesystemgnomevfs.c
+++ b/file-chooser/gtkfilesystemgnomevfs.c
@@ -654,63 +654,96 @@ gtk_file_system_gnome_vfs_list_volumes (GtkFileSystem *file_system)
GtkFileSystemGnomeVFS *system_vfs = GTK_FILE_SYSTEM_GNOME_VFS (file_system);
GnomeVFSVolume *volume;
GnomeVFSDrive *drive;
+ GList *drives;
+ GList *volumes;
GSList *result;
- GList *list;
GList *l;
+ GList *ll;
profile_start ("start", NULL);
result = NULL;
- /* User-visible drives */
+ /* Add root, first in the list */
+ volume = gnome_vfs_volume_monitor_get_volume_for_path (system_vfs->volume_monitor, "/");
+ if (volume)
+ result = g_slist_prepend (result, volume);
- list = gnome_vfs_volume_monitor_get_connected_drives (system_vfs->volume_monitor);
- list = g_list_sort (list, (GCompareFunc) gnome_vfs_drive_compare);
- for (l = list; l; l = l->next)
- {
- drive = GNOME_VFS_DRIVE (l->data);
+ /* Network Servers */
- if (gnome_vfs_drive_is_user_visible (drive))
- result = g_slist_prepend (result, drive);
- else
- gnome_vfs_drive_unref (drive);
- }
+ result = g_slist_prepend (result, (gpointer) network_servers_volume_token);
- g_list_free (list);
+ /* Keep this code in sync with nautilus/src/nautilus-places-sidebar.c:update_places()
+ * {{{
+ */
- /* User-visible volumes with no corresponding drives */
+ /* for all drives add all its volumes */
- list = gnome_vfs_volume_monitor_get_mounted_volumes (system_vfs->volume_monitor);
- list = g_list_sort (list, (GCompareFunc) gnome_vfs_volume_compare);
- for (l = list; l; l = l->next)
+ drives = gnome_vfs_volume_monitor_get_connected_drives (system_vfs->volume_monitor);
+ drives = g_list_sort (drives, (GCompareFunc)gnome_vfs_drive_compare);
+ for (l = drives; l != NULL; l = l->next)
{
- volume = GNOME_VFS_VOLUME (l->data);
- drive = gnome_vfs_volume_get_drive (volume);
+ drive = l->data;
+ if (!gnome_vfs_drive_is_user_visible (drive))
+ {
+ gnome_vfs_drive_unref (drive);
+ continue;
+ }
- if (!drive && gnome_vfs_volume_is_user_visible (volume))
- result = g_slist_prepend (result, volume);
- else
- gnome_vfs_volume_unref (volume);
+ if (gnome_vfs_drive_is_mounted (drive))
+ {
+ /* The drive is mounted, add all its volumes */
+ volumes = gnome_vfs_drive_get_mounted_volumes (drive);
+ volumes = g_list_sort (volumes, (GCompareFunc)gnome_vfs_volume_compare);
+ for (ll = volumes; ll != NULL; ll = ll->next)
+ {
+ volume = ll->data;
+ if (!gnome_vfs_volume_is_user_visible (volume))
+ {
+ gnome_vfs_volume_unref (volume);
+ continue;
+ }
+ result = g_slist_prepend (result, volume);
+ }
+ g_list_free (volumes);
- if (drive)
- gnome_vfs_drive_unref (drive);
+ gnome_vfs_drive_unref (drive);
+ }
+ else
+ {
+ /* The drive is unmounted but visible, add it.
+ * This is for drives like floppy that can't be
+ * auto-mounted */
+ result = g_slist_prepend (result, drive);
+ }
}
+ g_list_free (drives);
- g_list_free (list);
+ /* add mounted volumes that has no drive (ftp, sftp,...) */
- /* Network Servers */
+ volumes = gnome_vfs_volume_monitor_get_mounted_volumes (system_vfs->volume_monitor);
+ volumes = g_list_sort (volumes, (GCompareFunc)gnome_vfs_volume_compare);
+ for (l = volumes; l != NULL; l = l->next)
+ {
+ volume = l->data;
+ drive = gnome_vfs_volume_get_drive (volume);
+ if (!gnome_vfs_volume_is_user_visible (volume) || drive != NULL)
+ {
+ gnome_vfs_drive_unref (drive);
+ gnome_vfs_volume_unref (volume);
+ continue;
+ }
- result = g_slist_prepend (result, (gpointer) network_servers_volume_token);
+ result = g_slist_prepend (result, volume);
+ }
+ g_list_free (volumes);
+
+ /* }}} */
/* Done */
result = g_slist_reverse (result);
- /* Add root, first in the list */
- volume = gnome_vfs_volume_monitor_get_volume_for_path (system_vfs->volume_monitor, "/");
- if (volume)
- result = g_slist_prepend (result, volume);
-
profile_end ("end", NULL);
return result;
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
---------------------------------------------------------------------
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org