diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-05-27 23:37:00 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-05-27 23:37:00 +0000 |
commit | b0e912c8b3d02a518fedda28c3180eb4794a7520 (patch) | |
tree | 07d344862562fab58cbe2df39d13d16f2e4d2bea /k9devices/k9halconnection.cpp | |
parent | 4d695ec81fe4d4335ee82c7a9346ad9c9e144ecc (diff) | |
download | k9copy-b0e912c8b3d02a518fedda28c3180eb4794a7520.tar.gz k9copy-b0e912c8b3d02a518fedda28c3180eb4794a7520.zip |
TQt4 convert k9copy
This enables compilation under both Qt3 and Qt4
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/k9copy@1233843 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'k9devices/k9halconnection.cpp')
-rw-r--r-- | k9devices/k9halconnection.cpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/k9devices/k9halconnection.cpp b/k9devices/k9halconnection.cpp index 4de67ac..12d23cb 100644 --- a/k9devices/k9halconnection.cpp +++ b/k9devices/k9halconnection.cpp @@ -31,8 +31,8 @@ void halDeviceRemoved (LibHalContext *ctx, const char *udi) { } -k9HalConnection::k9HalConnection(QObject *parent, const char *name) - : QObject(parent, name) +k9HalConnection::k9HalConnection(TQObject *tqparent, const char *name) + : TQObject(tqparent, name) { m_devices.setAutoDelete(true); m_context =(void*) libhal_ctx_new(); @@ -41,7 +41,7 @@ k9HalConnection::k9HalConnection(QObject *parent, const char *name) dbus_error_init( &error ); m_dbusConnect = dbus_bus_get( DBUS_BUS_SYSTEM, &error ); if( dbus_error_is_set(&error) ) { - qDebug(QString("Error connecting to DBUS : %1").arg(error.message)); + qDebug(TQString("Error connecting to DBUS : %1").tqarg(error.message)); return; } @@ -82,7 +82,7 @@ void k9HalConnection::addDevice( const char* udi ) if( libhal_device_query_capability( (LibHalContext*) m_context, udi, "storage.cdrom", 0 ) ) { char* dev = libhal_device_get_property_string( (LibHalContext*) m_context, udi, "block.device", 0 ); if( dev ) { - QString s( dev ); + TQString s( dev ); libhal_free_string( dev ); if( !s.isEmpty() ) { @@ -104,7 +104,7 @@ void k9HalConnection::testVolumeChanged( const char * udi) { } else if( libhal_device_query_capability( (LibHalContext*) m_context, udi, "volume", 0 ) ) { - char* udiParent = libhal_device_get_property_string( (LibHalContext*) m_context, udi, "info.parent", 0 ); + char* udiParent = libhal_device_get_property_string( (LibHalContext*) m_context, udi, "info.tqparent", 0 ); if( udiParent ) { k9HalDevice *device=findDevice( udiParent); libhal_free_string( udiParent ); @@ -120,9 +120,9 @@ k9HalConnection::~k9HalConnection() libhal_ctx_shutdown((LibHalContext*)m_context, 0 ); libhal_ctx_free ((LibHalContext*)m_context); #ifdef DBUS_QT3 - //QDBusConnection::closeConnection("sbus"); + //TQDBusConnection::closeConnection("sbus"); #else - //delete m_dBusQtConnect; + //delete m_dBusTQtConnect; #endif } @@ -135,7 +135,7 @@ k9HalConnection * k9HalConnection::getInstance() { k9HalDevice *k9HalConnection::findDevice( const char *udi) { for (k9HalDevice *dev= m_devices.first();dev;dev=m_devices.next()) { - if (dev->name()==QString(udi)) + if (dev->name()==TQString(udi)) return dev; } return NULL; @@ -143,7 +143,7 @@ k9HalDevice *k9HalConnection::findDevice( const char *udi) { k9HalDevice *k9HalConnection::findDeviceByVolume( const char *udi) { for (k9HalDevice *dev= m_devices.first();dev;dev=m_devices.next()) { - if (dev->getVolumeUdi()==QString(udi)) + if (dev->getVolumeUdi()==TQString(udi)) return dev; } return NULL; |