summaryrefslogtreecommitdiff
path: root/noncore/settings/networksettings/module.h
Unidiff
Diffstat (limited to 'noncore/settings/networksettings/module.h') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/settings/networksettings/module.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/noncore/settings/networksettings/module.h b/noncore/settings/networksettings/module.h
index 46a3c77..db74394 100644
--- a/noncore/settings/networksettings/module.h
+++ b/noncore/settings/networksettings/module.h
@@ -1,48 +1,55 @@
1#ifndef NETCONF_MODULE_H 1#ifndef NETCONF_MODULE_H
2#define NETCONF_MODULE_H 2#define NETCONF_MODULE_H
3 3
4#include <qobject.h> 4#include <qobject.h>
5#if QT_VERSION < 300 5#if QT_VERSION < 300
6#include <qlist.h> 6#include <qlist.h>
7#else 7#else
8#include <qptrlist.h> 8#include <qptrlist.h>
9#endif 9#endif
10#include <qmap.h> 10#include <qmap.h>
11#include "interface.h" 11#include "interface.h"
12 12
13class QWidget; 13class QWidget;
14class QTabWidget; 14class QTabWidget;
15 15
16class Module : QObject{ 16class Module : QObject{
17 17
18signals: 18signals:
19 void updateInterface(Interface *i); 19 void updateInterface(Interface *i);
20
20 21
21public: 22public:
22 Module(){}; 23 Module(){};
23 24
24 /** 25 /**
26 * The type of the plugin
27 * and the name of the dcop call
28 */
29 virtual const QString type() = 0;
30
31 /**
25 * The current profile has been changed and the module should do any 32 * The current profile has been changed and the module should do any
26 * neccesary changes also. 33 * neccesary changes also.
27 * @param newProfile what the profile should be changed to. 34 * @param newProfile what the profile should be changed to.
28 */ 35 */
29 virtual void setProfile(const QString &newProfile) = 0; 36 virtual void setProfile(const QString &newProfile) = 0;
30 37
31 /** 38 /**
32 * get the icon name for this device. 39 * get the icon name for this device.
33 * @param Interface* can be used in determining the icon. 40 * @param Interface* can be used in determining the icon.
34 * @return QString the icon name (minus .png, .gif etc) 41 * @return QString the icon name (minus .png, .gif etc)
35 */ 42 */
36 virtual QString getPixmapName(Interface *) = 0; 43 virtual QString getPixmapName(Interface *) = 0;
37 44
38 /** 45 /**
39 * Check to see if the interface i is owned by this module. 46 * Check to see if the interface i is owned by this module.
40 * @param Interface* interface to check against 47 * @param Interface* interface to check against
41 * @return bool true if i is owned by this module, false otherwise. 48 * @return bool true if i is owned by this module, false otherwise.
42 */ 49 */
43 virtual bool isOwner(Interface *){ return false; }; 50 virtual bool isOwner(Interface *){ return false; };
44 51
45 /** 52 /**
46 * Create and return the WLANConfigure Module 53 * Create and return the WLANConfigure Module
47 * @param Interface *i the interface to configure. 54 * @param Interface *i the interface to configure.
48 * @return QWidget* pointer to this modules configure. 55 * @return QWidget* pointer to this modules configure.
@@ -61,30 +68,35 @@ public:
61 * @return QList<Interface> A list of interfaces that exsist that havn't 68 * @return QList<Interface> A list of interfaces that exsist that havn't
62 * been called by isOwner() 69 * been called by isOwner()
63 */ 70 */
64 virtual QList<Interface> getInterfaces() = 0; 71 virtual QList<Interface> getInterfaces() = 0;
65 72
66 /** 73 /**
67 * Adds possible new interfaces to the list (Example: usb(ppp), ir(ppp), 74 * Adds possible new interfaces to the list (Example: usb(ppp), ir(ppp),
68 * modem ppp) 75 * modem ppp)
69 */ 76 */
70 virtual void possibleNewInterfaces(QMap<QString, QString> &list) = 0; 77 virtual void possibleNewInterfaces(QMap<QString, QString> &list) = 0;
71 78
72 /** 79 /**
73 * Attempts to create a new interface from name 80 * Attempts to create a new interface from name
74 * @return Interface* NULL if it was unable to be created. 81 * @return Interface* NULL if it was unable to be created.
75 * @param name the type of interface to create 82 * @param name the type of interface to create
76 */ 83 */
77 virtual Interface *addNewInterface(const QString &name) = 0; 84 virtual Interface *addNewInterface(const QString &name) = 0;
78 85
79 /** 86 /**
80 * Attempts to remove the interface, doesn't delete i 87 * Attempts to remove the interface, doesn't delete i
81 * @return bool true if successfull, false otherwise. 88 * @return bool true if successfull, false otherwise.
82 */ 89 */
83 virtual bool remove(Interface* i) = 0; 90 virtual bool remove(Interface* i) = 0;
84 91
92 /**
93 * get dcop calls
94 */
95 virtual void receive(const QCString &msg, const QByteArray &arg) = 0;
96
85}; 97};
86 98
87#endif 99#endif
88 100
89// module.h 101// module.h
90 102