author | zautrix <zautrix> | 2005-07-29 20:08:52 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-07-29 20:08:52 (UTC) |
commit | e287df45507793e2e5ad16085a858153f3798941 (patch) (unidiff) | |
tree | f91ff66a8ac59254b9a0158e55d6254ca2928d75 | |
parent | 48a8fa71f1985fea9df4981808796ef65f0f974a (diff) | |
download | kdepimpi-e287df45507793e2e5ad16085a858153f3798941.zip kdepimpi-e287df45507793e2e5ad16085a858153f3798941.tar.gz kdepimpi-e287df45507793e2e5ad16085a858153f3798941.tar.bz2 |
fixx
-rw-r--r-- | korganizer/koeditorrecurrence.cpp | 12 | ||||
-rw-r--r-- | korganizer/koeditorrecurrence.h | 3 | ||||
-rw-r--r-- | libkcal/calendarlocal.cpp | 2 | ||||
-rw-r--r-- | libkcal/icalformatimpl.cpp | 11 | ||||
-rw-r--r-- | libkcal/journal.cpp | 2 |
5 files changed, 21 insertions, 9 deletions
diff --git a/korganizer/koeditorrecurrence.cpp b/korganizer/koeditorrecurrence.cpp index 89504db..0e74a99 100644 --- a/korganizer/koeditorrecurrence.cpp +++ b/korganizer/koeditorrecurrence.cpp | |||
@@ -515,36 +515,36 @@ RecurrenceRangeWidget::RecurrenceRangeWidget( QWidget *parent, | |||
515 | rangeLayout->setSpacing( KDialog::spacingHint() ); | 515 | rangeLayout->setSpacing( KDialog::spacingHint() ); |
516 | rangeLayout->setMargin( KDialog::marginHintSmall() ); | 516 | rangeLayout->setMargin( KDialog::marginHintSmall() ); |
517 | 517 | ||
518 | mStartDateLabel = new QLabel( i18n("Begin on:"), rangeBox ); | 518 | mStartDateLabel = new QLabel( i18n("Begin on:"), rangeBox ); |
519 | rangeLayout->addWidget( mStartDateLabel ); | 519 | rangeLayout->addWidget( mStartDateLabel ); |
520 | 520 | ||
521 | QButtonGroup *rangeButtonGroup = new QButtonGroup; | 521 | mRangeButtonGroup = new QButtonGroup; |
522 | 522 | ||
523 | mNoEndDateButton = new QRadioButton( i18n("No ending date"), rangeBox ); | 523 | mNoEndDateButton = new QRadioButton( i18n("No ending date"), rangeBox ); |
524 | rangeButtonGroup->insert( mNoEndDateButton ); | 524 | mRangeButtonGroup->insert( mNoEndDateButton ); |
525 | rangeLayout->addWidget( mNoEndDateButton ); | 525 | rangeLayout->addWidget( mNoEndDateButton ); |
526 | 526 | ||
527 | QBoxLayout *durationLayout = new QHBoxLayout( rangeLayout ); | 527 | QBoxLayout *durationLayout = new QHBoxLayout( rangeLayout ); |
528 | durationLayout->setSpacing( KDialog::spacingHint() ); | 528 | durationLayout->setSpacing( KDialog::spacingHint() ); |
529 | 529 | ||
530 | mEndDurationButton = new QRadioButton( i18n("End after"), rangeBox ); | 530 | mEndDurationButton = new QRadioButton( i18n("End after"), rangeBox ); |
531 | rangeButtonGroup->insert( mEndDurationButton ); | 531 | mRangeButtonGroup->insert( mEndDurationButton ); |
532 | durationLayout->addWidget( mEndDurationButton ); | 532 | durationLayout->addWidget( mEndDurationButton ); |
533 | 533 | ||
534 | mEndDurationEdit = new QSpinBox( 1, 9999, 1, rangeBox ); | 534 | mEndDurationEdit = new QSpinBox( 1, 9999, 1, rangeBox ); |
535 | durationLayout->addWidget( mEndDurationEdit ); | 535 | durationLayout->addWidget( mEndDurationEdit ); |
536 | 536 | ||
537 | QLabel *endDurationLabel = new QLabel( i18n("occurrence(s)"), rangeBox ); | 537 | QLabel *endDurationLabel = new QLabel( i18n("occurrence(s)"), rangeBox ); |
538 | durationLayout ->addWidget( endDurationLabel ); | 538 | durationLayout ->addWidget( endDurationLabel ); |
539 | 539 | ||
540 | QBoxLayout *endDateLayout = new QHBoxLayout( rangeLayout ); | 540 | QBoxLayout *endDateLayout = new QHBoxLayout( rangeLayout ); |
541 | endDateLayout->setSpacing( KDialog::spacingHint() ); | 541 | endDateLayout->setSpacing( KDialog::spacingHint() ); |
542 | 542 | ||
543 | mEndDateButton = new QRadioButton( i18n("End by:"), rangeBox ); | 543 | mEndDateButton = new QRadioButton( i18n("End by:"), rangeBox ); |
544 | rangeButtonGroup->insert( mEndDateButton ); | 544 | mRangeButtonGroup->insert( mEndDateButton ); |
545 | endDateLayout->addWidget( mEndDateButton ); | 545 | endDateLayout->addWidget( mEndDateButton ); |
546 | 546 | ||
547 | mEndDateEdit = new KDateEdit( rangeBox ); | 547 | mEndDateEdit = new KDateEdit( rangeBox ); |
548 | endDateLayout->addWidget( mEndDateEdit ); | 548 | endDateLayout->addWidget( mEndDateEdit ); |
549 | 549 | ||
550 | //endDateLayout->addStretch( 1 ); | 550 | //endDateLayout->addStretch( 1 ); |
@@ -554,12 +554,16 @@ RecurrenceRangeWidget::RecurrenceRangeWidget( QWidget *parent, | |||
554 | connect( mEndDurationButton, SIGNAL( toggled( bool ) ), | 554 | connect( mEndDurationButton, SIGNAL( toggled( bool ) ), |
555 | SLOT( showCurrentRange() ) ); | 555 | SLOT( showCurrentRange() ) ); |
556 | connect( mEndDateButton, SIGNAL( toggled( bool ) ), | 556 | connect( mEndDateButton, SIGNAL( toggled( bool ) ), |
557 | SLOT( showCurrentRange() ) ); | 557 | SLOT( showCurrentRange() ) ); |
558 | } | 558 | } |
559 | 559 | ||
560 | RecurrenceRangeWidget::~RecurrenceRangeWidget() | ||
561 | { | ||
562 | delete mRangeButtonGroup; | ||
563 | } | ||
560 | void RecurrenceRangeWidget::setDefaults( const QDateTime &from ) | 564 | void RecurrenceRangeWidget::setDefaults( const QDateTime &from ) |
561 | { | 565 | { |
562 | mNoEndDateButton->setChecked( true ); | 566 | mNoEndDateButton->setChecked( true ); |
563 | 567 | ||
564 | setDateTimes( from ); | 568 | setDateTimes( from ); |
565 | mEndDateEdit->setDate( from.date() ); | 569 | mEndDateEdit->setDate( from.date() ); |
diff --git a/korganizer/koeditorrecurrence.h b/korganizer/koeditorrecurrence.h index f398f62..75e0c73 100644 --- a/korganizer/koeditorrecurrence.h +++ b/korganizer/koeditorrecurrence.h | |||
@@ -30,12 +30,13 @@ | |||
30 | #include <qgroupbox.h> | 30 | #include <qgroupbox.h> |
31 | #include <qlineedit.h> | 31 | #include <qlineedit.h> |
32 | #include <qcombobox.h> | 32 | #include <qcombobox.h> |
33 | #include <qmultilineedit.h> | 33 | #include <qmultilineedit.h> |
34 | #include <qlistview.h> | 34 | #include <qlistview.h> |
35 | #include <qradiobutton.h> | 35 | #include <qradiobutton.h> |
36 | #include <qbuttongroup.h> | ||
36 | 37 | ||
37 | #include <kdialogbase.h> | 38 | #include <kdialogbase.h> |
38 | 39 | ||
39 | #include <libkcal/event.h> | 40 | #include <libkcal/event.h> |
40 | 41 | ||
41 | #include "ktimeedit.h" | 42 | #include "ktimeedit.h" |
@@ -214,12 +215,13 @@ class RecurrenceRangeBase | |||
214 | 215 | ||
215 | class RecurrenceRangeWidget : public QWidget, public RecurrenceRangeBase | 216 | class RecurrenceRangeWidget : public QWidget, public RecurrenceRangeBase |
216 | { | 217 | { |
217 | Q_OBJECT | 218 | Q_OBJECT |
218 | public: | 219 | public: |
219 | RecurrenceRangeWidget( QWidget *parent = 0, const char *name = 0 ); | 220 | RecurrenceRangeWidget( QWidget *parent = 0, const char *name = 0 ); |
221 | ~RecurrenceRangeWidget(); | ||
220 | 222 | ||
221 | void setDefaults( const QDateTime &from ); | 223 | void setDefaults( const QDateTime &from ); |
222 | 224 | ||
223 | void setDuration( int ); | 225 | void setDuration( int ); |
224 | int duration(); | 226 | int duration(); |
225 | 227 | ||
@@ -230,12 +232,13 @@ class RecurrenceRangeWidget : public QWidget, public RecurrenceRangeBase | |||
230 | const QDateTime &end = QDateTime() ); | 232 | const QDateTime &end = QDateTime() ); |
231 | 233 | ||
232 | protected slots: | 234 | protected slots: |
233 | void showCurrentRange(); | 235 | void showCurrentRange(); |
234 | 236 | ||
235 | private: | 237 | private: |
238 | QButtonGroup *mRangeButtonGroup; | ||
236 | QGroupBox *mRangeGroupBox; | 239 | QGroupBox *mRangeGroupBox; |
237 | QLabel *mStartDateLabel; | 240 | QLabel *mStartDateLabel; |
238 | QRadioButton *mNoEndDateButton; | 241 | QRadioButton *mNoEndDateButton; |
239 | QRadioButton *mEndDurationButton; | 242 | QRadioButton *mEndDurationButton; |
240 | QSpinBox *mEndDurationEdit; | 243 | QSpinBox *mEndDurationEdit; |
241 | QRadioButton *mEndDateButton; | 244 | QRadioButton *mEndDateButton; |
diff --git a/libkcal/calendarlocal.cpp b/libkcal/calendarlocal.cpp index eef8327..5baa7dc 100644 --- a/libkcal/calendarlocal.cpp +++ b/libkcal/calendarlocal.cpp | |||
@@ -253,13 +253,13 @@ void CalendarLocal::close() | |||
253 | 253 | ||
254 | Todo * i; | 254 | Todo * i; |
255 | for( i = mTodoList.first(); i; i = mTodoList.next() ) i->setRunning(false); | 255 | for( i = mTodoList.first(); i; i = mTodoList.next() ) i->setRunning(false); |
256 | 256 | ||
257 | mEventList.setAutoDelete( true ); | 257 | mEventList.setAutoDelete( true ); |
258 | mTodoList.setAutoDelete( true ); | 258 | mTodoList.setAutoDelete( true ); |
259 | mJournalList.setAutoDelete( false ); | 259 | mJournalList.setAutoDelete( true ); |
260 | 260 | ||
261 | mEventList.clear(); | 261 | mEventList.clear(); |
262 | mTodoList.clear(); | 262 | mTodoList.clear(); |
263 | mJournalList.clear(); | 263 | mJournalList.clear(); |
264 | 264 | ||
265 | mEventList.setAutoDelete( false ); | 265 | mEventList.setAutoDelete( false ); |
diff --git a/libkcal/icalformatimpl.cpp b/libkcal/icalformatimpl.cpp index f349681..53aa039 100644 --- a/libkcal/icalformatimpl.cpp +++ b/libkcal/icalformatimpl.cpp | |||
@@ -999,13 +999,13 @@ FreeBusy *ICalFormatImpl::readFreeBusy(icalcomponent *vfreebusy) | |||
999 | case ICAL_FREEBUSY_PROPERTY: //Any FreeBusy Times | 999 | case ICAL_FREEBUSY_PROPERTY: //Any FreeBusy Times |
1000 | icalperiod = icalproperty_get_freebusy(p); | 1000 | icalperiod = icalproperty_get_freebusy(p); |
1001 | period_start = readICalDateTime(icalperiod.start); | 1001 | period_start = readICalDateTime(icalperiod.start); |
1002 | period_end = readICalDateTime(icalperiod.end); | 1002 | period_end = readICalDateTime(icalperiod.end); |
1003 | freebusy->addPeriod(period_start, period_end); | 1003 | freebusy->addPeriod(period_start, period_end); |
1004 | break; | 1004 | break; |
1005 | 1005 | ||
1006 | default: | 1006 | default: |
1007 | kdDebug(5800) << "ICALFormat::readIncidence(): Unknown property: " << kind | 1007 | kdDebug(5800) << "ICALFormat::readIncidence(): Unknown property: " << kind |
1008 | << endl; | 1008 | << endl; |
1009 | break; | 1009 | break; |
1010 | } | 1010 | } |
1011 | p = icalcomponent_get_next_property(vfreebusy,ICAL_ANY_PROPERTY); | 1011 | p = icalcomponent_get_next_property(vfreebusy,ICAL_ANY_PROPERTY); |
@@ -1941,31 +1941,34 @@ bool ICalFormatImpl::populate( Calendar *cal, icalcomponent *calendar) | |||
1941 | 1941 | ||
1942 | // Iterate through all todos | 1942 | // Iterate through all todos |
1943 | c = icalcomponent_get_first_component(calendar,ICAL_VTODO_COMPONENT); | 1943 | c = icalcomponent_get_first_component(calendar,ICAL_VTODO_COMPONENT); |
1944 | while (c) { | 1944 | while (c) { |
1945 | // kdDebug(5800) << "----Todo found" << endl; | 1945 | // kdDebug(5800) << "----Todo found" << endl; |
1946 | Todo *todo = readTodo(c); | 1946 | Todo *todo = readTodo(c); |
1947 | if (!cal->todo(todo->uid())) cal->addTodo(todo); | 1947 | if (!cal->todo(todo->uid())) |
1948 | cal->addTodo(todo); | ||
1948 | c = icalcomponent_get_next_component(calendar,ICAL_VTODO_COMPONENT); | 1949 | c = icalcomponent_get_next_component(calendar,ICAL_VTODO_COMPONENT); |
1949 | } | 1950 | } |
1950 | 1951 | ||
1951 | // Iterate through all events | 1952 | // Iterate through all events |
1952 | c = icalcomponent_get_first_component(calendar,ICAL_VEVENT_COMPONENT); | 1953 | c = icalcomponent_get_first_component(calendar,ICAL_VEVENT_COMPONENT); |
1953 | while (c) { | 1954 | while (c) { |
1954 | // kdDebug(5800) << "----Event found" << endl; | 1955 | // kdDebug(5800) << "----Event found" << endl; |
1955 | Event *event = readEvent(c); | 1956 | Event *event = readEvent(c); |
1956 | if (!cal->event(event->uid())) cal->addEvent(event); | 1957 | if (!cal->event(event->uid())) |
1958 | cal->addEvent(event); | ||
1957 | c = icalcomponent_get_next_component(calendar,ICAL_VEVENT_COMPONENT); | 1959 | c = icalcomponent_get_next_component(calendar,ICAL_VEVENT_COMPONENT); |
1958 | } | 1960 | } |
1959 | 1961 | ||
1960 | // Iterate through all journals | 1962 | // Iterate through all journals |
1961 | c = icalcomponent_get_first_component(calendar,ICAL_VJOURNAL_COMPONENT); | 1963 | c = icalcomponent_get_first_component(calendar,ICAL_VJOURNAL_COMPONENT); |
1962 | while (c) { | 1964 | while (c) { |
1963 | // kdDebug(5800) << "----Journal found" << endl; | 1965 | // kdDebug(5800) << "----Journal found" << endl; |
1964 | Journal *journal = readJournal(c); | 1966 | Journal *journal = readJournal(c); |
1965 | if (!cal->journal(journal->uid())) cal->addJournal(journal); | 1967 | if (!cal->journal(journal->uid())) |
1968 | cal->addJournal(journal); | ||
1966 | c = icalcomponent_get_next_component(calendar,ICAL_VJOURNAL_COMPONENT); | 1969 | c = icalcomponent_get_next_component(calendar,ICAL_VJOURNAL_COMPONENT); |
1967 | } | 1970 | } |
1968 | 1971 | ||
1969 | #if 0 | 1972 | #if 0 |
1970 | initPropIterator(&i, vcal); | 1973 | initPropIterator(&i, vcal); |
1971 | 1974 | ||
diff --git a/libkcal/journal.cpp b/libkcal/journal.cpp index 859161f..c4e4474 100644 --- a/libkcal/journal.cpp +++ b/libkcal/journal.cpp | |||
@@ -21,16 +21,18 @@ | |||
21 | #include "journal.h" | 21 | #include "journal.h" |
22 | 22 | ||
23 | using namespace KCal; | 23 | using namespace KCal; |
24 | 24 | ||
25 | Journal::Journal() | 25 | Journal::Journal() |
26 | { | 26 | { |
27 | qDebug("New JJJ "); | ||
27 | } | 28 | } |
28 | 29 | ||
29 | Journal::~Journal() | 30 | Journal::~Journal() |
30 | { | 31 | { |
32 | qDebug("delete JJJ "); | ||
31 | } | 33 | } |
32 | 34 | ||
33 | Incidence *Journal::clone() | 35 | Incidence *Journal::clone() |
34 | { | 36 | { |
35 | return new Journal(*this); | 37 | return new Journal(*this); |
36 | } | 38 | } |