summaryrefslogtreecommitdiffabout
path: root/korganizer/koeditorrecurrence.h
Unidiff
Diffstat (limited to 'korganizer/koeditorrecurrence.h') (more/less context) (ignore whitespace changes)
-rw-r--r--korganizer/koeditorrecurrence.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/korganizer/koeditorrecurrence.h b/korganizer/koeditorrecurrence.h
index a15afcb..f398f62 100644
--- a/korganizer/koeditorrecurrence.h
+++ b/korganizer/koeditorrecurrence.h
@@ -178,147 +178,147 @@ class ExceptionsWidget : public QWidget, public ExceptionsBase
178 void deleteException(); 178 void deleteException();
179 179
180 private: 180 private:
181 KDateEdit *mExceptionDateEdit; 181 KDateEdit *mExceptionDateEdit;
182 QListBox *mExceptionList; 182 QListBox *mExceptionList;
183 DateList mExceptionDates; 183 DateList mExceptionDates;
184}; 184};
185 185
186class ExceptionsDialog : public KDialogBase, public ExceptionsBase 186class ExceptionsDialog : public KDialogBase, public ExceptionsBase
187{ 187{
188 public: 188 public:
189 ExceptionsDialog( QWidget *parent, const char *name = 0 ); 189 ExceptionsDialog( QWidget *parent, const char *name = 0 );
190 190
191 void setDefaults( const QDateTime &from ); 191 void setDefaults( const QDateTime &from );
192 192
193 void setDates( const DateList & ); 193 void setDates( const DateList & );
194 DateList dates(); 194 DateList dates();
195 195
196 private: 196 private:
197 ExceptionsWidget *mExceptions; 197 ExceptionsWidget *mExceptions;
198}; 198};
199 199
200class RecurrenceRangeBase 200class RecurrenceRangeBase
201{ 201{
202 public: 202 public:
203 virtual void setDefaults( const QDateTime &from ) = 0; 203 virtual void setDefaults( const QDateTime &from ) = 0;
204 204
205 virtual void setDuration( int ) = 0; 205 virtual void setDuration( int ) = 0;
206 virtual int duration() = 0; 206 virtual int duration() = 0;
207 207
208 virtual void setEndDate( const QDate & ) = 0; 208 virtual void setEndDate( const QDate & ) = 0;
209 virtual QDate endDate() = 0; 209 virtual QDate endDate() = 0;
210 210
211 virtual void setDateTimes( const QDateTime &start, 211 virtual void setDateTimes( const QDateTime &start,
212 const QDateTime &end = QDateTime() ) = 0; 212 const QDateTime &end = QDateTime() ) = 0;
213}; 213};
214 214
215class RecurrenceRangeWidget : public QWidget, public RecurrenceRangeBase 215class RecurrenceRangeWidget : public QWidget, public RecurrenceRangeBase
216{ 216{
217 Q_OBJECT 217 Q_OBJECT
218 public: 218 public:
219 RecurrenceRangeWidget( QWidget *parent = 0, const char *name = 0 ); 219 RecurrenceRangeWidget( QWidget *parent = 0, const char *name = 0 );
220 220
221 void setDefaults( const QDateTime &from ); 221 void setDefaults( const QDateTime &from );
222 222
223 void setDuration( int ); 223 void setDuration( int );
224 int duration(); 224 int duration();
225 225
226 void setEndDate( const QDate & ); 226 void setEndDate( const QDate & );
227 QDate endDate(); 227 QDate endDate();
228 228
229 void setDateTimes( const QDateTime &start, 229 void setDateTimes( const QDateTime &start,
230 const QDateTime &end = QDateTime() ); 230 const QDateTime &end = QDateTime() );
231 231
232 protected slots: 232 protected slots:
233 void showCurrentRange(); 233 void showCurrentRange();
234 234
235 private: 235 private:
236 QGroupBox *mRangeGroupBox; 236 QGroupBox *mRangeGroupBox;
237 QLabel *mStartDateLabel; 237 QLabel *mStartDateLabel;
238 QRadioButton *mNoEndDateButton; 238 QRadioButton *mNoEndDateButton;
239 QRadioButton *mEndDurationButton; 239 QRadioButton *mEndDurationButton;
240 QSpinBox *mEndDurationEdit; 240 QSpinBox *mEndDurationEdit;
241 QRadioButton *mEndDateButton; 241 QRadioButton *mEndDateButton;
242 KDateEdit *mEndDateEdit; 242 KDateEdit *mEndDateEdit;
243}; 243};
244 244
245class RecurrenceRangeDialog : public KDialogBase, public RecurrenceRangeBase 245class RecurrenceRangeDialog : public KDialogBase, public RecurrenceRangeBase
246{ 246{
247 public: 247 public:
248 RecurrenceRangeDialog( QWidget *parent = 0, const char *name = 0 ); 248 RecurrenceRangeDialog( QWidget *parent = 0, const char *name = 0 );
249 249
250 void setDefaults( const QDateTime &from ); 250 void setDefaults( const QDateTime &from );
251 251
252 void setDuration( int ); 252 void setDuration( int );
253 int duration(); 253 int duration();
254 254
255 void setEndDate( const QDate & ); 255 void setEndDate( const QDate & );
256 QDate endDate(); 256 QDate endDate();
257 257
258 void setDateTimes( const QDateTime &start, 258 void setDateTimes( const QDateTime &start,
259 const QDateTime &end = QDateTime() ); 259 const QDateTime &end = QDateTime() );
260 260
261 private: 261 private:
262 RecurrenceRangeWidget *mRecurrenceRangeWidget; 262 RecurrenceRangeWidget *mRecurrenceRangeWidget;
263}; 263};
264 264
265class KOEditorRecurrence : public QWidget 265class KOEditorRecurrence : public QWidget
266{ 266{
267 Q_OBJECT 267 Q_OBJECT
268 public: 268 public:
269 KOEditorRecurrence ( QWidget *parent = 0, const char *name = 0 ); 269 KOEditorRecurrence ( QWidget *parent = 0, const char *name = 0 );
270 virtual ~KOEditorRecurrence(); 270 virtual ~KOEditorRecurrence();
271 271
272 enum { Daily, Weekly, Monthly, Yearly }; 272 enum { Daily, Weekly, Monthly, Yearly };
273 273
274 /** Set widgets to default values */
275 void setDefaults( QDateTime from, QDateTime to, bool allday );
276 /** Read event object and setup widgets accordingly */ 274 /** Read event object and setup widgets accordingly */
277 void readEvent( Incidence * ); 275 void readEvent( Incidence * );
278 /** Write event settings to event object */ 276 /** Write event settings to event object */
279 void writeEvent( Incidence * ); 277 void writeEvent( Incidence * );
280 278
281 /** Check if the input is valid. */ 279 /** Check if the input is valid. */
282 bool validateInput(); 280 bool validateInput();
283 281
284 public slots: 282 public slots:
283 void setDefaultsDates( QDateTime from, QDateTime to );
284 void setDefaults( QDateTime from, QDateTime to );
285 void setEnabled( bool ); 285 void setEnabled( bool );
286 void setDateTimes( QDateTime start, QDateTime end ); 286 void setDateTimes( QDateTime start, QDateTime end );
287 void setDateTimeStr( const QString & ); 287 void setDateTimeStr( const QString & );
288 288
289 signals: 289 signals:
290 void dateTimesChanged( QDateTime start, QDateTime end ); 290 void dateTimesChanged( QDateTime start, QDateTime end );
291 291
292 protected slots: 292 protected slots:
293 void showCurrentRule( int ); 293 void showCurrentRule( int );
294 void showExceptionsDialog(); 294 void showExceptionsDialog();
295 void showRecurrenceRangeDialog(); 295 void showRecurrenceRangeDialog();
296 296
297 private: 297 private:
298 QCheckBox *mEnabledCheck; 298 QCheckBox *mEnabledCheck;
299 299
300 QGroupBox *mTimeGroupBox; 300 QGroupBox *mTimeGroupBox;
301 QLabel *mDateTimeLabel; 301 QLabel *mDateTimeLabel;
302 302
303 QGroupBox *mRuleBox; 303 QGroupBox *mRuleBox;
304 QWidgetStack *mRuleStack; 304 QWidgetStack *mRuleStack;
305 RecurrenceChooser *mRecurrenceChooser; 305 RecurrenceChooser *mRecurrenceChooser;
306 306
307 RecurDaily *mDaily; 307 RecurDaily *mDaily;
308 RecurWeekly *mWeekly; 308 RecurWeekly *mWeekly;
309 RecurMonthly *mMonthly; 309 RecurMonthly *mMonthly;
310 RecurYearly *mYearly; 310 RecurYearly *mYearly;
311 311
312 RecurrenceRangeBase *mRecurrenceRange; 312 RecurrenceRangeBase *mRecurrenceRange;
313 RecurrenceRangeWidget *mRecurrenceRangeWidget; 313 RecurrenceRangeWidget *mRecurrenceRangeWidget;
314 RecurrenceRangeDialog *mRecurrenceRangeDialog; 314 RecurrenceRangeDialog *mRecurrenceRangeDialog;
315 QPushButton *mRecurrenceRangeButton; 315 QPushButton *mRecurrenceRangeButton;
316 316
317 ExceptionsBase *mExceptions; 317 ExceptionsBase *mExceptions;
318 ExceptionsDialog *mExceptionsDialog; 318 ExceptionsDialog *mExceptionsDialog;
319 ExceptionsWidget *mExceptionsWidget; 319 ExceptionsWidget *mExceptionsWidget;
320 QPushButton *mExceptionsButton; 320 QPushButton *mExceptionsButton;
321 321
322}; 322};
323 323
324#endif 324#endif