RB.RemovableMediaManager¶
Subclasses: | None |
---|
Methods¶
Inherited: | GObject.Object (37) |
---|---|
Structs: | GObject.ObjectClass (5) |
class | new (shell) |
device_is_android (device) |
|
get_gudev_device (volume) |
|
scan () |
Properties¶
Name | Type | Flags | Short Description |
---|---|---|---|
scanned |
bool |
r | Whether a scan has been performed |
shell |
RB.Shell |
r/w/co | RB.Shell object |
Signals¶
Inherited: | GObject.Object (1) |
---|
Name | Short Description |
---|---|
create-source-device |
Emitted when a new device is detected to allow plugins to create a corresponding RB.Source . |
create-source-mount |
Emitted when a new mount is added to allow plugins to create a corresponding RB.Source . |
create-source-volume |
Emitted when a new volume is added to allow plugins to create a corresponding RB.Source . |
medium-added |
Emitted when a new source is added for a removable medium. |
Class Details¶
-
class
RB.
RemovableMediaManager
(**kwargs)¶ Bases: GObject.Object
Abstract: No Structure: RB.RemovableMediaManagerClass
-
classmethod
new
(shell)¶ Parameters: shell ( RB.Shell
) – theRB.Shell
Returns: the RB.RemovableMediaManager
Return type: RB.RemovableMediaManager
Creates the
RB.RemovableMediaManager
instance.
-
device_is_android
(device)¶ Parameters: device ( GObject.Object
) – the #GUdevDevice to queryReturns: True
if the device appears to be Android-basedReturn type: bool
Determines whether the specified device looks like an Android device.
-
get_gudev_device
(volume)¶ Parameters: volume ( Gio.Volume
) – theGio.Volume
Returns: the #GUDevDevice instance, if any Return type: GObject.Object
Finds the #GUdevDevice for the volume.
-
classmethod
Signal Details¶
-
RB.RemovableMediaManager.signals.
create_source_device
(removable_media_manager, device)¶ Signal Name: create-source-device
Flags: Parameters: - removable_media_manager (
RB.RemovableMediaManager
) – The object which received the signal - device (
GObject.Object
) – the device (actually a #GUdevDevice)
Returns: a source for the device, or
None
Return type: Emitted when a new device is detected to allow plugins to create a corresponding
RB.Source
. The first signal handler that returns a source wins. Plugins should only use this signal if there will be noGio.Volume
orGio.Mount
created for the device.- removable_media_manager (
-
RB.RemovableMediaManager.signals.
create_source_mount
(removable_media_manager, device_info, mount)¶ Signal Name: create-source-mount
Flags: Parameters: - removable_media_manager (
RB.RemovableMediaManager
) – The object which received the signal - device_info (
Gio.Mount
) – aMPID.Device
containing information on the device - mount (
MPID.Device
) – theGio.Mount
Returns: a source for the mount, or
None
Return type: Emitted when a new mount is added to allow plugins to create a corresponding
RB.Source
. The first signal handler that returns a source wins. If a source was created for theGio.Volume
for a mount, then this signal will not be emitted.- removable_media_manager (
-
RB.RemovableMediaManager.signals.
create_source_volume
(removable_media_manager, volume)¶ Signal Name: create-source-volume
Flags: Parameters: - removable_media_manager (
RB.RemovableMediaManager
) – The object which received the signal - volume (
Gio.Volume
) – theGio.Volume
Returns: a source for the volume, or
None
Return type: Emitted when a new volume is added to allow plugins to create a corresponding
RB.Source
. The first signal handler that returns a source wins. A plugin should only use this signal if it doesn’t require the volume to be mounted. If the volume must be mounted to be useful, use the create-source-mount signal instead.- removable_media_manager (
-
RB.RemovableMediaManager.signals.
medium_added
(removable_media_manager, source)¶ Signal Name: medium-added
Flags: Parameters: - removable_media_manager (
RB.RemovableMediaManager
) – The object which received the signal - source (
GObject.Object
) – the newly addedRB.Source
Emitted when a new source is added for a removable medium.
- removable_media_manager (
Property Details¶
-
RB.RemovableMediaManager.props.
scanned
¶ Name: scanned
Type: bool
Default Value: False
Flags: READABLE
This is set to
True
when the removable media manager has scanned all existing volumes and mounts. When a plugin that handles removable media is activated, it should request a new scan if this property is already set toTrue
.