Skip to content

Automatically mount directory after attaching loop device

After attaching a loop device, the device needs to be mounted on directory to be accessible. This can be done manually by clicking on the newly appeared device in dolphin side bar. This patch automatize this by automatically mounting the loop device to a directory using Solid after attaching the loop device.

The way this is done a little bit hacky since the plugin needs to wait for UDisks2 to send a signal to Solid to update its device database. The wait is done using a nested QEventLoop by waiting on Solid::DeviceNotifier::deviceAdded signal.

BUG: 424413

Edited by Kwon-Young Choi

Merge request reports

Loading