author | wimpie <wimpie> | 2005-01-07 01:19:13 (UTC) |
---|---|---|
committer | wimpie <wimpie> | 2005-01-07 01:19:13 (UTC) |
commit | 7af7203a51ddcf85f9f60e39157fcad21f7d9e34 (patch) (unidiff) | |
tree | 49829585a0100a5a741d55424f86be39c01d3150 /noncore/settings/networksettings2/opietooth2 | |
parent | a8e5ecd107a79f940d8a99d4a77071606a3a932f (diff) | |
download | opie-7af7203a51ddcf85f9f60e39157fcad21f7d9e34.zip opie-7af7203a51ddcf85f9f60e39157fcad21f7d9e34.tar.gz opie-7af7203a51ddcf85f9f60e39157fcad21f7d9e34.tar.bz2 |
First implementation of plugins
THIS VERSION DOES NOT COMPILE
Diffstat (limited to 'noncore/settings/networksettings2/opietooth2') (more/less context) (ignore whitespace changes)
12 files changed, 20 insertions, 20 deletions
diff --git a/noncore/settings/networksettings2/opietooth2/OTDevice.h b/noncore/settings/networksettings2/opietooth2/OTDevice.h index cf1c4b6..09de7ee 100644 --- a/noncore/settings/networksettings2/opietooth2/OTDevice.h +++ b/noncore/settings/networksettings2/opietooth2/OTDevice.h | |||
@@ -7,26 +7,26 @@ | |||
7 | #include <bluezlib.h> | 7 | #include <bluezlib.h> |
8 | 8 | ||
9 | #include <OTGateway.h> | 9 | #include <OTGateway.h> |
10 | 10 | ||
11 | // define if you want to use the process hciattach for detection | 11 | // define if you want to use the process hciattach for detection |
12 | // #define USEHCIPROC | 12 | // #define USEHCIPROC |
13 | 13 | ||
14 | class QTimerEvent; | 14 | class QTimerEvent; |
15 | 15 | ||
16 | namespace Opie { | 16 | namespace Opie { |
17 | namespace Core { | 17 | namespace Core { |
18 | class OProcess; | 18 | class OProcess; |
19 | }; | 19 | } |
20 | }; | 20 | } |
21 | 21 | ||
22 | namespace Opietooth2 { | 22 | namespace Opietooth2 { |
23 | 23 | ||
24 | /** | 24 | /** |
25 | * Device takes care of attaching serial | 25 | * Device takes care of attaching serial |
26 | * devices to the blueZ stack. | 26 | * devices to the blueZ stack. |
27 | * After attaching it hciconfig ups it | 27 | * After attaching it hciconfig ups it |
28 | */ | 28 | */ |
29 | class OTDevice : public QObject { | 29 | class OTDevice : public QObject { |
30 | 30 | ||
31 | Q_OBJECT | 31 | Q_OBJECT |
32 | 32 | ||
@@ -102,15 +102,15 @@ namespace Opietooth2 { | |||
102 | unsigned long & Speed ); | 102 | unsigned long & Speed ); |
103 | pid_t getPidOfHCIAttach( void ); | 103 | pid_t getPidOfHCIAttach( void ); |
104 | 104 | ||
105 | Opie::Core::OProcess* m_hciattach; // ptr to hciattach proces | 105 | Opie::Core::OProcess* m_hciattach; // ptr to hciattach proces |
106 | 106 | ||
107 | int m_deviceNr; // x as in hci(x) | 107 | int m_deviceNr; // x as in hci(x) |
108 | pid_t m_hciattachPid; // pid of hciattach program | 108 | pid_t m_hciattachPid; // pid of hciattach program |
109 | 109 | ||
110 | // backpointer | 110 | // backpointer |
111 | OTGateway * OT; | 111 | OTGateway * OT; |
112 | bool NeedsAttach; | 112 | bool NeedsAttach; |
113 | }; | 113 | }; |
114 | }; | 114 | } |
115 | 115 | ||
116 | #endif | 116 | #endif |
diff --git a/noncore/settings/networksettings2/opietooth2/OTDeviceAddress.h b/noncore/settings/networksettings2/opietooth2/OTDeviceAddress.h index 50f28fc..8395f37 100644 --- a/noncore/settings/networksettings2/opietooth2/OTDeviceAddress.h +++ b/noncore/settings/networksettings2/opietooth2/OTDeviceAddress.h | |||
@@ -94,15 +94,15 @@ public: | |||
94 | static const OTDeviceAddress any; | 94 | static const OTDeviceAddress any; |
95 | 95 | ||
96 | /** An address tagged as invalid */ | 96 | /** An address tagged as invalid */ |
97 | static const OTDeviceAddress invalid; | 97 | static const OTDeviceAddress invalid; |
98 | 98 | ||
99 | protected: | 99 | protected: |
100 | 100 | ||
101 | bdaddr_t BDaddr; | 101 | bdaddr_t BDaddr; |
102 | bool IsValid; | 102 | bool IsValid; |
103 | 103 | ||
104 | }; | 104 | }; |
105 | 105 | ||
106 | }; | 106 | } |
107 | 107 | ||
108 | #endif | 108 | #endif |
diff --git a/noncore/settings/networksettings2/opietooth2/OTDriver.h b/noncore/settings/networksettings2/opietooth2/OTDriver.h index f249cf7..b54ffdf 100644 --- a/noncore/settings/networksettings2/opietooth2/OTDriver.h +++ b/noncore/settings/networksettings2/opietooth2/OTDriver.h | |||
@@ -219,14 +219,14 @@ private: | |||
219 | 219 | ||
220 | int Dev_id,Fd,Type; | 220 | int Dev_id,Fd,Type; |
221 | bool IsUp; | 221 | bool IsUp; |
222 | int Iscan,Pscan,Auth,Encrypt; | 222 | int Iscan,Pscan,Auth,Encrypt; |
223 | 223 | ||
224 | // socket bound to this device | 224 | // socket bound to this device |
225 | OTHCISocket * Socket; | 225 | OTHCISocket * Socket; |
226 | 226 | ||
227 | // backpointer to opietooth system | 227 | // backpointer to opietooth system |
228 | OTGateway * OT; | 228 | OTGateway * OT; |
229 | }; | 229 | }; |
230 | 230 | ||
231 | }; | 231 | } |
232 | #endif | 232 | #endif |
diff --git a/noncore/settings/networksettings2/opietooth2/OTGateway.h b/noncore/settings/networksettings2/opietooth2/OTGateway.h index a47cefb..d97ef35 100644 --- a/noncore/settings/networksettings2/opietooth2/OTGateway.h +++ b/noncore/settings/networksettings2/opietooth2/OTGateway.h | |||
@@ -186,15 +186,15 @@ private : | |||
186 | 186 | ||
187 | OTDriver * ScanWith; | 187 | OTDriver * ScanWith; |
188 | OTDriverList AllDrivers; | 188 | OTDriverList AllDrivers; |
189 | OTDevice * TheOTDevice; | 189 | OTDevice * TheOTDevice; |
190 | int HciCtl; | 190 | int HciCtl; |
191 | int ErrorConnectCount; | 191 | int ErrorConnectCount; |
192 | int RefreshTimer; | 192 | int RefreshTimer; |
193 | OTInquiry * Scanning; | 193 | OTInquiry * Scanning; |
194 | bool AllPeersModified; | 194 | bool AllPeersModified; |
195 | PeerVector AllPeers; | 195 | PeerVector AllPeers; |
196 | LinkKeyArray AllKeys; | 196 | LinkKeyArray AllKeys; |
197 | }; | 197 | }; |
198 | }; | 198 | } |
199 | 199 | ||
200 | #endif | 200 | #endif |
diff --git a/noncore/settings/networksettings2/opietooth2/OTHCISocket.h b/noncore/settings/networksettings2/opietooth2/OTHCISocket.h index d508078..a004989 100644 --- a/noncore/settings/networksettings2/opietooth2/OTHCISocket.h +++ b/noncore/settings/networksettings2/opietooth2/OTHCISocket.h | |||
@@ -102,15 +102,15 @@ private: | |||
102 | unsigned short LastStatusOcf; | 102 | unsigned short LastStatusOcf; |
103 | unsigned char LastStatusOgf; | 103 | unsigned char LastStatusOgf; |
104 | int LastStatus; | 104 | int LastStatus; |
105 | 105 | ||
106 | private slots: | 106 | private slots: |
107 | 107 | ||
108 | void slotSocketActivated(); | 108 | void slotSocketActivated(); |
109 | void slotSocketError(int); | 109 | void slotSocketError(int); |
110 | void slotConnectionClosed(); | 110 | void slotConnectionClosed(); |
111 | 111 | ||
112 | }; | 112 | }; |
113 | 113 | ||
114 | }; | 114 | } |
115 | 115 | ||
116 | #endif | 116 | #endif |
diff --git a/noncore/settings/networksettings2/opietooth2/OTIcons.h b/noncore/settings/networksettings2/opietooth2/OTIcons.h index 966ed24..ee10831 100644 --- a/noncore/settings/networksettings2/opietooth2/OTIcons.h +++ b/noncore/settings/networksettings2/opietooth2/OTIcons.h | |||
@@ -40,15 +40,15 @@ public: | |||
40 | // set Sub to find icons in .../Icons dir | 40 | // set Sub to find icons in .../Icons dir |
41 | QPixmap loadPixmap( const QString &, bool Sub = 0 ); | 41 | QPixmap loadPixmap( const QString &, bool Sub = 0 ); |
42 | 42 | ||
43 | private: | 43 | private: |
44 | 44 | ||
45 | // first ist id, second is icon name | 45 | // first ist id, second is icon name |
46 | QMap<QString,QString> deviceIcons; | 46 | QMap<QString,QString> deviceIcons; |
47 | QMap<int,QString> serviceIcons; | 47 | QMap<int,QString> serviceIcons; |
48 | UUIDVector Modems; | 48 | UUIDVector Modems; |
49 | UUIDVector Networks; | 49 | UUIDVector Networks; |
50 | 50 | ||
51 | }; | 51 | }; |
52 | }; | 52 | } |
53 | 53 | ||
54 | #endif | 54 | #endif |
diff --git a/noncore/settings/networksettings2/opietooth2/OTInquiry.h b/noncore/settings/networksettings2/opietooth2/OTInquiry.h index 2682499..f7bdeec 100644 --- a/noncore/settings/networksettings2/opietooth2/OTInquiry.h +++ b/noncore/settings/networksettings2/opietooth2/OTInquiry.h | |||
@@ -165,14 +165,14 @@ private: | |||
165 | 165 | ||
166 | // std::deque<InquiryInfo> infoQueue; | 166 | // std::deque<InquiryInfo> infoQueue; |
167 | bool SuccessfullyStarted; | 167 | bool SuccessfullyStarted; |
168 | bool SuccessfullyEnded; | 168 | bool SuccessfullyEnded; |
169 | 169 | ||
170 | private slots: | 170 | private slots: |
171 | 171 | ||
172 | void slotInquiryTimeout(); | 172 | void slotInquiryTimeout(); |
173 | void slotHCIEvent(unsigned char eventCode, QByteArray buf); | 173 | void slotHCIEvent(unsigned char eventCode, QByteArray buf); |
174 | 174 | ||
175 | }; | 175 | }; |
176 | 176 | ||
177 | }; | 177 | } |
178 | #endif | 178 | #endif |
diff --git a/noncore/settings/networksettings2/opietooth2/OTPeer.h b/noncore/settings/networksettings2/opietooth2/OTPeer.h index 9cd0dc7..c09af15 100644 --- a/noncore/settings/networksettings2/opietooth2/OTPeer.h +++ b/noncore/settings/networksettings2/opietooth2/OTPeer.h | |||
@@ -121,15 +121,15 @@ private: | |||
121 | QString Name; | 121 | QString Name; |
122 | int Class; | 122 | int Class; |
123 | ServiceVector serviceList; | 123 | ServiceVector serviceList; |
124 | // -1 : don't know, 0 no, 1 yes | 124 | // -1 : don't know, 0 no, 1 yes |
125 | PeerState_t State; | 125 | PeerState_t State; |
126 | OTDriver * ConnectedTo; | 126 | OTDriver * ConnectedTo; |
127 | 127 | ||
128 | int ProbeFD; | 128 | int ProbeFD; |
129 | int ProbePhase; // see OTDriver | 129 | int ProbePhase; // see OTDriver |
130 | long ProbeTimeout; | 130 | long ProbeTimeout; |
131 | }; | 131 | }; |
132 | 132 | ||
133 | }; | 133 | } |
134 | 134 | ||
135 | #endif | 135 | #endif |
diff --git a/noncore/settings/networksettings2/opietooth2/OTSDPAttribute.h b/noncore/settings/networksettings2/opietooth2/OTSDPAttribute.h index 86b5623..e79e33d 100644 --- a/noncore/settings/networksettings2/opietooth2/OTSDPAttribute.h +++ b/noncore/settings/networksettings2/opietooth2/OTSDPAttribute.h | |||
@@ -126,15 +126,15 @@ private: | |||
126 | 126 | ||
127 | union { | 127 | union { |
128 | OTSDPAttribute::int128_t * intVal; | 128 | OTSDPAttribute::int128_t * intVal; |
129 | OTSDPAttribute::uint128_t * uintVal; | 129 | OTSDPAttribute::uint128_t * uintVal; |
130 | OTUUID * uuidVal; | 130 | OTUUID * uuidVal; |
131 | bool boolVal; | 131 | bool boolVal; |
132 | QString * stringVal; // strings and urls | 132 | QString * stringVal; // strings and urls |
133 | AttributeVector * sequenceVal; // sequences and alternatives | 133 | AttributeVector * sequenceVal; // sequences and alternatives |
134 | } Value; | 134 | } Value; |
135 | 135 | ||
136 | }; | 136 | }; |
137 | 137 | ||
138 | }; | 138 | } |
139 | 139 | ||
140 | #endif | 140 | #endif |
diff --git a/noncore/settings/networksettings2/opietooth2/OTSDPService.h b/noncore/settings/networksettings2/opietooth2/OTSDPService.h index 21d7344..4831df0 100644 --- a/noncore/settings/networksettings2/opietooth2/OTSDPService.h +++ b/noncore/settings/networksettings2/opietooth2/OTSDPService.h | |||
@@ -61,15 +61,15 @@ public: | |||
61 | bool hasClassID(const OTUUID & uuid); | 61 | bool hasClassID(const OTUUID & uuid); |
62 | 62 | ||
63 | private: | 63 | private: |
64 | 64 | ||
65 | struct AttributeEntry { | 65 | struct AttributeEntry { |
66 | int id; | 66 | int id; |
67 | OTSDPAttribute * attr; | 67 | OTSDPAttribute * attr; |
68 | }; | 68 | }; |
69 | 69 | ||
70 | QArray<AttributeEntry> attributeList; | 70 | QArray<AttributeEntry> attributeList; |
71 | }; | 71 | }; |
72 | 72 | ||
73 | }; | 73 | } |
74 | 74 | ||
75 | #endif | 75 | #endif |
diff --git a/noncore/settings/networksettings2/opietooth2/OTUUID.h b/noncore/settings/networksettings2/opietooth2/OTUUID.h index 97df114..aebd9b9 100644 --- a/noncore/settings/networksettings2/opietooth2/OTUUID.h +++ b/noncore/settings/networksettings2/opietooth2/OTUUID.h | |||
@@ -45,14 +45,14 @@ public : | |||
45 | 45 | ||
46 | QString toString() const ; | 46 | QString toString() const ; |
47 | operator QString() const; | 47 | operator QString() const; |
48 | operator ::uuid_t() const; | 48 | operator ::uuid_t() const; |
49 | 49 | ||
50 | OTUUID & operator=( const OTUUID & other ) ; | 50 | OTUUID & operator=( const OTUUID & other ) ; |
51 | bool operator<( const OTUUID & other ) const; | 51 | bool operator<( const OTUUID & other ) const; |
52 | bool operator==(const OTUUID & uuid) const; | 52 | bool operator==(const OTUUID & uuid) const; |
53 | 53 | ||
54 | uint64_t hi; | 54 | uint64_t hi; |
55 | uint64_t lo; | 55 | uint64_t lo; |
56 | }; | 56 | }; |
57 | }; | 57 | } |
58 | #endif | 58 | #endif |
diff --git a/noncore/settings/networksettings2/opietooth2/Opietooth.h b/noncore/settings/networksettings2/opietooth2/Opietooth.h index e66787f..f077dd7 100644 --- a/noncore/settings/networksettings2/opietooth2/Opietooth.h +++ b/noncore/settings/networksettings2/opietooth2/Opietooth.h | |||
@@ -2,27 +2,27 @@ | |||
2 | #define OPIETOOTH_H | 2 | #define OPIETOOTH_H |
3 | 3 | ||
4 | #include <OTIcons.h> | 4 | #include <OTIcons.h> |
5 | 5 | ||
6 | class MyProcess; | 6 | class MyProcess; |
7 | 7 | ||
8 | namespace Opie { | 8 | namespace Opie { |
9 | 9 | ||
10 | namespace Ui { | 10 | namespace Ui { |
11 | 11 | ||
12 | class OLedBox; | 12 | class OLedBox; |
13 | 13 | ||
14 | }; | 14 | } |
15 | 15 | ||
16 | }; | 16 | } |
17 | 17 | ||
18 | #include <OTSniffGUI.h> | 18 | #include <OTSniffGUI.h> |
19 | namespace Opietooth2 { | 19 | namespace Opietooth2 { |
20 | 20 | ||
21 | class OTGateway; | 21 | class OTGateway; |
22 | class OTDriver; | 22 | class OTDriver; |
23 | class OTInquiry; | 23 | class OTInquiry; |
24 | class OTPeer; | 24 | class OTPeer; |
25 | class PeerLVI; | 25 | class PeerLVI; |
26 | 26 | ||
27 | class OTSniffing : public OTSniffGUI { | 27 | class OTSniffing : public OTSniffGUI { |
28 | 28 | ||
@@ -42,25 +42,25 @@ private slots : | |||
42 | void SLOT_ProcessExited( MyProcess * ); | 42 | void SLOT_ProcessExited( MyProcess * ); |
43 | void SLOT_Show( const QString & ); | 43 | void SLOT_Show( const QString & ); |
44 | 44 | ||
45 | signals : | 45 | signals : |
46 | 46 | ||
47 | protected : | 47 | protected : |
48 | 48 | ||
49 | private : | 49 | private : |
50 | 50 | ||
51 | OTGateway * OT; | 51 | OTGateway * OT; |
52 | MyProcess * HciDump; | 52 | MyProcess * HciDump; |
53 | }; | 53 | }; |
54 | }; | 54 | } |
55 | 55 | ||
56 | #include <OTPairingGUI.h> | 56 | #include <OTPairingGUI.h> |
57 | 57 | ||
58 | namespace Opietooth2 { | 58 | namespace Opietooth2 { |
59 | class OTPairing : public OTPairingGUI { | 59 | class OTPairing : public OTPairingGUI { |
60 | 60 | ||
61 | Q_OBJECT | 61 | Q_OBJECT |
62 | 62 | ||
63 | public : | 63 | public : |
64 | 64 | ||
65 | OTPairing( QWidget * parent, | 65 | OTPairing( QWidget * parent, |
66 | OTIcons * _Ic = 0 ); | 66 | OTIcons * _Ic = 0 ); |
@@ -71,25 +71,25 @@ private slots : | |||
71 | void SLOT_Unpair( void ); | 71 | void SLOT_Unpair( void ); |
72 | 72 | ||
73 | signals : | 73 | signals : |
74 | 74 | ||
75 | protected : | 75 | protected : |
76 | 76 | ||
77 | private : | 77 | private : |
78 | 78 | ||
79 | bool MyIcons; | 79 | bool MyIcons; |
80 | OTIcons * Icons; | 80 | OTIcons * Icons; |
81 | OTGateway * OT; | 81 | OTGateway * OT; |
82 | }; | 82 | }; |
83 | }; | 83 | } |
84 | 84 | ||
85 | #include <OTScanGUI.h> | 85 | #include <OTScanGUI.h> |
86 | 86 | ||
87 | namespace Opietooth2 { | 87 | namespace Opietooth2 { |
88 | 88 | ||
89 | class OTGateway; | 89 | class OTGateway; |
90 | class OTDriver; | 90 | class OTDriver; |
91 | class OTInquiry; | 91 | class OTInquiry; |
92 | class OTPeer; | 92 | class OTPeer; |
93 | 93 | ||
94 | class OTScan : public OTScanGUI { | 94 | class OTScan : public OTScanGUI { |
95 | 95 | ||
@@ -149,25 +149,25 @@ private : | |||
149 | OTIcons * Icons; | 149 | OTIcons * Icons; |
150 | OTGateway * OT; | 150 | OTGateway * OT; |
151 | OTInquiry * Scanning; | 151 | OTInquiry * Scanning; |
152 | UUIDVector Filter; | 152 | UUIDVector Filter; |
153 | 153 | ||
154 | Opie::Ui::OLedBox * Paired_Led; | 154 | Opie::Ui::OLedBox * Paired_Led; |
155 | QTimer * StrengthTimer; | 155 | QTimer * StrengthTimer; |
156 | PeerLVI * Current; | 156 | PeerLVI * Current; |
157 | 157 | ||
158 | OTPeer * SelectedPeer; | 158 | OTPeer * SelectedPeer; |
159 | int SelectedChannel; | 159 | int SelectedChannel; |
160 | }; | 160 | }; |
161 | }; | 161 | } |
162 | 162 | ||
163 | #include <OTManageGUI.h> | 163 | #include <OTManageGUI.h> |
164 | namespace Opietooth2 { | 164 | namespace Opietooth2 { |
165 | 165 | ||
166 | class OTManage : public OTManageGUI { | 166 | class OTManage : public OTManageGUI { |
167 | 167 | ||
168 | Q_OBJECT | 168 | Q_OBJECT |
169 | 169 | ||
170 | public : | 170 | public : |
171 | 171 | ||
172 | OTManage( QWidget * parent, | 172 | OTManage( QWidget * parent, |
173 | OTIcons * _IC = 0 ); | 173 | OTIcons * _IC = 0 ); |
@@ -187,25 +187,25 @@ signals : | |||
187 | 187 | ||
188 | protected : | 188 | protected : |
189 | 189 | ||
190 | private : | 190 | private : |
191 | 191 | ||
192 | // load scanned devices | 192 | // load scanned devices |
193 | 193 | ||
194 | bool MyIcons; | 194 | bool MyIcons; |
195 | OTIcons * Icons; | 195 | OTIcons * Icons; |
196 | OTGateway * OT; | 196 | OTGateway * OT; |
197 | OTInquiry * Scanning; | 197 | OTInquiry * Scanning; |
198 | }; | 198 | }; |
199 | }; | 199 | } |
200 | 200 | ||
201 | #include <OTMainGUI.h> | 201 | #include <OTMainGUI.h> |
202 | 202 | ||
203 | namespace Opietooth2 { | 203 | namespace Opietooth2 { |
204 | class OTMain : public OTMainGUI { | 204 | class OTMain : public OTMainGUI { |
205 | 205 | ||
206 | Q_OBJECT | 206 | Q_OBJECT |
207 | 207 | ||
208 | public : | 208 | public : |
209 | 209 | ||
210 | OTMain( QWidget * parent ); | 210 | OTMain( QWidget * parent ); |
211 | ~OTMain(); | 211 | ~OTMain(); |
@@ -225,14 +225,14 @@ private slots : | |||
225 | 225 | ||
226 | signals : | 226 | signals : |
227 | 227 | ||
228 | protected : | 228 | protected : |
229 | 229 | ||
230 | private : | 230 | private : |
231 | 231 | ||
232 | // load scanned devices | 232 | // load scanned devices |
233 | OTIcons * Icons; | 233 | OTIcons * Icons; |
234 | OTGateway * OT; | 234 | OTGateway * OT; |
235 | QDialog * SnifWindow; | 235 | QDialog * SnifWindow; |
236 | }; | 236 | }; |
237 | }; | 237 | } |
238 | #endif | 238 | #endif |