author | Michael Krelin <hacker@klever.net> | 2007-07-04 11:23:42 (UTC) |
---|---|---|
committer | Michael Krelin <hacker@klever.net> | 2007-07-04 11:23:42 (UTC) |
commit | a08aff328d4393031d5ba7d622c2b05705a89d73 (patch) (unidiff) | |
tree | 8ee90d686081c52e7c69b5ce946e9b1a7d690001 /korganizer/koeditorrecurrence.cpp | |
parent | 11edc920afe4f274c0964436633aa632c8288a40 (diff) | |
download | kdepimpi-a08aff328d4393031d5ba7d622c2b05705a89d73.zip kdepimpi-a08aff328d4393031d5ba7d622c2b05705a89d73.tar.gz kdepimpi-a08aff328d4393031d5ba7d622c2b05705a89d73.tar.bz2 |
initial public commit of qt4 portp1
Diffstat (limited to 'korganizer/koeditorrecurrence.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | korganizer/koeditorrecurrence.cpp | 94 |
1 files changed, 51 insertions, 43 deletions
diff --git a/korganizer/koeditorrecurrence.cpp b/korganizer/koeditorrecurrence.cpp index e0380c4..e0ae3a0 100644 --- a/korganizer/koeditorrecurrence.cpp +++ b/korganizer/koeditorrecurrence.cpp | |||
@@ -21,19 +21,27 @@ | |||
21 | without including the source code for Qt in the source distribution. | 21 | without including the source code for Qt in the source distribution. |
22 | */ | 22 | */ |
23 | 23 | ||
24 | #include <qtooltip.h> | 24 | #include <qtooltip.h> |
25 | #include <qfiledialog.h> | 25 | #include <q3filedialog.h> |
26 | #include <qlayout.h> | 26 | #include <qlayout.h> |
27 | #include <qvbox.h> | 27 | #include <q3vbox.h> |
28 | #include <qbuttongroup.h> | 28 | #include <q3buttongroup.h> |
29 | #include <qvgroupbox.h> | 29 | #include <q3vgroupbox.h> |
30 | #include <qwidgetstack.h> | 30 | #include <q3widgetstack.h> |
31 | #include <qdatetime.h> | 31 | #include <qdatetime.h> |
32 | #include <qlistbox.h> | 32 | #include <q3listbox.h> |
33 | #include <qspinbox.h> | 33 | #include <qspinbox.h> |
34 | #include <qcheckbox.h> | 34 | #include <qcheckbox.h> |
35 | #include <qapplication.h> | 35 | #include <qapplication.h> |
36 | #include <QDesktopWidget> | ||
37 | //Added by qt3to4: | ||
38 | #include <Q3HBoxLayout> | ||
39 | #include <QLabel> | ||
40 | #include <Q3GridLayout> | ||
41 | #include <Q3PtrList> | ||
42 | #include <Q3Frame> | ||
43 | #include <Q3VBoxLayout> | ||
36 | 44 | ||
37 | #include <kdialog.h> | 45 | #include <kdialog.h> |
38 | #include <kglobal.h> | 46 | #include <kglobal.h> |
39 | #include <klocale.h> | 47 | #include <klocale.h> |
@@ -80,9 +88,9 @@ int RecurBase::frequency() | |||
80 | 88 | ||
81 | RecurDaily::RecurDaily( QWidget *parent, const char *name ) : | 89 | RecurDaily::RecurDaily( QWidget *parent, const char *name ) : |
82 | RecurBase( parent, name ) | 90 | RecurBase( parent, name ) |
83 | { | 91 | { |
84 | QBoxLayout *topLayout = new QHBoxLayout( this ); | 92 | Q3BoxLayout *topLayout = new Q3HBoxLayout( this ); |
85 | topLayout->setSpacing( KDialog::spacingHint() ); | 93 | topLayout->setSpacing( KDialog::spacingHint() ); |
86 | topLayout->setMargin( KDialog::marginHintSmall() ); | 94 | topLayout->setMargin( KDialog::marginHintSmall() ); |
87 | 95 | ||
88 | QLabel *preLabel = new QLabel( i18n("Recur every"), this ); | 96 | QLabel *preLabel = new QLabel( i18n("Recur every"), this ); |
@@ -99,15 +107,15 @@ RecurDaily::RecurDaily( QWidget *parent, const char *name ) : | |||
99 | 107 | ||
100 | RecurWeekly::RecurWeekly( QWidget *parent, const char *name ) : | 108 | RecurWeekly::RecurWeekly( QWidget *parent, const char *name ) : |
101 | RecurBase( parent, name ) | 109 | RecurBase( parent, name ) |
102 | { | 110 | { |
103 | QBoxLayout *topLayout = new QVBoxLayout( this ); | 111 | Q3BoxLayout *topLayout = new Q3VBoxLayout( this ); |
104 | topLayout->setSpacing( KDialog::spacingHint() ); | 112 | topLayout->setSpacing( KDialog::spacingHint() ); |
105 | topLayout->setMargin( KDialog::marginHintSmall() ); | 113 | topLayout->setMargin( KDialog::marginHintSmall() ); |
106 | 114 | ||
107 | //topLayout->addStretch( 1 ); | 115 | //topLayout->addStretch( 1 ); |
108 | 116 | ||
109 | QBoxLayout *weeksLayout = new QHBoxLayout( topLayout ); | 117 | Q3BoxLayout *weeksLayout = new Q3HBoxLayout( topLayout ); |
110 | 118 | ||
111 | QLabel *preLabel = new QLabel( i18n("Recur every"), this ); | 119 | QLabel *preLabel = new QLabel( i18n("Recur every"), this ); |
112 | weeksLayout->addWidget( preLabel ); | 120 | weeksLayout->addWidget( preLabel ); |
113 | 121 | ||
@@ -115,10 +123,10 @@ RecurWeekly::RecurWeekly( QWidget *parent, const char *name ) : | |||
115 | 123 | ||
116 | QLabel *postLabel = new QLabel( i18n("week(s) on:"), this ); | 124 | QLabel *postLabel = new QLabel( i18n("week(s) on:"), this ); |
117 | weeksLayout->addWidget( postLabel ); | 125 | weeksLayout->addWidget( postLabel ); |
118 | 126 | ||
119 | QHBox *dayBox = new QHBox( this ); | 127 | Q3HBox *dayBox = new Q3HBox( this ); |
120 | topLayout->addWidget( dayBox, 1, AlignVCenter ); | 128 | topLayout->addWidget( dayBox, 1, Qt::AlignVCenter ); |
121 | // TODO: Respect start of week setting | 129 | // TODO: Respect start of week setting |
122 | for ( int i = 0; i < 7; ++i ) { | 130 | for ( int i = 0; i < 7; ++i ) { |
123 | QString weekDayName = KGlobal::locale()->weekDayName( i + 1, true ); | 131 | QString weekDayName = KGlobal::locale()->weekDayName( i + 1, true ); |
124 | int left = 1; | 132 | int left = 1; |
@@ -155,14 +163,14 @@ QBitArray RecurWeekly::days() | |||
155 | 163 | ||
156 | RecurMonthly::RecurMonthly( QWidget *parent, const char *name ) : | 164 | RecurMonthly::RecurMonthly( QWidget *parent, const char *name ) : |
157 | RecurBase( parent, name ) | 165 | RecurBase( parent, name ) |
158 | { | 166 | { |
159 | QBoxLayout *topLayout = new QVBoxLayout( this ); | 167 | Q3BoxLayout *topLayout = new Q3VBoxLayout( this ); |
160 | topLayout->setSpacing( KDialog::spacingHint() ); | 168 | topLayout->setSpacing( KDialog::spacingHint() ); |
161 | topLayout->setMargin( KDialog::marginHintSmall() ); | 169 | topLayout->setMargin( KDialog::marginHintSmall() ); |
162 | 170 | ||
163 | 171 | ||
164 | QBoxLayout *freqLayout = new QHBoxLayout( topLayout ); | 172 | Q3BoxLayout *freqLayout = new Q3HBoxLayout( topLayout ); |
165 | 173 | ||
166 | QLabel *preLabel = new QLabel( i18n("every"), this ); | 174 | QLabel *preLabel = new QLabel( i18n("every"), this ); |
167 | freqLayout->addWidget( preLabel ); | 175 | freqLayout->addWidget( preLabel ); |
168 | 176 | ||
@@ -171,13 +179,13 @@ RecurMonthly::RecurMonthly( QWidget *parent, const char *name ) : | |||
171 | QLabel *postLabel = new QLabel( i18n("month(s)"), this ); | 179 | QLabel *postLabel = new QLabel( i18n("month(s)"), this ); |
172 | freqLayout->addWidget( postLabel ); | 180 | freqLayout->addWidget( postLabel ); |
173 | 181 | ||
174 | 182 | ||
175 | QButtonGroup *buttonGroup = new QButtonGroup( this ); | 183 | Q3ButtonGroup *buttonGroup = new Q3ButtonGroup( this ); |
176 | buttonGroup->setFrameStyle( QFrame::NoFrame ); | 184 | buttonGroup->setFrameStyle( Q3Frame::NoFrame ); |
177 | topLayout->addWidget( buttonGroup, 1, AlignVCenter ); | 185 | topLayout->addWidget( buttonGroup, 1, Qt::AlignVCenter ); |
178 | 186 | ||
179 | QGridLayout *buttonLayout = new QGridLayout( buttonGroup, 3, 2 ); | 187 | Q3GridLayout *buttonLayout = new Q3GridLayout( buttonGroup, 3, 2 ); |
180 | buttonLayout->setSpacing( KDialog::spacingHint() ); | 188 | buttonLayout->setSpacing( KDialog::spacingHint() ); |
181 | buttonLayout->setMargin( KDialog::marginHintSmall() ); | 189 | buttonLayout->setMargin( KDialog::marginHintSmall() ); |
182 | 190 | ||
183 | 191 | ||
@@ -188,9 +196,9 @@ RecurMonthly::RecurMonthly( QWidget *parent, const char *name ) : | |||
188 | 196 | ||
189 | mByDayRadio = new QRadioButton( recurOnText, buttonGroup ); | 197 | mByDayRadio = new QRadioButton( recurOnText, buttonGroup ); |
190 | buttonLayout->addWidget( mByDayRadio, 0, 0 ); | 198 | buttonLayout->addWidget( mByDayRadio, 0, 0 ); |
191 | 199 | ||
192 | mByDayCombo = new QComboBox( buttonGroup ); | 200 | mByDayCombo = new Q3ComboBox( buttonGroup ); |
193 | mByDayCombo->setSizeLimit( 7 ); | 201 | mByDayCombo->setSizeLimit( 7 ); |
194 | mByDayCombo->insertItem( i18n("1st") ); | 202 | mByDayCombo->insertItem( i18n("1st") ); |
195 | mByDayCombo->insertItem( i18n("2nd") ); | 203 | mByDayCombo->insertItem( i18n("2nd") ); |
196 | mByDayCombo->insertItem( i18n("3rd") ); | 204 | mByDayCombo->insertItem( i18n("3rd") ); |
@@ -292,14 +300,14 @@ int RecurMonthly::weekday() | |||
292 | 300 | ||
293 | RecurYearly::RecurYearly( QWidget *parent, const char *name ) : | 301 | RecurYearly::RecurYearly( QWidget *parent, const char *name ) : |
294 | RecurBase( parent, name ) | 302 | RecurBase( parent, name ) |
295 | { | 303 | { |
296 | QBoxLayout *topLayout = new QVBoxLayout( this ); | 304 | Q3BoxLayout *topLayout = new Q3VBoxLayout( this ); |
297 | topLayout->setSpacing( KDialog::spacingHint() ); | 305 | topLayout->setSpacing( KDialog::spacingHint() ); |
298 | topLayout->setMargin( KDialog::marginHintSmall() ); | 306 | topLayout->setMargin( KDialog::marginHintSmall() ); |
299 | 307 | ||
300 | 308 | ||
301 | QBoxLayout *freqLayout = new QHBoxLayout( topLayout ); | 309 | Q3BoxLayout *freqLayout = new Q3HBoxLayout( topLayout ); |
302 | 310 | ||
303 | QLabel *preLabel = new QLabel( i18n("every"), this ); | 311 | QLabel *preLabel = new QLabel( i18n("every"), this ); |
304 | freqLayout->addWidget( preLabel ); | 312 | freqLayout->addWidget( preLabel ); |
305 | 313 | ||
@@ -308,20 +316,20 @@ RecurYearly::RecurYearly( QWidget *parent, const char *name ) : | |||
308 | QLabel *postLabel = new QLabel( i18n("year(s)"), this ); | 316 | QLabel *postLabel = new QLabel( i18n("year(s)"), this ); |
309 | freqLayout->addWidget( postLabel ); | 317 | freqLayout->addWidget( postLabel ); |
310 | 318 | ||
311 | 319 | ||
312 | QButtonGroup *buttonGroup = new QButtonGroup( this ); | 320 | Q3ButtonGroup *buttonGroup = new Q3ButtonGroup( this ); |
313 | buttonGroup->setFrameStyle( QFrame::NoFrame ); | 321 | buttonGroup->setFrameStyle( Q3Frame::NoFrame ); |
314 | topLayout->addWidget( buttonGroup, 1, AlignVCenter ); | 322 | topLayout->addWidget( buttonGroup, 1, Qt::AlignVCenter ); |
315 | 323 | ||
316 | QGridLayout *buttonLayout = new QGridLayout( buttonGroup, 2, 3 ); | 324 | Q3GridLayout *buttonLayout = new Q3GridLayout( buttonGroup, 2, 3 ); |
317 | 325 | ||
318 | mByMonthRadio = new QRadioButton( i18n("On day "), buttonGroup); | 326 | mByMonthRadio = new QRadioButton( i18n("On day "), buttonGroup); |
319 | buttonLayout->addWidget( mByMonthRadio, 0, 0 , Qt::AlignRight); | 327 | buttonLayout->addWidget( mByMonthRadio, 0, 0 , Qt::AlignRight); |
320 | mByDayLabel = new QLabel( i18n("%1 of ").arg(1), buttonGroup ); | 328 | mByDayLabel = new QLabel( i18n("%1 of ").arg(1), buttonGroup ); |
321 | 329 | ||
322 | buttonLayout->addWidget( mByDayLabel, 0, 1 ); | 330 | buttonLayout->addWidget( mByDayLabel, 0, 1 ); |
323 | mByMonthCombo = new QComboBox( buttonGroup ); | 331 | mByMonthCombo = new Q3ComboBox( buttonGroup ); |
324 | mByMonthCombo->insertItem( i18n("January") ); | 332 | mByMonthCombo->insertItem( i18n("January") ); |
325 | mByMonthCombo->insertItem( i18n("February") ); | 333 | mByMonthCombo->insertItem( i18n("February") ); |
326 | mByMonthCombo->insertItem( i18n("March") ); | 334 | mByMonthCombo->insertItem( i18n("March") ); |
327 | mByMonthCombo->insertItem( i18n("April") ); | 335 | mByMonthCombo->insertItem( i18n("April") ); |
@@ -382,17 +390,17 @@ int RecurYearly::day() | |||
382 | 390 | ||
383 | ExceptionsWidget::ExceptionsWidget( QWidget *parent, const char *name ) : | 391 | ExceptionsWidget::ExceptionsWidget( QWidget *parent, const char *name ) : |
384 | QWidget( parent, name ) | 392 | QWidget( parent, name ) |
385 | { | 393 | { |
386 | QBoxLayout *topLayout = new QVBoxLayout( this ); | 394 | Q3BoxLayout *topLayout = new Q3VBoxLayout( this ); |
387 | 395 | ||
388 | QGroupBox *groupBox = new QGroupBox( 1, Horizontal, i18n("Exceptions"), | 396 | Q3GroupBox *groupBox = new Q3GroupBox( 1, Qt::Horizontal, i18n("Exceptions"), |
389 | this ); | 397 | this ); |
390 | topLayout->addWidget( groupBox ); | 398 | topLayout->addWidget( groupBox ); |
391 | 399 | ||
392 | QWidget *box = new QWidget( groupBox ); | 400 | QWidget *box = new QWidget( groupBox ); |
393 | 401 | ||
394 | QGridLayout *boxLayout = new QGridLayout( box ); | 402 | Q3GridLayout *boxLayout = new Q3GridLayout( box ); |
395 | 403 | ||
396 | mExceptionDateEdit = new KDateEdit( box ); | 404 | mExceptionDateEdit = new KDateEdit( box ); |
397 | boxLayout->addWidget( mExceptionDateEdit, 0, 0 ); | 405 | boxLayout->addWidget( mExceptionDateEdit, 0, 0 ); |
398 | 406 | ||
@@ -402,9 +410,9 @@ ExceptionsWidget::ExceptionsWidget( QWidget *parent, const char *name ) : | |||
402 | boxLayout->addWidget( changeExceptionButton, 2, 0 ); | 410 | boxLayout->addWidget( changeExceptionButton, 2, 0 ); |
403 | QPushButton *deleteExceptionButton = new QPushButton( i18n("Delete"), box ); | 411 | QPushButton *deleteExceptionButton = new QPushButton( i18n("Delete"), box ); |
404 | boxLayout->addWidget( deleteExceptionButton, 3, 0 ); | 412 | boxLayout->addWidget( deleteExceptionButton, 3, 0 ); |
405 | 413 | ||
406 | mExceptionList = new QListBox( box ); | 414 | mExceptionList = new Q3ListBox( box ); |
407 | boxLayout->addMultiCellWidget( mExceptionList, 0, 3, 1, 1 ); | 415 | boxLayout->addMultiCellWidget( mExceptionList, 0, 3, 1, 1 ); |
408 | 416 | ||
409 | boxLayout->setRowStretch( 4, 1 ); | 417 | boxLayout->setRowStretch( 4, 1 ); |
410 | boxLayout->setColStretch( 1, 3 ); | 418 | boxLayout->setColStretch( 1, 3 ); |
@@ -505,29 +513,29 @@ DateList ExceptionsDialog::dates() | |||
505 | RecurrenceRangeWidget::RecurrenceRangeWidget( QWidget *parent, | 513 | RecurrenceRangeWidget::RecurrenceRangeWidget( QWidget *parent, |
506 | const char *name ) | 514 | const char *name ) |
507 | : QWidget( parent, name ) | 515 | : QWidget( parent, name ) |
508 | { | 516 | { |
509 | QBoxLayout *topLayout = new QVBoxLayout( this ); | 517 | Q3BoxLayout *topLayout = new Q3VBoxLayout( this ); |
510 | 518 | ||
511 | mRangeGroupBox = new QGroupBox( 1, Horizontal, i18n("Recurrence Range"), | 519 | mRangeGroupBox = new Q3GroupBox( 1, Qt::Horizontal, i18n("Recurrence Range"), |
512 | this ); | 520 | this ); |
513 | topLayout->addWidget( mRangeGroupBox ); | 521 | topLayout->addWidget( mRangeGroupBox ); |
514 | 522 | ||
515 | QWidget *rangeBox = new QWidget( mRangeGroupBox ); | 523 | QWidget *rangeBox = new QWidget( mRangeGroupBox ); |
516 | QVBoxLayout *rangeLayout = new QVBoxLayout( rangeBox ); | 524 | Q3VBoxLayout *rangeLayout = new Q3VBoxLayout( rangeBox ); |
517 | rangeLayout->setSpacing( KDialog::spacingHint() ); | 525 | rangeLayout->setSpacing( KDialog::spacingHint() ); |
518 | rangeLayout->setMargin( KDialog::marginHintSmall() ); | 526 | rangeLayout->setMargin( KDialog::marginHintSmall() ); |
519 | 527 | ||
520 | mStartDateLabel = new QLabel( i18n("Begin on:"), rangeBox ); | 528 | mStartDateLabel = new QLabel( i18n("Begin on:"), rangeBox ); |
521 | rangeLayout->addWidget( mStartDateLabel ); | 529 | rangeLayout->addWidget( mStartDateLabel ); |
522 | 530 | ||
523 | mRangeButtonGroup = new QButtonGroup; | 531 | mRangeButtonGroup = new Q3ButtonGroup; |
524 | 532 | ||
525 | mNoEndDateButton = new QRadioButton( i18n("No ending date"), rangeBox ); | 533 | mNoEndDateButton = new QRadioButton( i18n("No ending date"), rangeBox ); |
526 | mRangeButtonGroup->insert( mNoEndDateButton ); | 534 | mRangeButtonGroup->insert( mNoEndDateButton ); |
527 | rangeLayout->addWidget( mNoEndDateButton ); | 535 | rangeLayout->addWidget( mNoEndDateButton ); |
528 | 536 | ||
529 | QBoxLayout *durationLayout = new QHBoxLayout( rangeLayout ); | 537 | Q3BoxLayout *durationLayout = new Q3HBoxLayout( rangeLayout ); |
530 | durationLayout->setSpacing( KDialog::spacingHint() ); | 538 | durationLayout->setSpacing( KDialog::spacingHint() ); |
531 | 539 | ||
532 | mEndDurationButton = new QRadioButton( i18n("End after"), rangeBox ); | 540 | mEndDurationButton = new QRadioButton( i18n("End after"), rangeBox ); |
533 | mRangeButtonGroup->insert( mEndDurationButton ); | 541 | mRangeButtonGroup->insert( mEndDurationButton ); |
@@ -538,9 +546,9 @@ RecurrenceRangeWidget::RecurrenceRangeWidget( QWidget *parent, | |||
538 | 546 | ||
539 | QLabel *endDurationLabel = new QLabel( i18n("occurrence(s)"), rangeBox ); | 547 | QLabel *endDurationLabel = new QLabel( i18n("occurrence(s)"), rangeBox ); |
540 | durationLayout ->addWidget( endDurationLabel ); | 548 | durationLayout ->addWidget( endDurationLabel ); |
541 | 549 | ||
542 | QBoxLayout *endDateLayout = new QHBoxLayout( rangeLayout ); | 550 | Q3BoxLayout *endDateLayout = new Q3HBoxLayout( rangeLayout ); |
543 | endDateLayout->setSpacing( KDialog::spacingHint() ); | 551 | endDateLayout->setSpacing( KDialog::spacingHint() ); |
544 | 552 | ||
545 | mEndDateButton = new QRadioButton( i18n("End by:"), rangeBox ); | 553 | mEndDateButton = new QRadioButton( i18n("End by:"), rangeBox ); |
546 | mRangeButtonGroup->insert( mEndDateButton ); | 554 | mRangeButtonGroup->insert( mEndDateButton ); |
@@ -665,9 +673,9 @@ void RecurrenceRangeDialog::setDateTimes( const QDateTime &start, | |||
665 | 673 | ||
666 | RecurrenceChooser::RecurrenceChooser( QWidget *parent, const char *name ) : | 674 | RecurrenceChooser::RecurrenceChooser( QWidget *parent, const char *name ) : |
667 | QWidget( parent, name ) | 675 | QWidget( parent, name ) |
668 | { | 676 | { |
669 | QBoxLayout *topLayout = new QVBoxLayout( this ); | 677 | Q3BoxLayout *topLayout = new Q3VBoxLayout( this ); |
670 | 678 | ||
671 | mTypeCombo = new QComboBox( this ); | 679 | mTypeCombo = new QComboBox( this ); |
672 | mTypeCombo->insertItem( i18n("Daily") ); | 680 | mTypeCombo->insertItem( i18n("Daily") ); |
673 | mTypeCombo->insertItem( i18n("Weekly") ); | 681 | mTypeCombo->insertItem( i18n("Weekly") ); |
@@ -724,9 +732,9 @@ void RecurrenceChooser::emitChoice() | |||
724 | 732 | ||
725 | KOEditorRecurrence::KOEditorRecurrence( QWidget* parent, const char *name ) : | 733 | KOEditorRecurrence::KOEditorRecurrence( QWidget* parent, const char *name ) : |
726 | QWidget( parent, name ) | 734 | QWidget( parent, name ) |
727 | { | 735 | { |
728 | QGridLayout *topLayout = new QGridLayout( this, 2,2 ); | 736 | Q3GridLayout *topLayout = new Q3GridLayout( this, 2,2 ); |
729 | topLayout->setSpacing( KDialog::spacingHint() ); | 737 | topLayout->setSpacing( KDialog::spacingHint() ); |
730 | topLayout->setMargin( KDialog::marginHintSmall() ); | 738 | topLayout->setMargin( KDialog::marginHintSmall() ); |
731 | 739 | ||
732 | mEnabledCheck = new QCheckBox( i18n("Enable Recurrence"), this ); | 740 | mEnabledCheck = new QCheckBox( i18n("Enable Recurrence"), this ); |
@@ -734,9 +742,9 @@ KOEditorRecurrence::KOEditorRecurrence( QWidget* parent, const char *name ) : | |||
734 | SLOT( setEnabled( bool ) ) ); | 742 | SLOT( setEnabled( bool ) ) ); |
735 | topLayout->addMultiCellWidget( mEnabledCheck, 0, 0, 0, 1 ); | 743 | topLayout->addMultiCellWidget( mEnabledCheck, 0, 0, 0, 1 ); |
736 | 744 | ||
737 | 745 | ||
738 | mTimeGroupBox = new QGroupBox( 1, Horizontal, i18n("Time"), | 746 | mTimeGroupBox = new Q3GroupBox( 1, Qt::Horizontal, i18n("Time"), |
739 | this ); | 747 | this ); |
740 | topLayout->addMultiCellWidget( mTimeGroupBox, 1, 1 , 0 , 1 ); | 748 | topLayout->addMultiCellWidget( mTimeGroupBox, 1, 1 , 0 , 1 ); |
741 | 749 | ||
742 | if ( QApplication::desktop()->width() <= 640 ) { | 750 | if ( QApplication::desktop()->width() <= 640 ) { |
@@ -751,16 +759,16 @@ KOEditorRecurrence::KOEditorRecurrence( QWidget* parent, const char *name ) : | |||
751 | // mDateTimeLabel = new QLabel( timeFrame ); | 759 | // mDateTimeLabel = new QLabel( timeFrame ); |
752 | // layoutTimeFrame->addWidget( mDateTimeLabel ); | 760 | // layoutTimeFrame->addWidget( mDateTimeLabel ); |
753 | //mTimeGroupBox->setSizePolicy( QSizePolicy( QSizePolicy::Preferred, QSizePolicy::Maximum ) ); | 761 | //mTimeGroupBox->setSizePolicy( QSizePolicy( QSizePolicy::Preferred, QSizePolicy::Maximum ) ); |
754 | //mDateTimeLabel->setSizePolicy( QSizePolicy( QSizePolicy::Preferred, QSizePolicy::Maximum) ); | 762 | //mDateTimeLabel->setSizePolicy( QSizePolicy( QSizePolicy::Preferred, QSizePolicy::Maximum) ); |
755 | mRuleBox = new QGroupBox( 1, Horizontal, i18n("Recurrence Rule"), this ); | 763 | mRuleBox = new Q3GroupBox( 1, Qt::Horizontal, i18n("Recurrence Rule"), this ); |
756 | topLayout->addMultiCellWidget( mRuleBox, 2, 2, 0, 1 ); | 764 | topLayout->addMultiCellWidget( mRuleBox, 2, 2, 0, 1 ); |
757 | mRecurrenceChooser = new RecurrenceChooser( mRuleBox ); | 765 | mRecurrenceChooser = new RecurrenceChooser( mRuleBox ); |
758 | connect( mRecurrenceChooser, SIGNAL( chosen( int ) ), | 766 | connect( mRecurrenceChooser, SIGNAL( chosen( int ) ), |
759 | SLOT( showCurrentRule( int ) ) ); | 767 | SLOT( showCurrentRule( int ) ) ); |
760 | 768 | ||
761 | 769 | ||
762 | mRuleStack = new QWidgetStack( mRuleBox ); | 770 | mRuleStack = new Q3WidgetStack( mRuleBox ); |
763 | 771 | ||
764 | mDaily = new RecurDaily( mRuleStack ); | 772 | mDaily = new RecurDaily( mRuleStack ); |
765 | mRuleStack->addWidget( mDaily, 0 ); | 773 | mRuleStack->addWidget( mDaily, 0 ); |
766 | 774 | ||
@@ -895,10 +903,10 @@ void KOEditorRecurrence::readEvent(Incidence *event) | |||
895 | dtEnd = ((Todo*)event)->dtDue(); | 903 | dtEnd = ((Todo*)event)->dtDue(); |
896 | 904 | ||
897 | setDefaults( event->dtStart(), dtEnd ); | 905 | setDefaults( event->dtStart(), dtEnd ); |
898 | QBitArray rDays( 7 ); | 906 | QBitArray rDays( 7 ); |
899 | QPtrList<Recurrence::rMonthPos> rmp; | 907 | Q3PtrList<Recurrence::rMonthPos> rmp; |
900 | QPtrList<int> rmd; | 908 | Q3PtrList<int> rmd; |
901 | int day = 0; | 909 | int day = 0; |
902 | int count = 0; | 910 | int count = 0; |
903 | int month = 0; | 911 | int month = 0; |
904 | setDateTimes( event->dtStart(), dtEnd ); | 912 | setDateTimes( event->dtStart(), dtEnd ); |
@@ -967,9 +975,9 @@ void KOEditorRecurrence::readEvent(Incidence *event) | |||
967 | month = event->dtStart().date().month() ; | 975 | month = event->dtStart().date().month() ; |
968 | mYearly->setByMonth( month, day ); | 976 | mYearly->setByMonth( month, day ); |
969 | #if 0 | 977 | #if 0 |
970 | //qDebug("2day = %d ",day ); | 978 | //qDebug("2day = %d ",day ); |
971 | QPtrList<Recurrence::rMonthPos> monthlist = r->yearMonthPositions(); | 979 | Q3PtrList<Recurrence::rMonthPos> monthlist = r->yearMonthPositions(); |
972 | int month; | 980 | int month; |
973 | if ( !monthlist.isEmpty() ) { | 981 | if ( !monthlist.isEmpty() ) { |
974 | month = monthlist.first()->rPos ; | 982 | month = monthlist.first()->rPos ; |
975 | } else { | 983 | } else { |