-rw-r--r-- | core/pim/datebook/dateentry.ui | 40 | ||||
-rw-r--r-- | core/pim/datebook/dateentryimpl.cpp | 38 |
2 files changed, 61 insertions, 17 deletions
diff --git a/core/pim/datebook/dateentry.ui b/core/pim/datebook/dateentry.ui index dc5195f..1a712ec 100644 --- a/core/pim/datebook/dateentry.ui +++ b/core/pim/datebook/dateentry.ui | |||
@@ -1,94 +1,94 @@ | |||
1 | <!DOCTYPE UI><UI> | 1 | <!DOCTYPE UI><UI> |
2 | <class>DateEntryBase</class> | 2 | <class>DateEntryBase</class> |
3 | <comment>********************************************************************* | 3 | <comment>********************************************************************* |
4 | ** Copyright (C) 2000 Trolltech AS. All rights reserved. | 4 | ** Copyright (C) 2000 Trolltech AS. All rights reserved. |
5 | ** | 5 | ** |
6 | ** This file is part of Qtopia Environment. | 6 | ** This file is part of Qtopia Environment. |
7 | ** | 7 | ** |
8 | ** This file may be distributed and/or modified under the terms of the | 8 | ** This file may be distributed and/or modified under the terms of the |
9 | ** GNU General Public License version 2 as published by the Free Software | 9 | ** GNU General Public License version 2 as published by the Free Software |
10 | ** Foundation and appearing in the file LICENSE.GPL included in the | 10 | ** Foundation and appearing in the file LICENSE.GPL included in the |
11 | ** packaging of this file. | 11 | ** packaging of this file. |
12 | ** | 12 | ** |
13 | ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE | 13 | ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE |
14 | ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. | 14 | ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. |
15 | ** | 15 | ** |
16 | ** See http://www.trolltech.com/gpl/ for GPL licensing information. | 16 | ** See http://www.trolltech.com/gpl/ for GPL licensing information. |
17 | ** | 17 | ** |
18 | ** Contact info@trolltech.com if any conditions of this licensing are | 18 | ** Contact info@trolltech.com if any conditions of this licensing are |
19 | ** not clear to you. | 19 | ** not clear to you. |
20 | ** | 20 | ** |
21 | ** $Id$ | 21 | ** $Id$ |
22 | ** | 22 | ** |
23 | *********************************************************************</comment> | 23 | *********************************************************************</comment> |
24 | <widget> | 24 | <widget> |
25 | <class>QWidget</class> | 25 | <class>QWidget</class> |
26 | <property stdset="1"> | 26 | <property stdset="1"> |
27 | <name>name</name> | 27 | <name>name</name> |
28 | <cstring>DateEntryBase</cstring> | 28 | <cstring>DateEntryBase</cstring> |
29 | </property> | 29 | </property> |
30 | <property stdset="1"> | 30 | <property stdset="1"> |
31 | <name>geometry</name> | 31 | <name>geometry</name> |
32 | <rect> | 32 | <rect> |
33 | <x>0</x> | 33 | <x>0</x> |
34 | <y>0</y> | 34 | <y>0</y> |
35 | <width>242</width> | 35 | <width>242</width> |
36 | <height>339</height> | 36 | <height>339</height> |
37 | </rect> | 37 | </rect> |
38 | </property> | 38 | </property> |
39 | <property stdset="1"> | 39 | <property stdset="1"> |
40 | <name>caption</name> | 40 | <name>caption</name> |
41 | <string>New Event</string> | 41 | <string>New Event</string> |
42 | </property> | 42 | </property> |
43 | <grid> | 43 | <grid> |
44 | <property stdset="1"> | 44 | <property stdset="1"> |
45 | <name>margin</name> | 45 | <name>margin</name> |
46 | <number>0</number> | 46 | <number>2</number> |
47 | </property> | 47 | </property> |
48 | <property stdset="1"> | 48 | <property stdset="1"> |
49 | <name>spacing</name> | 49 | <name>spacing</name> |
50 | <number>0</number> | 50 | <number>0</number> |
51 | </property> | 51 | </property> |
52 | <widget row="1" column="0" > | 52 | <widget row="1" column="0" > |
53 | <class>QLabel</class> | 53 | <class>QLabel</class> |
54 | <property stdset="1"> | 54 | <property stdset="1"> |
55 | <name>name</name> | 55 | <name>name</name> |
56 | <cstring>TextLabel2</cstring> | 56 | <cstring>TextLabel2</cstring> |
57 | </property> | 57 | </property> |
58 | <property stdset="1"> | 58 | <property stdset="1"> |
59 | <name>frameShape</name> | 59 | <name>frameShape</name> |
60 | <enum>MShape</enum> | 60 | <enum>MShape</enum> |
61 | </property> | 61 | </property> |
62 | <property stdset="1"> | 62 | <property stdset="1"> |
63 | <name>frameShadow</name> | 63 | <name>frameShadow</name> |
64 | <enum>MShadow</enum> | 64 | <enum>MShadow</enum> |
65 | </property> | 65 | </property> |
66 | <property stdset="1"> | 66 | <property stdset="1"> |
67 | <name>text</name> | 67 | <name>text</name> |
68 | <string>Location</string> | 68 | <string>Location</string> |
69 | </property> | 69 | </property> |
70 | </widget> | 70 | </widget> |
71 | <widget row="2" column="0" > | 71 | <widget row="2" column="0" > |
72 | <class>QLabel</class> | 72 | <class>QLabel</class> |
73 | <property stdset="1"> | 73 | <property stdset="1"> |
74 | <name>name</name> | 74 | <name>name</name> |
75 | <cstring>TextLabel2_2</cstring> | 75 | <cstring>TextLabel2_2</cstring> |
76 | </property> | 76 | </property> |
77 | <property stdset="1"> | 77 | <property stdset="1"> |
78 | <name>text</name> | 78 | <name>text</name> |
79 | <string>Category</string> | 79 | <string>Category</string> |
80 | </property> | 80 | </property> |
81 | <property> | 81 | <property> |
82 | <name>buddy</name> | 82 | <name>buddy</name> |
83 | <cstring>comboPriority</cstring> | 83 | <cstring>comboPriority</cstring> |
84 | </property> | 84 | </property> |
85 | </widget> | 85 | </widget> |
86 | <widget row="0" column="1" rowspan="1" colspan="3" > | 86 | <widget row="0" column="1" rowspan="1" colspan="3" > |
87 | <class>QComboBox</class> | 87 | <class>QComboBox</class> |
88 | <item> | 88 | <item> |
89 | <property> | 89 | <property> |
90 | <name>text</name> | 90 | <name>text</name> |
91 | <string></string> | 91 | <string></string> |
92 | </property> | 92 | </property> |
93 | </item> | 93 | </item> |
94 | <item> | 94 | <item> |
@@ -102,279 +102,301 @@ | |||
102 | <name>text</name> | 102 | <name>text</name> |
103 | <string>Lunch</string> | 103 | <string>Lunch</string> |
104 | </property> | 104 | </property> |
105 | </item> | 105 | </item> |
106 | <item> | 106 | <item> |
107 | <property> | 107 | <property> |
108 | <name>text</name> | 108 | <name>text</name> |
109 | <string>Dinner</string> | 109 | <string>Dinner</string> |
110 | </property> | 110 | </property> |
111 | </item> | 111 | </item> |
112 | <item> | 112 | <item> |
113 | <property> | 113 | <property> |
114 | <name>text</name> | 114 | <name>text</name> |
115 | <string>Travel</string> | 115 | <string>Travel</string> |
116 | </property> | 116 | </property> |
117 | </item> | 117 | </item> |
118 | <property stdset="1"> | 118 | <property stdset="1"> |
119 | <name>name</name> | 119 | <name>name</name> |
120 | <cstring>comboDescription</cstring> | 120 | <cstring>comboDescription</cstring> |
121 | </property> | 121 | </property> |
122 | <property stdset="1"> | 122 | <property stdset="1"> |
123 | <name>sizePolicy</name> | 123 | <name>sizePolicy</name> |
124 | <sizepolicy> | 124 | <sizepolicy> |
125 | <hsizetype>7</hsizetype> | 125 | <hsizetype>7</hsizetype> |
126 | <vsizetype>0</vsizetype> | 126 | <vsizetype>0</vsizetype> |
127 | </sizepolicy> | 127 | </sizepolicy> |
128 | </property> | 128 | </property> |
129 | <property stdset="1"> | 129 | <property stdset="1"> |
130 | <name>editable</name> | 130 | <name>editable</name> |
131 | <bool>true</bool> | 131 | <bool>true</bool> |
132 | </property> | 132 | </property> |
133 | <property stdset="1"> | 133 | <property stdset="1"> |
134 | <name>currentItem</name> | 134 | <name>currentItem</name> |
135 | <number>0</number> | 135 | <number>0</number> |
136 | </property> | 136 | </property> |
137 | <property stdset="1"> | 137 | <property stdset="1"> |
138 | <name>duplicatesEnabled</name> | 138 | <name>duplicatesEnabled</name> |
139 | <bool>false</bool> | 139 | <bool>false</bool> |
140 | </property> | 140 | </property> |
141 | </widget> | 141 | </widget> |
142 | <widget row="0" column="0" > | 142 | <widget row="0" column="0" > |
143 | <class>QLabel</class> | 143 | <class>QLabel</class> |
144 | <property stdset="1"> | 144 | <property stdset="1"> |
145 | <name>name</name> | 145 | <name>name</name> |
146 | <cstring>TextLabel1</cstring> | 146 | <cstring>TextLabel1</cstring> |
147 | </property> | 147 | </property> |
148 | <property stdset="1"> | 148 | <property stdset="1"> |
149 | <name>text</name> | 149 | <name>text</name> |
150 | <string>Description</string> | 150 | <string>Description </string> |
151 | </property> | 151 | </property> |
152 | </widget> | 152 | </widget> |
153 | <widget row="1" column="1" rowspan="1" colspan="3" > | 153 | <widget row="1" column="1" rowspan="1" colspan="3" > |
154 | <class>QComboBox</class> | 154 | <class>QComboBox</class> |
155 | <item> | 155 | <item> |
156 | <property> | 156 | <property> |
157 | <name>text</name> | 157 | <name>text</name> |
158 | <string></string> | 158 | <string></string> |
159 | </property> | 159 | </property> |
160 | </item> | 160 | </item> |
161 | <item> | 161 | <item> |
162 | <property> | 162 | <property> |
163 | <name>text</name> | 163 | <name>text</name> |
164 | <string>Office</string> | 164 | <string>Office</string> |
165 | </property> | 165 | </property> |
166 | </item> | 166 | </item> |
167 | <item> | 167 | <item> |
168 | <property> | 168 | <property> |
169 | <name>text</name> | 169 | <name>text</name> |
170 | <string>Home</string> | 170 | <string>Home</string> |
171 | </property> | 171 | </property> |
172 | </item> | 172 | </item> |
173 | <property stdset="1"> | 173 | <property stdset="1"> |
174 | <name>name</name> | 174 | <name>name</name> |
175 | <cstring>comboLocation</cstring> | 175 | <cstring>comboLocation</cstring> |
176 | </property> | 176 | </property> |
177 | <property stdset="1"> | 177 | <property stdset="1"> |
178 | <name>sizePolicy</name> | 178 | <name>sizePolicy</name> |
179 | <sizepolicy> | 179 | <sizepolicy> |
180 | <hsizetype>7</hsizetype> | 180 | <hsizetype>7</hsizetype> |
181 | <vsizetype>0</vsizetype> | 181 | <vsizetype>0</vsizetype> |
182 | </sizepolicy> | 182 | </sizepolicy> |
183 | </property> | 183 | </property> |
184 | <property stdset="1"> | 184 | <property stdset="1"> |
185 | <name>editable</name> | 185 | <name>editable</name> |
186 | <bool>true</bool> | 186 | <bool>true</bool> |
187 | </property> | 187 | </property> |
188 | <property stdset="1"> | 188 | <property stdset="1"> |
189 | <name>currentItem</name> | 189 | <name>currentItem</name> |
190 | <number>0</number> | 190 | <number>0</number> |
191 | </property> | 191 | </property> |
192 | <property stdset="1"> | 192 | <property stdset="1"> |
193 | <name>duplicatesEnabled</name> | 193 | <name>duplicatesEnabled</name> |
194 | <bool>false</bool> | 194 | <bool>false</bool> |
195 | </property> | 195 | </property> |
196 | </widget> | 196 | </widget> |
197 | <widget row="2" column="1" rowspan="1" colspan="3" > | 197 | <widget row="2" column="1" rowspan="1" colspan="3" > |
198 | <class>CategorySelect</class> | 198 | <class>CategorySelect</class> |
199 | <property stdset="1"> | 199 | <property stdset="1"> |
200 | <name>name</name> | 200 | <name>name</name> |
201 | <cstring>comboCategory</cstring> | 201 | <cstring>comboCategory</cstring> |
202 | </property> | 202 | </property> |
203 | </widget> | 203 | </widget> |
204 | <widget row="3" column="0" rowspan="2"> | 204 | <widget row="3" column="0" rowspan="2"> |
205 | <class>QLabel</class> | 205 | <class>QLabel</class> |
206 | <property stdset="1"> | 206 | <property stdset="1"> |
207 | <name>name</name> | 207 | <name>name</name> |
208 | <cstring>TextLabel3</cstring> | 208 | <cstring>TextLabel3</cstring> |
209 | </property> | 209 | </property> |
210 | <property stdset="1"> | 210 | <property stdset="1"> |
211 | <name>text</name> | 211 | <name>text</name> |
212 | <string>Start - End</string> | 212 | <string>Start - End </string> |
213 | </property> | 213 | </property> |
214 | </widget> | 214 | </widget> |
215 | <widget row="3" column="1" > | 215 | <widget row="3" column="1" > |
216 | <class>QPushButton</class> | 216 | <class>QPushButton</class> |
217 | <property stdset="1"> | 217 | <property stdset="1"> |
218 | <name>name</name> | 218 | <name>name</name> |
219 | <cstring>buttonStart</cstring> | 219 | <cstring>buttonStart</cstring> |
220 | </property> | 220 | </property> |
221 | <property stdset="1"> | 221 | <property stdset="1"> |
222 | <name>text</name> | 222 | <name>text</name> |
223 | <string>Jan 02 00</string> | 223 | <string>Jan 02 00</string> |
224 | </property> | 224 | </property> |
225 | <property stdset="1"> | 225 | <property stdset="1"> |
226 | <name>minimumSize</name> | 226 | <name>minimumSize</name> |
227 | <size> | 227 | <size> |
228 | <width>70</width> | 228 | <width>70</width> |
229 | <height>0</height> | 229 | <height>0</height> |
230 | </size> | 230 | </size> |
231 | </property> | 231 | </property> |
232 | <property stdset="1"> | 232 | <property stdset="1"> |
233 | <name>maximumSize</name> | 233 | <name>maximumSize</name> |
234 | <size> | 234 | <size> |
235 | <width>70</width> | 235 | <width>70</width> |
236 | <height>32767</height> | 236 | <height>32767</height> |
237 | </size> | 237 | </size> |
238 | </property> | 238 | </property> |
239 | </widget> | 239 | </widget> |
240 | <widget row="4" column="1" rowspan="1" colspan="1" > | 240 | <widget row="4" column="1" rowspan="1" colspan="1" > |
241 | <class>QLineEdit</class> | 241 | <class>QLineEdit</class> |
242 | <property stdset="1"> | 242 | <property stdset="1"> |
243 | <name>name</name> | 243 | <name>name</name> |
244 | <cstring>comboStart</cstring> | 244 | <cstring>comboStart</cstring> |
245 | </property> | 245 | </property> |
246 | <property stdset="1"> | 246 | <property stdset="1"> |
247 | <name>minimumSize</name> | 247 | <name>minimumSize</name> |
248 | <size> | 248 | <size> |
249 | <width>70</width> | 249 | <width>70</width> |
250 | <height>0</height> | 250 | <height>0</height> |
251 | </size> | 251 | </size> |
252 | </property> | 252 | </property> |
253 | <property stdset="1"> | 253 | <property stdset="1"> |
254 | <name>maximumSize</name> | 254 | <name>maximumSize</name> |
255 | <size> | 255 | <size> |
256 | <width>70</width> | 256 | <width>70</width> |
257 | <height>32767</height> | 257 | <height>32767</height> |
258 | </size> | 258 | </size> |
259 | </property> | 259 | </property> |
260 | <property stdset="1"> | 260 | <property stdset="1"> |
261 | <name>alignment</name> | 261 | <name>alignment</name> |
262 | <set>AlignHCenter</set> | 262 | <set>AlignHCenter</set> |
263 | </property> | 263 | </property> |
264 | <property> | 264 | <property> |
265 | <name>hAlign</name> | 265 | <name>hAlign</name> |
266 | </property> | 266 | </property> |
267 | </widget> | 267 | </widget> |
268 | <spacer row="3" column="2" rowspan="2" colspan="1" > | ||
269 | <property> | ||
270 | <name>name</name> | ||
271 | <cstring>Spacer1_2</cstring> | ||
272 | </property> | ||
273 | <property stdset="1"> | ||
274 | <name>orientation</name> | ||
275 | <enum>Horizontal</enum> | ||
276 | </property> | ||
277 | <property stdset="1"> | ||
278 | <name>sizeType</name> | ||
279 | <enum>Expanding</enum> | ||
280 | </property> | ||
281 | <property> | ||
282 | <name>sizeHint</name> | ||
283 | <size> | ||
284 | <width>20</width> | ||
285 | <height>20</height> | ||
286 | </size> | ||
287 | </property> | ||
288 | </spacer> | ||
289 | |||
268 | <widget row="5" column="1" colspan="3"> | 290 | <widget row="5" column="1" colspan="3"> |
269 | <class>TimePicker</class> | 291 | <class>TimePicker</class> |
270 | <property stdset="1"> | 292 | <property stdset="1"> |
271 | <name>name</name> | 293 | <name>name</name> |
272 | <cstring>timePickerStart</cstring> | 294 | <cstring>timePickerStart</cstring> |
273 | </property> | 295 | </property> |
274 | </widget> | 296 | </widget> |
275 | <widget row="3" column="2" colspan="2"> | 297 | <widget row="3" column="3" colspan="1"> |
276 | <class>QPushButton</class> | 298 | <class>QPushButton</class> |
277 | <property stdset="1"> | 299 | <property stdset="1"> |
278 | <name>name</name> | 300 | <name>name</name> |
279 | <cstring>buttonEnd</cstring> | 301 | <cstring>buttonEnd</cstring> |
280 | </property> | 302 | </property> |
281 | <property stdset="1"> | 303 | <property stdset="1"> |
282 | <name>text</name> | 304 | <name>text</name> |
283 | <string>Jan 02 00</string> | 305 | <string>Jan 02 00</string> |
284 | </property> | 306 | </property> |
285 | <property stdset="1"> | 307 | <property stdset="1"> |
286 | <name>minimumSize</name> | 308 | <name>minimumSize</name> |
287 | <size> | 309 | <size> |
288 | <width>70</width> | 310 | <width>70</width> |
289 | <height>0</height> | 311 | <height>0</height> |
290 | </size> | 312 | </size> |
291 | </property> | 313 | </property> |
292 | <property stdset="1"> | 314 | <property stdset="1"> |
293 | <name>maximumSize</name> | 315 | <name>maximumSize</name> |
294 | <size> | 316 | <size> |
295 | <width>70</width> | 317 | <width>70</width> |
296 | <height>32767</height> | 318 | <height>32767</height> |
297 | </size> | 319 | </size> |
298 | </property> | 320 | </property> |
299 | </widget> | 321 | </widget> |
300 | <widget row="4" column="2" colspan="2"> | 322 | <widget row="4" column="3" colspan="1"> |
301 | <class>QLineEdit</class> | 323 | <class>QLineEdit</class> |
302 | <property stdset="1"> | 324 | <property stdset="1"> |
303 | <name>name</name> | 325 | <name>name</name> |
304 | <cstring>comboEnd</cstring> | 326 | <cstring>comboEnd</cstring> |
305 | </property> | 327 | </property> |
306 | <property stdset="1"> | 328 | <property stdset="1"> |
307 | <name>minimumSize</name> | 329 | <name>minimumSize</name> |
308 | <size> | 330 | <size> |
309 | <width>70</width> | 331 | <width>70</width> |
310 | <height>0</height> | 332 | <height>0</height> |
311 | </size> | 333 | </size> |
312 | </property> | 334 | </property> |
313 | <property stdset="1"> | 335 | <property stdset="1"> |
314 | <name>maximumSize</name> | 336 | <name>maximumSize</name> |
315 | <size> | 337 | <size> |
316 | <width>70</width> | 338 | <width>70</width> |
317 | <height>32767</height> | 339 | <height>32767</height> |
318 | </size> | 340 | </size> |
319 | </property> | 341 | </property> |
320 | <property stdset="1"> | 342 | <property stdset="1"> |
321 | <name>alignment</name> | 343 | <name>alignment</name> |
322 | <set>AlignHCenter</set> | 344 | <set>AlignHCenter</set> |
323 | </property> | 345 | </property> |
324 | <property> | 346 | <property> |
325 | <name>hAlign</name> | 347 | <name>hAlign</name> |
326 | </property> | 348 | </property> |
327 | </widget> | 349 | </widget> |
328 | <widget row="5" column="0" > | 350 | <widget row="5" column="0" > |
329 | <class>QLabel</class> | 351 | <class>QLabel</class> |
330 | <property stdset="1"> | 352 | <property stdset="1"> |
331 | <name>name</name> | 353 | <name>name</name> |
332 | <cstring>TextLabel3_2</cstring> | 354 | <cstring>TimePickerLabel</cstring> |
333 | </property> | 355 | </property> |
334 | <property stdset="1"> | 356 | <property stdset="1"> |
335 | <name>text</name> | 357 | <name>text</name> |
336 | <string>Start time</string> | 358 | <string>Start time</string> |
337 | </property> | 359 | </property> |
338 | </widget> | 360 | </widget> |
339 | <widget row="6" column="0" > | 361 | <widget row="6" column="0" > |
340 | <class>QCheckBox</class> | 362 | <class>QCheckBox</class> |
341 | <property stdset="1"> | 363 | <property stdset="1"> |
342 | <name>name</name> | 364 | <name>name</name> |
343 | <cstring>checkAllDay</cstring> | 365 | <cstring>checkAllDay</cstring> |
344 | </property> | 366 | </property> |
345 | <property stdset="1"> | 367 | <property stdset="1"> |
346 | <name>text</name> | 368 | <name>text</name> |
347 | <string>All day</string> | 369 | <string>All day</string> |
348 | </property> | 370 | </property> |
349 | </widget> | 371 | </widget> |
350 | <widget row="7" column="0" > | 372 | <widget row="7" column="0" > |
351 | <class>QLabel</class> | 373 | <class>QLabel</class> |
352 | <property stdset="1"> | 374 | <property stdset="1"> |
353 | <name>name</name> | 375 | <name>name</name> |
354 | <cstring>TextLabel3_2_2</cstring> | 376 | <cstring>TextLabel3_2_2</cstring> |
355 | </property> | 377 | </property> |
356 | <property stdset="1"> | 378 | <property stdset="1"> |
357 | <name>text</name> | 379 | <name>text</name> |
358 | <string>Time zone</string> | 380 | <string>Time zone</string> |
359 | </property> | 381 | </property> |
360 | </widget> | 382 | </widget> |
361 | <widget row="7" column="1" rowspan="1" colspan="3" > | 383 | <widget row="7" column="1" rowspan="1" colspan="3" > |
362 | <class>TimeZoneSelector</class> | 384 | <class>TimeZoneSelector</class> |
363 | <property stdset="1"> | 385 | <property stdset="1"> |
364 | <name>name</name> | 386 | <name>name</name> |
365 | <cstring>timezone</cstring> | 387 | <cstring>timezone</cstring> |
366 | </property> | 388 | </property> |
367 | </widget> | 389 | </widget> |
368 | <widget row="8" column="0" > | 390 | <widget row="8" column="0" > |
369 | <class>QCheckBox</class> | 391 | <class>QCheckBox</class> |
370 | <property stdset="1"> | 392 | <property stdset="1"> |
371 | <name>name</name> | 393 | <name>name</name> |
372 | <cstring>checkAlarm</cstring> | 394 | <cstring>checkAlarm</cstring> |
373 | </property> | 395 | </property> |
374 | <property stdset="1"> | 396 | <property stdset="1"> |
375 | <name>enabled</name> | 397 | <name>enabled</name> |
376 | <bool>true</bool> | 398 | <bool>true</bool> |
377 | </property> | 399 | </property> |
378 | <property stdset="1"> | 400 | <property stdset="1"> |
379 | <name>autoMask</name> | 401 | <name>autoMask</name> |
380 | <bool>false</bool> | 402 | <bool>false</bool> |
@@ -518,71 +540,77 @@ | |||
518 | <hordata>7</hordata> | 540 | <hordata>7</hordata> |
519 | <verdata>1</verdata> | 541 | <verdata>1</verdata> |
520 | </sizepolicy> | 542 | </sizepolicy> |
521 | <pixmap>image1</pixmap> | 543 | <pixmap>image1</pixmap> |
522 | </customwidget> | 544 | </customwidget> |
523 | </customwidgets> | 545 | </customwidgets> |
524 | <images> | 546 | <images> |
525 | <image> | 547 | <image> |
526 | <name>image0</name> | 548 | <name>image0</name> |
527 | <data format="XPM.GZ" length="45">789cd3d7528808f055d0d2e72a2e492cc94c5648ce482c52d04a29cdcdad8c8eb5ade6523250004143a55a6b2e0026630c4f</data> | 549 | <data format="XPM.GZ" length="45">789cd3d7528808f055d0d2e72a2e492cc94c5648ce482c52d04a29cdcdad8c8eb5ade6523250004143a55a6b2e0026630c4f</data> |
528 | </image> | 550 | </image> |
529 | <image> | 551 | <image> |
530 | <name>image1</name> | 552 | <name>image1</name> |
531 | <data format="XPM.GZ" length="646">789c6dd2c10ac2300c00d07bbf2234b7229d1be245fc04c5a3201e4615f430059d0711ff5ddb2e6bb236ec90eed134cb5a19d8ef36602af5ecdbfeeac05dda0798d3abebde87e3faa374d3807fa0d633a52d38d8de6f679fe33fc776e196f53cd010188256a3600a292882096246517815ca99884606e18044a3a40d91824820924265a7923a2e8bcd05f33db1173e002913175f2a6be6d3294871a2d95fa00e8a94ee017b69d339d90df1e77c57ea072ede6758</data> | 553 | <data format="XPM.GZ" length="646">789c6dd2c10ac2300c00d07bbf2234b7229d1be245fc04c5a3201e4615f430059d0711ff5ddb2e6bb236ec90eed134cb5a19d8ef36602af5ecdbfeeac05dda0798d3abebde87e3faa374d3807fa0d633a52d38d8de6f679fe33fc776e196f53cd010188256a3600a292882096246517815ca99884606e18044a3a40d91824820924265a7923a2e8bcd05f33db1173e002913175f2a6be6d3294871a2d95fa00e8a94ee017b69d339d90df1e77c57ea072ede6758</data> |
532 | </image> | 554 | </image> |
533 | </images> | 555 | </images> |
534 | <connections> | 556 | <connections> |
535 | <connection> | 557 | <connection> |
536 | <sender>checkAlarm</sender> | 558 | <sender>checkAlarm</sender> |
537 | <signal>toggled(bool)</signal> | 559 | <signal>toggled(bool)</signal> |
538 | <receiver>spinAlarm</receiver> | 560 | <receiver>spinAlarm</receiver> |
539 | <slot>setEnabled(bool)</slot> | 561 | <slot>setEnabled(bool)</slot> |
540 | </connection> | 562 | </connection> |
541 | <connection> | 563 | <connection> |
542 | <sender>comboEnd</sender> | 564 | <sender>comboEnd</sender> |
543 | <signal>textChanged(const QString&)</signal> | 565 | <signal>textChanged(const QString&)</signal> |
544 | <receiver>DateEntryBase</receiver> | 566 | <receiver>DateEntryBase</receiver> |
545 | <slot>endTimeChanged( const QString & )</slot> | 567 | <slot>endTimeChanged( const QString & )</slot> |
546 | </connection> | 568 | </connection> |
547 | <connection> | 569 | <connection> |
548 | <sender>cmdRepeat</sender> | 570 | <sender>cmdRepeat</sender> |
549 | <signal>clicked()</signal> | 571 | <signal>clicked()</signal> |
550 | <receiver>DateEntryBase</receiver> | 572 | <receiver>DateEntryBase</receiver> |
551 | <slot>slotRepeat()</slot> | 573 | <slot>slotRepeat()</slot> |
552 | </connection> | 574 | </connection> |
553 | <connection> | 575 | <connection> |
554 | <sender>comboStart</sender> | 576 | <sender>comboStart</sender> |
555 | <signal>textChanged(const QString &)</signal> | 577 | <signal>textChanged(const QString &)</signal> |
556 | <receiver>DateEntryBase</receiver> | 578 | <receiver>DateEntryBase</receiver> |
557 | <slot>startTimeEdited( const QString & )</slot> | 579 | <slot>startTimeEdited( const QString & )</slot> |
558 | </connection> | 580 | </connection> |
559 | <connection> | 581 | <connection> |
560 | <sender>checkAllDay</sender> | 582 | <sender>checkAllDay</sender> |
561 | <signal>toggled(bool)</signal> | 583 | <signal>toggled(bool)</signal> |
562 | <receiver>comboEnd</receiver> | 584 | <receiver>comboEnd</receiver> |
563 | <slot>setDisabled(bool)</slot> | 585 | <slot>setDisabled(bool)</slot> |
564 | </connection> | 586 | </connection> |
565 | <connection> | 587 | <connection> |
588 | <sender>checkAllDay</sender> | ||
589 | <signal>toggled(bool)</signal> | ||
590 | <receiver>timePickerStart</receiver> | ||
591 | <slot>setDisabled(bool)</slot> | ||
592 | </connection> | ||
593 | <connection> | ||
566 | <sender>checkAlarm</sender> | 594 | <sender>checkAlarm</sender> |
567 | <signal>toggled(bool)</signal> | 595 | <signal>toggled(bool)</signal> |
568 | <receiver>comboSound</receiver> | 596 | <receiver>comboSound</receiver> |
569 | <slot>setEnabled(bool)</slot> | 597 | <slot>setEnabled(bool)</slot> |
570 | </connection> | 598 | </connection> |
571 | <connection> | 599 | <connection> |
572 | <sender>checkAllDay</sender> | 600 | <sender>checkAllDay</sender> |
573 | <signal>toggled(bool)</signal> | 601 | <signal>toggled(bool)</signal> |
574 | <receiver>comboStart</receiver> | 602 | <receiver>comboStart</receiver> |
575 | <slot>setDisabled(bool)</slot> | 603 | <slot>setDisabled(bool)</slot> |
576 | </connection> | 604 | </connection> |
577 | <slot access="public">endDateChanged( const QString & )</slot> | 605 | <slot access="public">endDateChanged( const QString & )</slot> |
578 | <slot access="public">endDateChanged( int, int, int )</slot> | 606 | <slot access="public">endDateChanged( int, int, int )</slot> |
579 | <slot access="public">endTimeChanged( const QString & )</slot> | 607 | <slot access="public">endTimeChanged( const QString & )</slot> |
580 | <slot access="public">slotRepeat()</slot> | 608 | <slot access="public">slotRepeat()</slot> |
581 | <slot access="public">slotWait( int )</slot> | 609 | <slot access="public">slotWait( int )</slot> |
582 | <slot access="public">startDateChanged( const QString & )</slot> | 610 | <slot access="public">startDateChanged( const QString & )</slot> |
583 | <slot access="public">startDateChanged(int, int, int)</slot> | 611 | <slot access="public">startDateChanged(int, int, int)</slot> |
584 | <slot access="public">startTimeEdited( const QString & )</slot> | 612 | <slot access="public">startTimeEdited( const QString & )</slot> |
585 | <slot access="public">typeChanged( const QString & )</slot> | 613 | <slot access="public">typeChanged( const QString & )</slot> |
586 | <slot access="public">tzexecute(void)</slot> | 614 | <slot access="public">tzexecute(void)</slot> |
587 | </connections> | 615 | </connections> |
588 | </UI> | 616 | </UI> |
diff --git a/core/pim/datebook/dateentryimpl.cpp b/core/pim/datebook/dateentryimpl.cpp index f2f17c6..e14e2f5 100644 --- a/core/pim/datebook/dateentryimpl.cpp +++ b/core/pim/datebook/dateentryimpl.cpp | |||
@@ -23,103 +23,119 @@ | |||
23 | 23 | ||
24 | #include <qpe/qpeapplication.h> | 24 | #include <qpe/qpeapplication.h> |
25 | #include <qpe/categoryselect.h> | 25 | #include <qpe/categoryselect.h> |
26 | #include <qpe/datebookmonth.h> | 26 | #include <qpe/datebookmonth.h> |
27 | #include <qpe/global.h> | 27 | #include <qpe/global.h> |
28 | #include <qpe/timeconversion.h> | 28 | #include <qpe/timeconversion.h> |
29 | #include <qpe/timestring.h> | 29 | #include <qpe/timestring.h> |
30 | #include <qpe/tzselect.h> | 30 | #include <qpe/tzselect.h> |
31 | 31 | ||
32 | #include <qevent.h> | 32 | #include <qevent.h> |
33 | #include <qcheckbox.h> | 33 | #include <qcheckbox.h> |
34 | #include <qcombobox.h> | 34 | #include <qcombobox.h> |
35 | #include <qlayout.h> | 35 | #include <qlayout.h> |
36 | #include <qlineedit.h> | 36 | #include <qlineedit.h> |
37 | #include <qmultilineedit.h> | 37 | #include <qmultilineedit.h> |
38 | #include <qpopupmenu.h> | 38 | #include <qpopupmenu.h> |
39 | #include <qscrollview.h> | 39 | #include <qscrollview.h> |
40 | #include <qspinbox.h> | 40 | #include <qspinbox.h> |
41 | #include <qtoolbutton.h> | 41 | #include <qtoolbutton.h> |
42 | 42 | ||
43 | #include "timepicker.h" | 43 | #include "timepicker.h" |
44 | 44 | ||
45 | #include <stdlib.h> | 45 | #include <stdlib.h> |
46 | 46 | ||
47 | /* | 47 | /* |
48 | * Constructs a DateEntry which is a child of 'parent', with the | 48 | * Constructs a DateEntry which is a child of 'parent', with the |
49 | * name 'name' and widget flags set to 'f' | 49 | * name 'name' and widget flags set to 'f' |
50 | * | 50 | * |
51 | * The dialog will by default be modeless, unless you set 'modal' to | 51 | * The dialog will by default be modeless, unless you set 'modal' to |
52 | * TRUE to construct a modal dialog. | 52 | * TRUE to construct a modal dialog. |
53 | */ | 53 | */ |
54 | 54 | ||
55 | DateEntry::DateEntry( bool startOnMonday, const QDateTime &start, | 55 | DateEntry::DateEntry( bool startOnMonday, const QDateTime &start, |
56 | const QDateTime &end, bool whichClock, QWidget* parent, | 56 | const QDateTime &end, bool whichClock, QWidget* parent, |
57 | const char* name ) | 57 | const char* name ) |
58 | : DateEntryBase( parent, name ), | 58 | : DateEntryBase( parent, name ), |
59 | ampm( whichClock ), | 59 | ampm( whichClock ), |
60 | startWeekOnMonday( startOnMonday ) | 60 | startWeekOnMonday( startOnMonday ) |
61 | { | 61 | { |
62 | init(); | 62 | init(); |
63 | setDates(start,end); | 63 | setDates(start,end); |
64 | setFocusProxy(comboDescription); | 64 | setFocusProxy(comboDescription); |
65 | } | 65 | } |
66 | 66 | ||
67 | bool DateEntry::eventFilter(QObject *obj, QEvent *ev ) | 67 | bool DateEntry::eventFilter(QObject *obj, QEvent *ev ) |
68 | { | 68 | { |
69 | if( ev->type() == QEvent::FocusIn ){ | 69 | if( ev->type() == QEvent::FocusIn ){ |
70 | if( obj == comboStart ){ | 70 | if( obj == comboStart ){ |
71 | TextLabel3_2->setText( tr("Start Time" ) ); | 71 | timePickerStart->setHour(startTime.hour()); |
72 | timePickerStart->setMinute(startTime.minute()); | ||
73 | TimePickerLabel->setText( tr("Start Time" ) ); | ||
72 | m_showStart= true; | 74 | m_showStart= true; |
73 | }else if( obj == comboEnd ){ | 75 | }else if( obj == comboEnd ){ |
74 | TextLabel3_2->setText( tr("End Time") ); | 76 | timePickerStart->setHour(endTime.hour()); |
77 | timePickerStart->setMinute(endTime.minute()); | ||
78 | TimePickerLabel->setText( tr("End Time") ); | ||
75 | m_showStart = false; | 79 | m_showStart = false; |
76 | } | 80 | } |
81 | } else if( ev->type() == QEvent::FocusOut ){ | ||
82 | if( obj == comboEnd ){ | ||
83 | QString s; | ||
84 | s.sprintf("%.2d:%.2d",endTime.hour(), endTime.minute()); | ||
85 | comboEnd->setText(s); | ||
86 | } | ||
87 | else if( obj == comboStart ){ | ||
88 | QString s; | ||
89 | s.sprintf("%.2d:%.2d",startTime.hour(), startTime.minute()); | ||
90 | comboStart->setText(s); | ||
91 | } | ||
77 | } | 92 | } |
93 | |||
78 | return false; | 94 | return false; |
79 | } | 95 | } |
80 | 96 | ||
81 | static void addOrPick( QComboBox* combo, const QString& t ) | 97 | static void addOrPick( QComboBox* combo, const QString& t ) |
82 | { | 98 | { |
83 | // Pick an item if one excists | 99 | // Pick an item if one excists |
84 | for (int i=0; i<combo->count(); i++) { | 100 | for (int i=0; i<combo->count(); i++) { |
85 | if ( combo->text(i) == t ) { | 101 | if ( combo->text(i) == t ) { |
86 | combo->setCurrentItem(i); | 102 | combo->setCurrentItem(i); |
87 | return; | 103 | return; |
88 | } | 104 | } |
89 | } | 105 | } |
90 | 106 | ||
91 | // Else add one | 107 | // Else add one |
92 | combo->insertItem(t); | 108 | combo->insertItem(t); |
93 | combo->setCurrentItem(combo->count()-1); | 109 | combo->setCurrentItem(combo->count()-1); |
94 | } | 110 | } |
95 | 111 | ||
96 | DateEntry::DateEntry( bool startOnMonday, const Event &event, bool whichClock, | 112 | DateEntry::DateEntry( bool startOnMonday, const Event &event, bool whichClock, |
97 | QWidget* parent, const char* name ) | 113 | QWidget* parent, const char* name ) |
98 | : DateEntryBase( parent, name ), | 114 | : DateEntryBase( parent, name ), |
99 | ampm( whichClock ), | 115 | ampm( whichClock ), |
100 | startWeekOnMonday( startOnMonday ) | 116 | startWeekOnMonday( startOnMonday ) |
101 | { | 117 | { |
102 | init(); | 118 | init(); |
103 | setDates(event.start(),event.end()); | 119 | setDates(event.start(),event.end()); |
104 | comboCategory->setCategories( event.categories(), "Calendar", tr("Calendar") ); | 120 | comboCategory->setCategories( event.categories(), "Calendar", tr("Calendar") ); |
105 | if(!event.description().isEmpty()) | 121 | if(!event.description().isEmpty()) |
106 | addOrPick( comboDescription, event.description() ); | 122 | addOrPick( comboDescription, event.description() ); |
107 | if(!event.location().isEmpty()) | 123 | if(!event.location().isEmpty()) |
108 | addOrPick( comboLocation, event.location() ); | 124 | addOrPick( comboLocation, event.location() ); |
109 | checkAlarm->setChecked( event.hasAlarm() ); | 125 | checkAlarm->setChecked( event.hasAlarm() ); |
110 | checkAllDay->setChecked( event.type() == Event::AllDay ); | 126 | checkAllDay->setChecked( event.type() == Event::AllDay ); |
111 | if(!event.notes().isEmpty()) | 127 | if(!event.notes().isEmpty()) |
112 | editNote->setText(event.notes()); | 128 | editNote->setText(event.notes()); |
113 | spinAlarm->setValue(event.alarmTime()); | 129 | spinAlarm->setValue(event.alarmTime()); |
114 | if ( event.alarmSound() != Event::Silent ) | 130 | if ( event.alarmSound() != Event::Silent ) |
115 | comboSound->setCurrentItem( 1 ); | 131 | comboSound->setCurrentItem( 1 ); |
116 | if ( event.hasRepeat() ) { | 132 | if ( event.hasRepeat() ) { |
117 | rp = event.repeatPattern(); | 133 | rp = event.repeatPattern(); |
118 | cmdRepeat->setText( tr("Repeat...") ); | 134 | cmdRepeat->setText( tr("Repeat...") ); |
119 | } | 135 | } |
120 | setRepeatLabel(); | 136 | setRepeatLabel(); |
121 | } | 137 | } |
122 | 138 | ||
123 | void DateEntry::setDates( const QDateTime& s, const QDateTime& e ) | 139 | void DateEntry::setDates( const QDateTime& s, const QDateTime& e ) |
124 | { | 140 | { |
125 | startDate = s.date(); | 141 | startDate = s.date(); |
@@ -223,157 +239,157 @@ void DateEntry::endDateChanged( int y, int m, int d ) | |||
223 | endDate.setYMD( y, m, d ); | 239 | endDate.setYMD( y, m, d ); |
224 | if ( endDate < startDate ) { | 240 | if ( endDate < startDate ) { |
225 | endDate = startDate; | 241 | endDate = startDate; |
226 | } | 242 | } |
227 | 243 | ||
228 | buttonEnd->setText( TimeString::shortDate( endDate ) ); | 244 | buttonEnd->setText( TimeString::shortDate( endDate ) ); |
229 | 245 | ||
230 | endPicker->setDate( endDate.year(), endDate.month(), endDate.day() ); | 246 | endPicker->setDate( endDate.year(), endDate.month(), endDate.day() ); |
231 | } | 247 | } |
232 | 248 | ||
233 | static QTime parseTime( const QString& s, bool ampm ) | 249 | static QTime parseTime( const QString& s, bool ampm ) |
234 | { | 250 | { |
235 | QTime tmpTime; | 251 | QTime tmpTime; |
236 | QStringList l = QStringList::split( ':', s ); | 252 | QStringList l = QStringList::split( ':', s ); |
237 | int hour = l[0].toInt(); | 253 | int hour = l[0].toInt(); |
238 | if ( ampm ) { | 254 | if ( ampm ) { |
239 | int i=0; | 255 | int i=0; |
240 | while (i<int(l[1].length()) && l[1][i]>='0' && l[1][i]<='9') | 256 | while (i<int(l[1].length()) && l[1][i]>='0' && l[1][i]<='9') |
241 | i++; | 257 | i++; |
242 | QString digits = l[1].left(i); | 258 | QString digits = l[1].left(i); |
243 | if ( l[1].contains( "PM", FALSE ) ) { | 259 | if ( l[1].contains( "PM", FALSE ) ) { |
244 | if ( hour != 12 ) | 260 | if ( hour != 12 ) |
245 | hour += 12; | 261 | hour += 12; |
246 | } else { | 262 | } else { |
247 | if ( hour == 12 ) | 263 | if ( hour == 12 ) |
248 | hour = 0; | 264 | hour = 0; |
249 | } | 265 | } |
250 | l[1] = digits; | 266 | l[1] = digits; |
251 | } | 267 | } |
252 | int minute = l[1].toInt(); | 268 | int minute = l[1].toInt(); |
253 | if ( minute > 59 ) | 269 | if ( minute > 59 ) |
254 | minute = 59; | 270 | minute = 59; |
255 | else if ( minute < 0 ) | 271 | else if ( minute < 0 ) |
256 | minute = 0; | 272 | minute = 0; |
257 | if ( hour > 23 ) { | 273 | if ( hour > 23 ) { |
258 | hour = 23; | 274 | hour = 23; |
259 | minute = 59; | 275 | minute = 59; |
260 | } else if ( hour < 0 ) | 276 | } else if ( hour < 0 ) |
261 | hour = 0; | 277 | hour = 0; |
262 | tmpTime.setHMS( hour, minute, 0 ); | 278 | tmpTime.setHMS( hour, minute, 0 ); |
263 | return tmpTime; | 279 | return tmpTime; |
264 | } | 280 | } |
265 | 281 | ||
266 | /* | 282 | /* |
267 | * public slot | 283 | * public slot |
268 | */ | 284 | */ |
269 | void DateEntry::endTimeChanged( const QString &s ) | 285 | void DateEntry::endTimeChanged( const QString &s ) |
270 | { | 286 | { |
271 | QTime tmpTime = parseTime(s,ampm); | 287 | endTimeChanged( parseTime(s,ampm) ); |
272 | if ( endDate > startDate || tmpTime >= startTime ) { | 288 | } |
273 | endTime = tmpTime; | 289 | |
290 | void DateEntry::endTimeChanged( const QTime &t ) { | ||
291 | if ( endDate > startDate || t >= startTime ) { | ||
292 | endTime = t; | ||
274 | } else { | 293 | } else { |
275 | endTime = startTime; | 294 | endTime = startTime; |
276 | //comboEnd->setCurrentItem( comboStart->currentItem() ); | 295 | //comboEnd->setCurrentItem( comboStart->currentItem() ); |
277 | } | 296 | } |
278 | 297 | timePickerStart->setHour(endTime.hour()); | |
279 | } | 298 | timePickerStart->setMinute(endTime.minute()); |
280 | |||
281 | void DateEntry::endTimeChanged( const QTime &t ) { | ||
282 | } | 299 | } |
283 | 300 | ||
284 | /* | 301 | /* |
285 | * public slot | 302 | * public slot |
286 | */ | 303 | */ |
287 | void DateEntry::startDateChanged( int y, int m, int d ) | 304 | void DateEntry::startDateChanged( int y, int m, int d ) |
288 | { | 305 | { |
289 | QDate prev = startDate; | 306 | QDate prev = startDate; |
290 | startDate.setYMD( y, m, d ); | 307 | startDate.setYMD( y, m, d ); |
291 | if ( rp.type == Event::Weekly && | 308 | if ( rp.type == Event::Weekly && |
292 | startDate.dayOfWeek() != prev.dayOfWeek() ) { | 309 | startDate.dayOfWeek() != prev.dayOfWeek() ) { |
293 | // if we change the start of a weekly repeating event | 310 | // if we change the start of a weekly repeating event |
294 | // set the repeating day appropriately | 311 | // set the repeating day appropriately |
295 | char mask = 1 << (prev.dayOfWeek()-1); | 312 | char mask = 1 << (prev.dayOfWeek()-1); |
296 | rp.days &= (~mask); | 313 | rp.days &= (~mask); |
297 | rp.days |= 1 << (startDate.dayOfWeek()-1); | 314 | rp.days |= 1 << (startDate.dayOfWeek()-1); |
298 | } | 315 | } |
299 | 316 | ||
300 | buttonStart->setText( TimeString::shortDate( startDate ) ); | 317 | buttonStart->setText( TimeString::shortDate( startDate ) ); |
301 | 318 | ||
302 | // our pickers must be reset... | 319 | // our pickers must be reset... |
303 | startPicker->setDate( y, m, d ); | 320 | startPicker->setDate( y, m, d ); |
304 | endPicker->setDate( y, m, d ); | 321 | endPicker->setDate( y, m, d ); |
305 | } | 322 | } |
306 | 323 | ||
307 | /* | 324 | /* |
308 | * public slot | 325 | * public slot |
309 | */ | 326 | */ |
310 | void DateEntry::startTimeEdited( const QString &s ) | 327 | void DateEntry::startTimeEdited( const QString &s ) |
311 | { | 328 | { |
312 | startTimeChanged(parseTime(s,ampm)); | 329 | startTimeChanged(parseTime(s,ampm)); |
313 | updateTimeEdit(false,true); | 330 | updateTimeEdit(false,true); |
314 | timePickerStart->setHour(startTime.hour()); | 331 | timePickerStart->setHour(startTime.hour()); |
315 | timePickerStart->setMinute(startTime.minute()); | 332 | timePickerStart->setMinute(startTime.minute()); |
316 | } | 333 | } |
317 | 334 | ||
318 | void DateEntry::startTimeChanged( const QTime &t ) | 335 | void DateEntry::startTimeChanged( const QTime &t ) |
319 | { | 336 | { |
320 | int duration=startTime.secsTo(endTime); | 337 | int duration=startTime.secsTo(endTime); |
321 | startTime = t; | 338 | startTime = t; |
322 | endTime=t.addSecs(duration); | 339 | endTime=t.addSecs(duration); |
323 | } | 340 | } |
324 | void DateEntry::startTimePicked( const QTime &t ) { | 341 | void DateEntry::startTimePicked( const QTime &t ) { |
325 | if(m_showStart ){ | 342 | if(m_showStart ){ |
326 | startTimeChanged(t); | 343 | startTimeChanged(t); |
327 | updateTimeEdit(true,true); | 344 | updateTimeEdit(true,true); |
328 | }else{ | 345 | }else{ |
329 | endTime = t; | 346 | endTimeChanged(t); |
330 | updateTimeEdit(false, true ); | 347 | updateTimeEdit(false, true ); |
331 | |||
332 | } | 348 | } |
333 | } | 349 | } |
334 | 350 | ||
335 | /* | 351 | /* |
336 | * public slot | 352 | * public slot |
337 | */ | 353 | */ |
338 | void DateEntry::typeChanged( const QString &s ) | 354 | void DateEntry::typeChanged( const QString &s ) |
339 | { | 355 | { |
340 | bool b = s != "All Day"; | 356 | bool b = s != "All Day"; |
341 | buttonStart->setEnabled( b ); | 357 | buttonStart->setEnabled( b ); |
342 | comboStart->setEnabled( b ); | 358 | comboStart->setEnabled( b ); |
343 | comboEnd->setEnabled( b ); | 359 | comboEnd->setEnabled( b ); |
344 | } | 360 | } |
345 | 361 | ||
346 | void DateEntry::slotRepeat() | 362 | void DateEntry::slotRepeat() |
347 | { | 363 | { |
348 | // Work around for compiler Bug.. | 364 | // Work around for compiler Bug.. |
349 | RepeatEntry *e; | 365 | RepeatEntry *e; |
350 | 366 | ||
351 | // it is better in my opinion to just grab this from the mother, | 367 | // it is better in my opinion to just grab this from the mother, |
352 | // since, this dialog doesn't need to keep track of it... | 368 | // since, this dialog doesn't need to keep track of it... |
353 | if ( rp.type != Event::NoRepeat ) | 369 | if ( rp.type != Event::NoRepeat ) |
354 | e = new RepeatEntry( startWeekOnMonday, rp, startDate, this); | 370 | e = new RepeatEntry( startWeekOnMonday, rp, startDate, this); |
355 | else | 371 | else |
356 | e = new RepeatEntry( startWeekOnMonday, startDate, this ); | 372 | e = new RepeatEntry( startWeekOnMonday, startDate, this ); |
357 | 373 | ||
358 | #if defined(Q_WS_QWS) || defined(_WS_QWS_) | 374 | #if defined(Q_WS_QWS) || defined(_WS_QWS_) |
359 | e->showMaximized(); | 375 | e->showMaximized(); |
360 | #endif | 376 | #endif |
361 | if ( e->exec() ) { | 377 | if ( e->exec() ) { |
362 | rp = e->repeatPattern(); | 378 | rp = e->repeatPattern(); |
363 | setRepeatLabel(); | 379 | setRepeatLabel(); |
364 | } | 380 | } |
365 | } | 381 | } |
366 | 382 | ||
367 | void DateEntry::slotChangeStartOfWeek( bool onMonday ) | 383 | void DateEntry::slotChangeStartOfWeek( bool onMonday ) |
368 | { | 384 | { |
369 | startWeekOnMonday = onMonday; | 385 | startWeekOnMonday = onMonday; |
370 | } | 386 | } |
371 | 387 | ||
372 | Event DateEntry::event() | 388 | Event DateEntry::event() |
373 | { | 389 | { |
374 | Event ev; | 390 | Event ev; |
375 | Event::SoundTypeChoice st; | 391 | Event::SoundTypeChoice st; |
376 | ev.setDescription( comboDescription->currentText() ); | 392 | ev.setDescription( comboDescription->currentText() ); |
377 | ev.setLocation( comboLocation->currentText() ); | 393 | ev.setLocation( comboLocation->currentText() ); |
378 | ev.setCategories( comboCategory->currentCategories() ); | 394 | ev.setCategories( comboCategory->currentCategories() ); |
379 | ev.setType( checkAllDay->isChecked() ? Event::AllDay : Event::Normal ); | 395 | ev.setType( checkAllDay->isChecked() ? Event::AllDay : Event::Normal ); |