summaryrefslogtreecommitdiffstats
path: root/k9devices/k9cddrive.h
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-02-17 00:32:19 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-02-17 00:32:19 +0000
commit0d382a262c0638d0f572fc37193ccc5ed3dc895f (patch)
tree8578dcddfce4191f3f7a142a37769df7add48475 /k9devices/k9cddrive.h
downloadk9copy-0d382a262c0638d0f572fc37193ccc5ed3dc895f.tar.gz
k9copy-0d382a262c0638d0f572fc37193ccc5ed3dc895f.zip
Added old abandoned version of k9copy
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/k9copy@1091546 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'k9devices/k9cddrive.h')
-rw-r--r--k9devices/k9cddrive.h87
1 files changed, 87 insertions, 0 deletions
diff --git a/k9devices/k9cddrive.h b/k9devices/k9cddrive.h
new file mode 100644
index 0000000..e64bc0f
--- /dev/null
+++ b/k9devices/k9cddrive.h
@@ -0,0 +1,87 @@
+//
+// C++ Interface: k9cddrive
+//
+// Description:
+//
+//
+// Author: Jean-Michel PETIT <[email protected]>, (C) 2007
+//
+// Copyright: See COPYING file that comes with this distribution
+//
+//
+#ifndef K9CDDRIVE_H
+#define K9CDDRIVE_H
+#include "k9common.h"
+
+#include <qobject.h>
+
+#include <qstring.h>
+#include <qstringlist.h>
+#include <qvaluelist.h>
+#ifndef HAVE_HAL
+#include <k3bdevice.h>
+#include <k3bdevicemanager.h>
+#endif
+
+
+/**
+ *@author
+ */
+class k9HalDevice;
+class k9HalConnection;
+
+class k9CdDrive : public QObject {
+ Q_OBJECT
+public:
+ k9CdDrive();
+ ~k9CdDrive();
+ int num;
+ QString name;
+ QString device;
+ bool canWriteCDR;
+ bool canReadDVD;
+ bool canWriteDVD;
+
+ void setWriteSpeeds(const QValueList< int >& _value);
+ QValueList< int > getWriteSpeeds() const;
+
+ #ifdef HAVE_HAL
+ void setDevice(k9HalDevice* _value) { m_Device = _value;}
+
+ k9HalDevice* getDevice() { return m_Device;}
+ #endif
+private:
+ QValueList <int> writeSpeeds;
+ #ifdef HAVE_HAL
+ k9HalDevice *m_Device;
+ #endif
+};
+
+class k9CdDrives : public QObject {
+ Q_OBJECT
+public:
+ k9CdDrives();
+ ~k9CdDrives();
+ /** No descriptions */
+ int count();
+ /** No descriptions */
+ k9CdDrive * getDrive(int num);
+ void eject(const QString & device);
+ void scanDrives();
+public slots:
+ void deviceAdded(k9HalDevice *device);
+ void deviceRemoved(k9HalDevice *device);
+signals:
+ void deviceAdded(k9CdDrive *drive);
+ void deviceRemoved(k9CdDrive *drive);
+private: // Private methods
+ #ifdef HAVE_HAL
+ k9HalConnection *m_connection;
+ void addDrive(k9HalDevice *_device);
+ #else
+ K3bDevice::DeviceManager *m_devMgr;
+ #endif
+ void readConfig();
+ QPtrList <k9CdDrive> drives;
+};
+#endif