Commit 0f1fe739 authored by Harald Sitter's avatar Harald Sitter 🏳️‍🌈
Browse files

mtp: remove timeout members

they are entirely unused
parent 766af7f3
......@@ -101,7 +101,7 @@ void KMTPd::checkDevice(const Solid::Device &solidDevice)
LIBMTP_mtpdevice_t *mtpDevice = LIBMTP_Open_Raw_Device_Uncached(rawDevice);
if (mtpDevice) {
MTPDevice *device = new MTPDevice(QStringLiteral("/modules/kmtpd/device%1").arg(m_devices.count()), mtpDevice, rawDevice, solidDevice.udi(), m_timeout);
auto device = new MTPDevice(QStringLiteral("/modules/kmtpd/device%1").arg(m_devices.count()), mtpDevice, rawDevice, solidDevice.udi());
// Always let MTPDevice know any changes to devices. It might be helpful Daemon interfaces
connect(this, &KMTPd::devicesChanged, device, [device] {
......
......@@ -32,7 +32,6 @@ private:
MTPDevice *deviceFromUdi(const QString &udi) const;
QList<MTPDevice *> m_devices;
qint32 m_timeout;
public Q_SLOTS:
// D-Bus methods
......
......@@ -29,10 +29,9 @@
* @param device The LIBMTP_mtpdevice_t pointer to cache
* @param udi The UDI of the new device to cache
*/
MTPDevice::MTPDevice(const QString &dbusObjectPath, LIBMTP_mtpdevice_t *device, LIBMTP_raw_device_t *rawdevice, const QString &udi, qint32 timeout, QObject *parent)
MTPDevice::MTPDevice(const QString &dbusObjectPath, LIBMTP_mtpdevice_t *device, LIBMTP_raw_device_t *rawdevice, const QString &udi, QObject *parent)
: QObject(parent),
m_dbusObjectName(dbusObjectPath),
m_timeout(timeout),
m_mtpdevice(device),
m_rawdevice(*rawdevice),
m_udi(udi),
......@@ -48,7 +47,7 @@ MTPDevice::MTPDevice(const QString &dbusObjectPath, LIBMTP_mtpdevice_t *device,
m_friendlyName = QString::fromUtf8(deviceName);
}
qCDebug(LOG_KIOD_KMTPD) << "Created device " << m_friendlyName << " with udi=" << udi << " and timeout " << timeout;
qCDebug(LOG_KIOD_KMTPD) << "Created device " << m_friendlyName << " with udi=" << udi;
new DeviceAdaptor(this);
QDBusConnection::sessionBus().registerObject(m_dbusObjectName, this);
......
......@@ -30,7 +30,6 @@ public:
LIBMTP_mtpdevice_t *device,
LIBMTP_raw_device_t *rawdevice,
const QString &udi,
qint32 timeout,
QObject *parent = nullptr);
~MTPDevice() override;
......@@ -50,7 +49,6 @@ public:
private:
const QString m_dbusObjectName;
QList<MTPStorage *> m_storages;
qint32 m_timeout;
LIBMTP_mtpdevice_t *m_mtpdevice;
LIBMTP_raw_device_t m_rawdevice;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment