diff options
author | David Zeuthen <davidz@redhat.com> | 2007-12-19 09:39:50 +0000 |
---|---|---|
committer | Alexander Larsson <alexl@src.gnome.org> | 2007-12-19 09:39:50 +0000 |
commit | 88679aba98d30ba069edfffb46257ef77451d641 (patch) | |
tree | b7db980ffe189176c93e237d884a6c9d607f9591 /gio/gdrive.c | |
parent | 3ca41fe1092a7de0ad5d43b167349edf8c1a3feb (diff) | |
download | glib-88679aba98d30ba069edfffb46257ef77451d641.tar.gz glib-88679aba98d30ba069edfffb46257ef77451d641.tar.bz2 glib-88679aba98d30ba069edfffb46257ef77451d641.zip |
Introduce g_volume_monitor_adopt_orphan_mount() function. Also add signals
2007-12-19 David Zeuthen <davidz@redhat.com>
Introduce g_volume_monitor_adopt_orphan_mount() function. Also
add signals 'disconnected' and 'eject-button' on GDrive. Add
signal 'removed' on GVolume and 'unmounted' on GMount.
* gdrive.c: (g_drive_base_init):
* gdrive.h:
* gfile.c: (g_file_mount_mountable),
(g_file_mount_enclosing_volume):
* gio.symbols:
* gioerror.h:
* gmount.c: (g_mount_base_init):
* gmount.h:
* gunionvolumemonitor.c: (g_volume_monitor_adopt_orphan_mount):
* gunixvolumemonitor.c: (update_volumes), (update_mounts):
* gvolume.c: (g_volume_base_init), (g_volume_mount):
* gvolume.h:
* gvolumemonitor.h:
svn path=/trunk/; revision=6153
Diffstat (limited to 'gio/gdrive.c')
-rw-r--r-- | gio/gdrive.c | 35 |
1 files changed, 33 insertions, 2 deletions
diff --git a/gio/gdrive.c b/gio/gdrive.c index 642ef6b2f..b047774b5 100644 --- a/gio/gdrive.c +++ b/gio/gdrive.c @@ -97,10 +97,9 @@ g_drive_base_init (gpointer g_class) { /** * GDrive::changed: - * @volume: a #GVolume. + * @drive: a #GDrive. * * Emitted when the drive's state has changed. - * **/ g_signal_new (I_("changed"), G_TYPE_DRIVE, @@ -110,6 +109,38 @@ g_drive_base_init (gpointer g_class) g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); + /** + * GDrive::disconnected: + * @drive: a #GDrive. + * + * This signal is emitted when the #GDrive have been + * disconnected. If the recipient is holding references to the + * object they should release them so the object can be + * finalized. + **/ + g_signal_new (I_("disconnected"), + G_TYPE_DRIVE, + G_SIGNAL_RUN_LAST, + G_STRUCT_OFFSET (GDriveIface, disconnected), + NULL, NULL, + g_cclosure_marshal_VOID__VOID, + G_TYPE_NONE, 0); + + /** + * GDrive::eject-button: + * @drive: a #GDrive. + * + * Emitted when the physical eject button (if any) of a drive have been pressed. + * + **/ + g_signal_new (I_("eject-button"), + G_TYPE_DRIVE, + G_SIGNAL_RUN_LAST, + G_STRUCT_OFFSET (GDriveIface, eject_button), + NULL, NULL, + g_cclosure_marshal_VOID__VOID, + G_TYPE_NONE, 0); + initialized = TRUE; } } |