summaryrefslogtreecommitdiffstats
path: root/tdeioslave/media/mediamanager
diff options
context:
space:
mode:
Diffstat (limited to 'tdeioslave/media/mediamanager')
-rw-r--r--tdeioslave/media/mediamanager/dialog.cpp2
-rw-r--r--tdeioslave/media/mediamanager/fstabbackend.cpp10
-rw-r--r--tdeioslave/media/mediamanager/linuxcdpolling.cpp22
-rw-r--r--tdeioslave/media/mediamanager/medialist.h2
-rw-r--r--tdeioslave/media/mediamanager/mediamanager.cpp18
-rw-r--r--tdeioslave/media/mediamanager/removablebackend.cpp6
-rw-r--r--tdeioslave/media/mediamanager/tdehardwarebackend.cpp31
7 files changed, 45 insertions, 46 deletions
diff --git a/tdeioslave/media/mediamanager/dialog.cpp b/tdeioslave/media/mediamanager/dialog.cpp
index b2e9ff5f5..ddfd041a0 100644
--- a/tdeioslave/media/mediamanager/dialog.cpp
+++ b/tdeioslave/media/mediamanager/dialog.cpp
@@ -37,7 +37,7 @@ Dialog::Dialog(TQString url, TQString iconName) :
TQPixmap pixmap = TDEGlobal::iconLoader()->loadIcon(iconName, TDEIcon::NoGroup, TDEIcon::SizeLarge);
unlockDialog->encryptedIcon->setPixmap( pixmap );
- connect(unlockDialog->passwordEdit, TQT_SIGNAL (textChanged(const TQString &)), this, TQT_SLOT (slotPasswordChanged(const TQString &)));
+ connect(unlockDialog->passwordEdit, TQ_SIGNAL (textChanged(const TQString &)), this, TQ_SLOT (slotPasswordChanged(const TQString &)));
setMainWidget(unlockDialog);
}
diff --git a/tdeioslave/media/mediamanager/fstabbackend.cpp b/tdeioslave/media/mediamanager/fstabbackend.cpp
index 6549723fe..2f60dfcbf 100644
--- a/tdeioslave/media/mediamanager/fstabbackend.cpp
+++ b/tdeioslave/media/mediamanager/fstabbackend.cpp
@@ -43,7 +43,7 @@
#include <kdirwatch.h>
#include <kurl.h>
#include <kmountpoint.h>
-#include <kstandarddirs.h>
+#include <tdestandarddirs.h>
#ifdef _OS_SOLARIS_
#define FSTAB "/etc/vfstab"
@@ -61,8 +61,8 @@ FstabBackend::FstabBackend(MediaList &list, bool networkSharesOnly)
KDirWatch::self()->addFile(MTAB);
KDirWatch::self()->addFile(FSTAB);
- connect( KDirWatch::self(), TQT_SIGNAL( dirty(const TQString&) ),
- this, TQT_SLOT( slotDirty(const TQString&) ) );
+ connect( KDirWatch::self(), TQ_SIGNAL( dirty(const TQString&) ),
+ this, TQ_SLOT( slotDirty(const TQString&) ) );
handleFstabChange(false);
handleMtabChange(false);
@@ -70,8 +70,8 @@ FstabBackend::FstabBackend(MediaList &list, bool networkSharesOnly)
KDirWatch::self()->startScan();
#if defined(Q_OS_FREEBSD) || defined(Q_OS_NETBSD)
- connect( &m_mtabTimer, TQT_SIGNAL( timeout() ),
- this, TQT_SLOT( handleMtabChange() ) );
+ connect( &m_mtabTimer, TQ_SIGNAL( timeout() ),
+ this, TQ_SLOT( handleMtabChange() ) );
m_mtabTimer.start(250);
#endif
}
diff --git a/tdeioslave/media/mediamanager/linuxcdpolling.cpp b/tdeioslave/media/mediamanager/linuxcdpolling.cpp
index eccdf1f34..66074f40e 100644
--- a/tdeioslave/media/mediamanager/linuxcdpolling.cpp
+++ b/tdeioslave/media/mediamanager/linuxcdpolling.cpp
@@ -176,19 +176,19 @@ private:
LinuxCDPolling::LinuxCDPolling(MediaList &list)
: TQObject(), BackendBase(list)
{
- connect(&m_mediaList, TQT_SIGNAL(mediumAdded(const TQString &,
+ connect(&m_mediaList, TQ_SIGNAL(mediumAdded(const TQString &,
const TQString &, bool)),
- this, TQT_SLOT(slotMediumAdded(const TQString &)) );
+ this, TQ_SLOT(slotMediumAdded(const TQString &)) );
- connect(&m_mediaList, TQT_SIGNAL(mediumRemoved(const TQString &,
+ connect(&m_mediaList, TQ_SIGNAL(mediumRemoved(const TQString &,
const TQString &, bool)),
- this, TQT_SLOT(slotMediumRemoved(const TQString &)) );
+ this, TQ_SLOT(slotMediumRemoved(const TQString &)) );
- connect(&m_mediaList, TQT_SIGNAL(mediumStateChanged(const TQString &,
+ connect(&m_mediaList, TQ_SIGNAL(mediumStateChanged(const TQString &,
const TQString &, bool, bool)),
- this, TQT_SLOT(slotMediumStateChanged(const TQString &)) );
+ this, TQ_SLOT(slotMediumStateChanged(const TQString &)) );
- connect(&m_timer, TQT_SIGNAL(timeout()), this, TQT_SLOT(slotTimeout()));
+ connect(&m_timer, TQ_SIGNAL(timeout()), this, TQ_SLOT(slotTimeout()));
}
LinuxCDPolling::~LinuxCDPolling()
@@ -514,7 +514,7 @@ bool LinuxCDPolling::hasDirectory(const TQCString &devNode, const TQCString &dir
close(fd);
return false;
}
- if (Q_BYTE_ORDER != Q_LITTLE_ENDIAN)
+ if (TQ_BYTE_ORDER != TQ_LITTLE_ENDIAN)
bs = ((bs << 8) & 0xFF00) | ((bs >> 8) & 0xFF);
// read in size of path table
@@ -524,7 +524,7 @@ bool LinuxCDPolling::hasDirectory(const TQCString &devNode, const TQCString &dir
close(fd);
return false;
}
- if (Q_BYTE_ORDER != Q_LITTLE_ENDIAN)
+ if (TQ_BYTE_ORDER != TQ_LITTLE_ENDIAN)
ts = ((ts << 8) & 0xFF00) | ((ts >> 8) & 0xFF);
// read in which block path table is in
@@ -534,7 +534,7 @@ bool LinuxCDPolling::hasDirectory(const TQCString &devNode, const TQCString &dir
close(fd);
return false;
}
- if (Q_BYTE_ORDER != Q_LITTLE_ENDIAN)
+ if (TQ_BYTE_ORDER != TQ_LITTLE_ENDIAN)
tl = ((tl << 24) & 0xFF000000) | ((tl << 8) & 0xFF0000) |
((tl >> 8) & 0xFF00) | ((tl >> 24) & 0xFF);
@@ -559,7 +559,7 @@ bool LinuxCDPolling::hasDirectory(const TQCString &devNode, const TQCString &dir
ret = false;
break;
}
- if (Q_BYTE_ORDER != Q_LITTLE_ENDIAN)
+ if (TQ_BYTE_ORDER != TQ_LITTLE_ENDIAN)
parent = ((parent << 8) & 0xFF00) | ((parent >> 8) & 0xFF);
// read the name
diff --git a/tdeioslave/media/mediamanager/medialist.h b/tdeioslave/media/mediamanager/medialist.h
index 5397b37cc..a92d1b6c0 100644
--- a/tdeioslave/media/mediamanager/medialist.h
+++ b/tdeioslave/media/mediamanager/medialist.h
@@ -23,7 +23,7 @@
#include "medium.h"
-class MediaList : public QObject
+class MediaList : public TQObject
{
TQ_OBJECT
diff --git a/tdeioslave/media/mediamanager/mediamanager.cpp b/tdeioslave/media/mediamanager/mediamanager.cpp
index f8c2a574b..dc1671b22 100644
--- a/tdeioslave/media/mediamanager/mediamanager.cpp
+++ b/tdeioslave/media/mediamanager/mediamanager.cpp
@@ -26,7 +26,7 @@
#include <tdelocale.h>
#include <kdirnotify_stub.h>
-#include <kstandarddirs.h>
+#include <tdestandarddirs.h>
#include "mediamanagersettings.h"
@@ -43,15 +43,15 @@
MediaManager::MediaManager(const TQCString &obj)
: KDEDModule(obj), m_dirNotify(m_mediaList)
{
- connect( &m_mediaList, TQT_SIGNAL(mediumAdded(const TQString&, const TQString&, bool)),
- TQT_SLOT(slotMediumAdded(const TQString&, const TQString&, bool)) );
- connect( &m_mediaList, TQT_SIGNAL(mediumRemoved(const TQString&, const TQString&, bool)),
- TQT_SLOT(slotMediumRemoved(const TQString&, const TQString&, bool)) );
+ connect( &m_mediaList, TQ_SIGNAL(mediumAdded(const TQString&, const TQString&, bool)),
+ TQ_SLOT(slotMediumAdded(const TQString&, const TQString&, bool)) );
+ connect( &m_mediaList, TQ_SIGNAL(mediumRemoved(const TQString&, const TQString&, bool)),
+ TQ_SLOT(slotMediumRemoved(const TQString&, const TQString&, bool)) );
connect( &m_mediaList,
- TQT_SIGNAL(mediumStateChanged(const TQString&, const TQString&, bool, bool)),
- TQT_SLOT(slotMediumChanged(const TQString&, const TQString&, bool, bool)) );
+ TQ_SIGNAL(mediumStateChanged(const TQString&, const TQString&, bool, bool)),
+ TQ_SLOT(slotMediumChanged(const TQString&, const TQString&, bool, bool)) );
- TQTimer::singleShot( 10, this, TQT_SLOT( loadBackends() ) );
+ TQTimer::singleShot( 10, this, TQ_SLOT( loadBackends() ) );
}
MediaManager::~MediaManager()
@@ -483,7 +483,7 @@ void MediaManager::slotMediumChanged(const TQString &/*id*/, const TQString &nam
extern "C" {
- KDE_EXPORT KDEDModule *create_mediamanager(const TQCString &obj)
+ TDE_EXPORT KDEDModule *create_mediamanager(const TQCString &obj)
{
TDEGlobal::locale()->insertCatalogue("tdeio_media");
return new MediaManager(obj);
diff --git a/tdeioslave/media/mediamanager/removablebackend.cpp b/tdeioslave/media/mediamanager/removablebackend.cpp
index dacb9b704..9e8b447f4 100644
--- a/tdeioslave/media/mediamanager/removablebackend.cpp
+++ b/tdeioslave/media/mediamanager/removablebackend.cpp
@@ -22,7 +22,7 @@
#include <kdirwatch.h>
#include <kurl.h>
#include <kmountpoint.h>
-#include <kstandarddirs.h>
+#include <tdestandarddirs.h>
#ifdef _OS_SOLARIS_
#define MTAB "/etc/mnttab"
@@ -37,8 +37,8 @@ RemovableBackend::RemovableBackend(MediaList &list)
{
KDirWatch::self()->addFile(MTAB);
- connect( KDirWatch::self(), TQT_SIGNAL( dirty(const TQString&) ),
- this, TQT_SLOT( slotDirty(const TQString&) ) );
+ connect( KDirWatch::self(), TQ_SIGNAL( dirty(const TQString&) ),
+ this, TQ_SLOT( slotDirty(const TQString&) ) );
KDirWatch::self()->startScan();
}
diff --git a/tdeioslave/media/mediamanager/tdehardwarebackend.cpp b/tdeioslave/media/mediamanager/tdehardwarebackend.cpp
index b12aa6ea9..d26188927 100644
--- a/tdeioslave/media/mediamanager/tdehardwarebackend.cpp
+++ b/tdeioslave/media/mediamanager/tdehardwarebackend.cpp
@@ -27,13 +27,13 @@
#include <tdelocale.h>
#include <tdeconfig.h>
#include <tdeio/job.h>
-#include <kprocess.h>
+#include <tdeprocess.h>
#include <kmimetype.h>
#include <kmountpoint.h>
#include <tdemessagebox.h>
#include <tdeapplication.h>
#include <kprotocolinfo.h>
-#include <kstandarddirs.h>
+#include <tdestandarddirs.h>
#include "dialog.h"
@@ -55,9 +55,9 @@ TDEBackend::TDEBackend(MediaList &list, TQObject* parent)
TDEHardwareDevices *hwdevices = TDEGlobal::hardwareDevices();
// Connect device monitoring signals/slots
- connect(hwdevices, TQT_SIGNAL(hardwareAdded(TDEGenericDevice*)), this, TQT_SLOT(AddDeviceHandler(TDEGenericDevice*)));
- connect(hwdevices, TQT_SIGNAL(hardwareRemoved(TDEGenericDevice*)), this, TQT_SLOT(RemoveDeviceHandler(TDEGenericDevice*)));
- connect(hwdevices, TQT_SIGNAL(hardwareUpdated(TDEGenericDevice*)), this, TQT_SLOT(ModifyDeviceHandler(TDEGenericDevice*)));
+ connect(hwdevices, TQ_SIGNAL(hardwareAdded(TDEGenericDevice*)), this, TQ_SLOT(AddDeviceHandler(TDEGenericDevice*)));
+ connect(hwdevices, TQ_SIGNAL(hardwareRemoved(TDEGenericDevice*)), this, TQ_SLOT(RemoveDeviceHandler(TDEGenericDevice*)));
+ connect(hwdevices, TQ_SIGNAL(hardwareUpdated(TDEGenericDevice*)), this, TQ_SLOT(ModifyDeviceHandler(TDEGenericDevice*)));
// List devices at startup
ListDevices();
@@ -771,9 +771,8 @@ void TDEBackend::setVolumeProperties(Medium* medium)
diskLabel = i18n("%1 Fixed Disk (%2)").arg(sdevice->deviceFriendlySize(), sdevice->deviceNode());
}
- if (sdevice->isDiskOfType(TDEDiskDeviceType::USB)
- || sdevice->checkDiskStatus(TDEDiskDeviceStatus::Removable)
- || sdevice->checkDiskStatus(TDEDiskDeviceStatus::Hotpluggable)) {
+ if (sdevice->isDiskOfType(TDEDiskDeviceType::USB) ||
+ sdevice->checkDiskStatus(TDEDiskDeviceStatus::Removable)) {
mimeType = "media/removable" + MOUNT_MEDIA_SUFFIX;
if (useDefaultLabel) {
diskLabel = i18n("%1 Removable Disk (%2)").arg(sdevice->deviceFriendlySize(), sdevice->deviceNode());
@@ -910,7 +909,7 @@ void TDEBackend::setCameraProperties(Medium* medium)
TQString device = "camera:/";
- TQStringList devNodeList = TQStringList::split("/", sdevice->deviceNode(), TRUE);
+ TQStringList devNodeList = TQStringList::split("/", sdevice->deviceNode(), true);
TQString devNode0 = devNodeList[devNodeList.count()-2];
TQString devNode1 = devNodeList[devNodeList.count()-1];
@@ -1035,7 +1034,7 @@ TQStringList TDEBackend::mountoptions(const TQString &name)
bool removable = false;
if (!drive_udi.isNull()) {
- removable = ((sdevice->checkDiskStatus(TDEDiskDeviceStatus::Removable)) || (sdevice->checkDiskStatus(TDEDiskDeviceStatus::Hotpluggable)));
+ removable = sdevice->checkDiskStatus(TDEDiskDeviceStatus::Removable);
}
TQString tmp;
@@ -1235,12 +1234,12 @@ TQStringVariantMap TDEBackend::mount(const Medium *medium)
data.medium = medium;
TDEIO::Job *job = TDEIO::mount(false, 0, medium->deviceNode(), mountPoint);
- connect(job, TQT_SIGNAL(result(TDEIO::Job*)), TQT_SLOT(slotResult(TDEIO::Job*)));
+ connect(job, TQ_SIGNAL(result(TDEIO::Job*)), TQ_SLOT(slotResult(TDEIO::Job*)));
mount_jobs[job] = &data;
// The caller expects the device to be mounted when the function
// completes. Thus block until the job completes.
while (!data.completed) {
- kapp->eventLoop()->enterLoop();
+ tdeApp->eventLoop()->enterLoop();
}
if (!data.error) {
result["result"] = true;
@@ -1269,7 +1268,7 @@ TQStringVariantMap TDEBackend::mount(const Medium *medium)
}
if (diskLabel.isEmpty()) {
// Try to use a pretty mount point if possible
- TQStringList pieces = TQStringList::split("/", sdevice->deviceNode(), FALSE);
+ TQStringList pieces = TQStringList::split("/", sdevice->deviceNode(), false);
TQString node = pieces[pieces.count()-1];
diskLabel = medium->label() + " (" + node + ")";
diskLabel.replace("/", "_");
@@ -1346,12 +1345,12 @@ TQStringVariantMap TDEBackend::unmount(const TQString &id)
data.medium = medium;
TDEIO::Job *job = TDEIO::unmount( medium->mountPoint(), false );
- connect(job, TQT_SIGNAL(result(TDEIO::Job*)), TQT_SLOT(slotResult(TDEIO::Job*)));
+ connect(job, TQ_SIGNAL(result(TDEIO::Job*)), TQ_SLOT(slotResult(TDEIO::Job*)));
mount_jobs[job] = &data;
// The caller expects the device to be unmounted when the function
// completes. Thus block until the job completes.
while (!data.completed) {
- kapp->eventLoop()->enterLoop();
+ tdeApp->eventLoop()->enterLoop();
}
if (!data.error) {
result["result"] = true;
@@ -1683,7 +1682,7 @@ void TDEBackend::slotResult(TDEIO::Job *job)
/* Job completed. Notify the caller */
data->error = job->error();
data->completed = true;
- kapp->eventLoop()->exitLoop();
+ tdeApp->eventLoop()->exitLoop();
}
TQString TDEBackend::isInFstab(const Medium *medium)