author | zautrix <zautrix> | 2004-06-29 12:52:18 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2004-06-29 12:52:18 (UTC) |
commit | 275e70532bb26ed78ce2d3bebf980dd745368ec2 (patch) (unidiff) | |
tree | c9252a9ec50856c86cc1165007f841c50d5cdc51 /korganizer | |
parent | 7b2b9f2b05809b9577837551ad864d88b9b355ef (diff) | |
download | kdepimpi-275e70532bb26ed78ce2d3bebf980dd745368ec2.zip kdepimpi-275e70532bb26ed78ce2d3bebf980dd745368ec2.tar.gz kdepimpi-275e70532bb26ed78ce2d3bebf980dd745368ec2.tar.bz2 |
Removed the include moc on KO dir
47 files changed, 11 insertions, 53 deletions
diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp index 7ac5b11..0956c78 100644 --- a/korganizer/calendarview.cpp +++ b/korganizer/calendarview.cpp | |||
@@ -3442,35 +3442,35 @@ void CalendarView::purgeCompleted() | |||
3442 | bool deletedOne = true; | 3442 | bool deletedOne = true; |
3443 | todoCal = calendar()->todos(); | 3443 | todoCal = calendar()->todos(); |
3444 | for (aTodo = todoCal.first(); aTodo; aTodo = todoCal.next()) { | 3444 | for (aTodo = todoCal.first(); aTodo; aTodo = todoCal.next()) { |
3445 | if ( !aTodo->relatedTo() ) | 3445 | if ( !aTodo->relatedTo() ) |
3446 | rootTodos.append( aTodo ); | 3446 | rootTodos.append( aTodo ); |
3447 | } | 3447 | } |
3448 | for (aTodo = rootTodos.first(); aTodo; aTodo = rootTodos.next()) { | 3448 | for (aTodo = rootTodos.first(); aTodo; aTodo = rootTodos.next()) { |
3449 | removeCompletedSubTodos( aTodo ); | 3449 | removeCompletedSubTodos( aTodo ); |
3450 | } | 3450 | } |
3451 | 3451 | ||
3452 | updateView(); | 3452 | updateView(); |
3453 | } | 3453 | } |
3454 | } | 3454 | } |
3455 | 3455 | ||
3456 | void CalendarView::slotCalendarChanged() | 3456 | void CalendarView::slotCalendarChanged() |
3457 | { | 3457 | { |
3458 | ; | 3458 | ; |
3459 | } | 3459 | } |
3460 | 3460 | ||
3461 | NavigatorBar *CalendarView::navigatorBar() | 3461 | NavigatorBar *CalendarView::navigatorBar() |
3462 | { | 3462 | { |
3463 | return mNavigatorBar; | 3463 | return mNavigatorBar; |
3464 | } | 3464 | } |
3465 | 3465 | ||
3466 | 3466 | ||
3467 | 3467 | ||
3468 | void CalendarView::keyPressEvent ( QKeyEvent *e) | 3468 | void CalendarView::keyPressEvent ( QKeyEvent *e) |
3469 | { | 3469 | { |
3470 | //qDebug(" alendarView::keyPressEvent "); | 3470 | //qDebug(" alendarView::keyPressEvent "); |
3471 | e->ignore(); | 3471 | e->ignore(); |
3472 | } | 3472 | } |
3473 | 3473 | ||
3474 | #include "calendarview.moc" | 3474 | //#include "calendarview.moc" |
3475 | 3475 | ||
3476 | #include "calendarviewbase.moc" | 3476 | //#include "calendarviewbase.moc" |
diff --git a/korganizer/datenavigator.cpp b/korganizer/datenavigator.cpp index 8d35c42..e26e20b 100644 --- a/korganizer/datenavigator.cpp +++ b/korganizer/datenavigator.cpp | |||
@@ -255,33 +255,33 @@ void DateNavigator::selectNextYear() | |||
255 | selectWeekByDay( weekDay, firstSelected ); | 255 | selectWeekByDay( weekDay, firstSelected ); |
256 | } | 256 | } |
257 | 257 | ||
258 | void DateNavigator::selectPrevious() | 258 | void DateNavigator::selectPrevious() |
259 | { | 259 | { |
260 | int offset = -7; | 260 | int offset = -7; |
261 | if ( datesCount() == 1 ) { | 261 | if ( datesCount() == 1 ) { |
262 | offset = -1; | 262 | offset = -1; |
263 | } | 263 | } |
264 | if ( mViewManager ) | 264 | if ( mViewManager ) |
265 | if ( mViewManager->showsNextDays() ) | 265 | if ( mViewManager->showsNextDays() ) |
266 | offset = -datesCount(); | 266 | offset = -datesCount(); |
267 | selectDates( mSelectedDates.first().addDays( offset ), datesCount() ); | 267 | selectDates( mSelectedDates.first().addDays( offset ), datesCount() ); |
268 | } | 268 | } |
269 | 269 | ||
270 | void DateNavigator::selectNext() | 270 | void DateNavigator::selectNext() |
271 | { | 271 | { |
272 | int offset = 7; | 272 | int offset = 7; |
273 | if ( datesCount() == 1 ) { | 273 | if ( datesCount() == 1 ) { |
274 | offset = 1; | 274 | offset = 1; |
275 | } | 275 | } |
276 | if ( mViewManager ) | 276 | if ( mViewManager ) |
277 | if ( mViewManager->showsNextDays() ) | 277 | if ( mViewManager->showsNextDays() ) |
278 | offset = datesCount(); | 278 | offset = datesCount(); |
279 | selectDates( mSelectedDates.first().addDays( offset ), datesCount() ); | 279 | selectDates( mSelectedDates.first().addDays( offset ), datesCount() ); |
280 | } | 280 | } |
281 | 281 | ||
282 | void DateNavigator::emitSelected() | 282 | void DateNavigator::emitSelected() |
283 | { | 283 | { |
284 | emit datesSelected( mSelectedDates ); | 284 | emit datesSelected( mSelectedDates ); |
285 | } | 285 | } |
286 | 286 | ||
287 | #include "datenavigator.moc" | 287 | //#include "datenavigator.moc" |
diff --git a/korganizer/filtereditdialog.cpp b/korganizer/filtereditdialog.cpp index 2943e41..ca09844 100644 --- a/korganizer/filtereditdialog.cpp +++ b/korganizer/filtereditdialog.cpp | |||
@@ -11,65 +11,65 @@ | |||
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
13 | GNU General Public License for more details. | 13 | GNU General Public License for more details. |
14 | 14 | ||
15 | You should have received a copy of the GNU General Public License | 15 | You should have received a copy of the GNU General Public License |
16 | along with this program; if not, write to the Free Software | 16 | along with this program; if not, write to the Free Software |
17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
18 | 18 | ||
19 | As a special exception, permission is given to link this program | 19 | As a special exception, permission is given to link this program |
20 | with any edition of Qt, and distribute the resulting executable, | 20 | with any edition of Qt, and distribute the resulting executable, |
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 <qlayout.h> | 24 | #include <qlayout.h> |
25 | #include <qpushbutton.h> | 25 | #include <qpushbutton.h> |
26 | #include <qcombobox.h> | 26 | #include <qcombobox.h> |
27 | #include <qcheckbox.h> | 27 | #include <qcheckbox.h> |
28 | #include <qradiobutton.h> | 28 | #include <qradiobutton.h> |
29 | #include <qlistbox.h> | 29 | #include <qlistbox.h> |
30 | #include <qapplication.h> | 30 | #include <qapplication.h> |
31 | 31 | ||
32 | #include <kdebug.h> | 32 | #include <kdebug.h> |
33 | #include <klocale.h> | 33 | #include <klocale.h> |
34 | #include <klineeditdlg.h> | 34 | #include <klineeditdlg.h> |
35 | #include <kmessagebox.h> | 35 | #include <kmessagebox.h> |
36 | 36 | ||
37 | #include <libkdepim/categoryselectdialog.h> | 37 | #include <libkdepim/categoryselectdialog.h> |
38 | 38 | ||
39 | #include "koprefs.h" | 39 | #include "koprefs.h" |
40 | #include "filteredit_base.h" | 40 | #include "filteredit_base.h" |
41 | 41 | ||
42 | #include "filtereditdialog.h" | 42 | #include "filtereditdialog.h" |
43 | #include "filtereditdialog.moc" | 43 | //#include "filtereditdialog.moc" |
44 | 44 | ||
45 | // TODO: Make dialog work on a copy of the filters objects. | 45 | // TODO: Make dialog work on a copy of the filters objects. |
46 | 46 | ||
47 | class ComboFilterBox: public QComboBox | 47 | class ComboFilterBox: public QComboBox |
48 | { | 48 | { |
49 | public: | 49 | public: |
50 | ComboFilterBox( QWidget *parent=0, const char *name=0) : | 50 | ComboFilterBox( QWidget *parent=0, const char *name=0) : |
51 | QComboBox( parent,name ) { } | 51 | QComboBox( parent,name ) { } |
52 | void popupBox() { popup(); } | 52 | void popupBox() { popup(); } |
53 | 53 | ||
54 | }; | 54 | }; |
55 | 55 | ||
56 | FilterEditDialog::FilterEditDialog(QPtrList<CalFilter> *filters,QWidget *parent, | 56 | FilterEditDialog::FilterEditDialog(QPtrList<CalFilter> *filters,QWidget *parent, |
57 | const char *name) : | 57 | const char *name) : |
58 | KDialogBase(parent,name,true,i18n("Edit Calendar Filters"), | 58 | KDialogBase(parent,name,true,i18n("Edit Calendar Filters"), |
59 | Ok|Apply|Cancel) | 59 | Ok|Apply|Cancel) |
60 | { | 60 | { |
61 | mFilters = filters; | 61 | mFilters = filters; |
62 | 62 | ||
63 | QWidget *mainWidget = new QWidget(this); | 63 | QWidget *mainWidget = new QWidget(this); |
64 | setMainWidget(mainWidget); | 64 | setMainWidget(mainWidget); |
65 | 65 | ||
66 | mSelectionCombo = new ComboFilterBox(mainWidget); | 66 | mSelectionCombo = new ComboFilterBox(mainWidget); |
67 | connect(mSelectionCombo,SIGNAL(activated(int)),SLOT(filterSelected())); | 67 | connect(mSelectionCombo,SIGNAL(activated(int)),SLOT(filterSelected())); |
68 | // mSelectionCombo->setEditable ( true ); | 68 | // mSelectionCombo->setEditable ( true ); |
69 | QPushButton *addButton = new QPushButton(i18n("Add Filter"),mainWidget); | 69 | QPushButton *addButton = new QPushButton(i18n("Add Filter"),mainWidget); |
70 | connect(addButton,SIGNAL(clicked()),SLOT(slotAdd())); | 70 | connect(addButton,SIGNAL(clicked()),SLOT(slotAdd())); |
71 | addButton->setMaximumSize( addButton->sizeHint()); | 71 | addButton->setMaximumSize( addButton->sizeHint()); |
72 | mRemoveButton = new QPushButton( i18n("Remove"), mainWidget ); | 72 | mRemoveButton = new QPushButton( i18n("Remove"), mainWidget ); |
73 | connect( mRemoveButton, SIGNAL( clicked() ), SLOT( slotRemove() ) ); | 73 | connect( mRemoveButton, SIGNAL( clicked() ), SLOT( slotRemove() ) ); |
74 | mRemoveButton->setMaximumSize( mRemoveButton->sizeHint()); | 74 | mRemoveButton->setMaximumSize( mRemoveButton->sizeHint()); |
75 | 75 | ||
diff --git a/korganizer/incomingdialog.cpp b/korganizer/incomingdialog.cpp index 490d21e..f3bd09f 100644 --- a/korganizer/incomingdialog.cpp +++ b/korganizer/incomingdialog.cpp | |||
@@ -495,33 +495,33 @@ bool IncomingDialog::automaticAction(ScheduleItemIn *item) | |||
495 | return autoAction; | 495 | return autoAction; |
496 | } | 496 | } |
497 | 497 | ||
498 | bool IncomingDialog::checkOrganizerInAddressbook(QString organizer) | 498 | bool IncomingDialog::checkOrganizerInAddressbook(QString organizer) |
499 | { | 499 | { |
500 | bool inBook = false; | 500 | bool inBook = false; |
501 | #ifndef KORG_NOKABC | 501 | #ifndef KORG_NOKABC |
502 | KABC::AddressBook *add_book = KABC::StdAddressBook::self(); | 502 | KABC::AddressBook *add_book = KABC::StdAddressBook::self(); |
503 | KABC::Addressee::List addressList; | 503 | KABC::Addressee::List addressList; |
504 | addressList = add_book->findByEmail(organizer); | 504 | addressList = add_book->findByEmail(organizer); |
505 | if ( addressList.size()>0 ) inBook = true; | 505 | if ( addressList.size()>0 ) inBook = true; |
506 | #endif | 506 | #endif |
507 | return inBook; | 507 | return inBook; |
508 | } | 508 | } |
509 | 509 | ||
510 | bool IncomingDialog::checkAttendeesInAddressbook(IncidenceBase *inc) | 510 | bool IncomingDialog::checkAttendeesInAddressbook(IncidenceBase *inc) |
511 | { | 511 | { |
512 | bool inBook = false; | 512 | bool inBook = false; |
513 | #ifndef KORG_NOKABC | 513 | #ifndef KORG_NOKABC |
514 | KABC::AddressBook *add_book = KABC::StdAddressBook::self(); | 514 | KABC::AddressBook *add_book = KABC::StdAddressBook::self(); |
515 | KABC::Addressee::List addressList; | 515 | KABC::Addressee::List addressList; |
516 | QPtrList <Attendee> attendees; | 516 | QPtrList <Attendee> attendees; |
517 | Attendee *att; | 517 | Attendee *att; |
518 | attendees = inc->attendees(); | 518 | attendees = inc->attendees(); |
519 | for (att=attendees.first();att;att=attendees.next()) { | 519 | for (att=attendees.first();att;att=attendees.next()) { |
520 | addressList = add_book->findByEmail(att->email()); | 520 | addressList = add_book->findByEmail(att->email()); |
521 | if (addressList.size()>0 ) inBook = true; | 521 | if (addressList.size()>0 ) inBook = true; |
522 | } | 522 | } |
523 | #endif | 523 | #endif |
524 | return inBook; | 524 | return inBook; |
525 | } | 525 | } |
526 | 526 | ||
527 | #include "incomingdialog.moc" | 527 | //#include "incomingdialog.moc" |
diff --git a/korganizer/incomingdialog_base.cpp b/korganizer/incomingdialog_base.cpp index 91740a4..8589803 100644 --- a/korganizer/incomingdialog_base.cpp +++ b/korganizer/incomingdialog_base.cpp | |||
@@ -105,33 +105,33 @@ void IncomingDialog_base::languageChange() | |||
105 | mMessageListView->header()->setLabel( 1, tr2i18n( "Start Date" ) ); | 105 | mMessageListView->header()->setLabel( 1, tr2i18n( "Start Date" ) ); |
106 | mMessageListView->header()->setLabel( 2, tr2i18n( "Start Time" ) ); | 106 | mMessageListView->header()->setLabel( 2, tr2i18n( "Start Time" ) ); |
107 | mMessageListView->header()->setLabel( 3, tr2i18n( "End Date" ) ); | 107 | mMessageListView->header()->setLabel( 3, tr2i18n( "End Date" ) ); |
108 | mMessageListView->header()->setLabel( 4, tr2i18n( "End Time" ) ); | 108 | mMessageListView->header()->setLabel( 4, tr2i18n( "End Time" ) ); |
109 | mMessageListView->header()->setLabel( 5, tr2i18n( "Organizer" ) ); | 109 | mMessageListView->header()->setLabel( 5, tr2i18n( "Organizer" ) ); |
110 | mMessageListView->header()->setLabel( 6, tr2i18n( "Method" ) ); | 110 | mMessageListView->header()->setLabel( 6, tr2i18n( "Method" ) ); |
111 | mMessageListView->header()->setLabel( 7, tr2i18n( "Status" ) ); | 111 | mMessageListView->header()->setLabel( 7, tr2i18n( "Status" ) ); |
112 | PushButton7_2->setText( tr2i18n( "Accept A&ll" ) ); | 112 | PushButton7_2->setText( tr2i18n( "Accept A&ll" ) ); |
113 | PushButton8->setText( tr2i18n( "&Accept" ) ); | 113 | PushButton8->setText( tr2i18n( "&Accept" ) ); |
114 | PushButton9->setText( tr2i18n( "&Reject" ) ); | 114 | PushButton9->setText( tr2i18n( "&Reject" ) ); |
115 | } | 115 | } |
116 | 116 | ||
117 | void IncomingDialog_base::acceptAllMessages() | 117 | void IncomingDialog_base::acceptAllMessages() |
118 | { | 118 | { |
119 | qWarning( "IncomingDialog_base::acceptAllMessages(): Not implemented yet" ); | 119 | qWarning( "IncomingDialog_base::acceptAllMessages(): Not implemented yet" ); |
120 | } | 120 | } |
121 | 121 | ||
122 | void IncomingDialog_base::acceptMessage() | 122 | void IncomingDialog_base::acceptMessage() |
123 | { | 123 | { |
124 | qWarning( "IncomingDialog_base::acceptMessage(): Not implemented yet" ); | 124 | qWarning( "IncomingDialog_base::acceptMessage(): Not implemented yet" ); |
125 | } | 125 | } |
126 | 126 | ||
127 | void IncomingDialog_base::rejectMessage() | 127 | void IncomingDialog_base::rejectMessage() |
128 | { | 128 | { |
129 | qWarning( "IncomingDialog_base::rejectMessage(): Not implemented yet" ); | 129 | qWarning( "IncomingDialog_base::rejectMessage(): Not implemented yet" ); |
130 | } | 130 | } |
131 | 131 | ||
132 | void IncomingDialog_base::retrieve() | 132 | void IncomingDialog_base::retrieve() |
133 | { | 133 | { |
134 | qWarning( "IncomingDialog_base::retrieve(): Not implemented yet" ); | 134 | qWarning( "IncomingDialog_base::retrieve(): Not implemented yet" ); |
135 | } | 135 | } |
136 | 136 | ||
137 | #include "incomingdialog_base.moc" | 137 | //#include "incomingdialog_base.moc" |
diff --git a/korganizer/journalentry.cpp b/korganizer/journalentry.cpp index d1d7946..7af5cf4 100644 --- a/korganizer/journalentry.cpp +++ b/korganizer/journalentry.cpp | |||
@@ -10,65 +10,65 @@ | |||
10 | This program is distributed in the hope that it will be useful, | 10 | This program is distributed in the hope that it will be useful, |
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
13 | GNU General Public License for more details. | 13 | GNU General Public License for more details. |
14 | 14 | ||
15 | You should have received a copy of the GNU General Public License | 15 | You should have received a copy of the GNU General Public License |
16 | along with this program; if not, write to the Free Software | 16 | along with this program; if not, write to the Free Software |
17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
18 | 18 | ||
19 | As a special exception, permission is given to link this program | 19 | As a special exception, permission is given to link this program |
20 | with any edition of Qt, and distribute the resulting executable, | 20 | with any edition of Qt, and distribute the resulting executable, |
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 | // | 24 | // |
25 | // Journal Entry | 25 | // Journal Entry |
26 | 26 | ||
27 | #include <qlabel.h> | 27 | #include <qlabel.h> |
28 | #include <qlayout.h> | 28 | #include <qlayout.h> |
29 | 29 | ||
30 | #include <kdebug.h> | 30 | #include <kdebug.h> |
31 | #include <kglobal.h> | 31 | #include <kglobal.h> |
32 | #include <klocale.h> | 32 | #include <klocale.h> |
33 | #include <ktextedit.h> | 33 | #include <ktextedit.h> |
34 | #include "koprefs.h" | 34 | #include "koprefs.h" |
35 | 35 | ||
36 | #include <libkcal/journal.h> | 36 | #include <libkcal/journal.h> |
37 | #include <libkcal/calendarresources.h> | 37 | #include <libkcal/calendarresources.h> |
38 | #include <libkcal/resourcecalendar.h> | 38 | #include <libkcal/resourcecalendar.h> |
39 | #include <kresources/resourceselectdialog.h> | 39 | #include <kresources/resourceselectdialog.h> |
40 | 40 | ||
41 | #include "journalentry.h" | 41 | #include "journalentry.h" |
42 | #include "journalentry.moc" | 42 | //#include "journalentry.moc" |
43 | #ifndef DESKTOP_VERSION | 43 | #ifndef DESKTOP_VERSION |
44 | #include <qpe/qpeapplication.h> | 44 | #include <qpe/qpeapplication.h> |
45 | #endif | 45 | #endif |
46 | JournalEntry::JournalEntry(Calendar *calendar,QWidget *parent) : | 46 | JournalEntry::JournalEntry(Calendar *calendar,QWidget *parent) : |
47 | QFrame(parent) | 47 | QFrame(parent) |
48 | { | 48 | { |
49 | mCalendar = calendar; | 49 | mCalendar = calendar; |
50 | mJournal = 0; | 50 | mJournal = 0; |
51 | mDirty = false; | 51 | mDirty = false; |
52 | 52 | ||
53 | mTitleLabel = new QLabel(i18n("Title"),this); | 53 | mTitleLabel = new QLabel(i18n("Title"),this); |
54 | mTitleLabel->setMargin(2); | 54 | mTitleLabel->setMargin(2); |
55 | mTitleLabel->setAlignment(AlignCenter); | 55 | mTitleLabel->setAlignment(AlignCenter); |
56 | 56 | ||
57 | mEditor = new KTextEdit(this); | 57 | mEditor = new KTextEdit(this); |
58 | connect(mEditor,SIGNAL(textChanged()),SLOT(setDirty())); | 58 | connect(mEditor,SIGNAL(textChanged()),SLOT(setDirty())); |
59 | #ifndef DESKTOP_VERSION | 59 | #ifndef DESKTOP_VERSION |
60 | QPEApplication::setStylusOperation( mEditor, QPEApplication::RightOnHold ); | 60 | QPEApplication::setStylusOperation( mEditor, QPEApplication::RightOnHold ); |
61 | #endif | 61 | #endif |
62 | mEditor->setWordWrap( KTextEdit::WidgetWidth ); | 62 | mEditor->setWordWrap( KTextEdit::WidgetWidth ); |
63 | QBoxLayout *topLayout = new QVBoxLayout(this); | 63 | QBoxLayout *topLayout = new QVBoxLayout(this); |
64 | topLayout->addWidget(mTitleLabel); | 64 | topLayout->addWidget(mTitleLabel); |
65 | topLayout->addWidget(mEditor); | 65 | topLayout->addWidget(mEditor); |
66 | mEditor->installEventFilter(this); | 66 | mEditor->installEventFilter(this); |
67 | } | 67 | } |
68 | 68 | ||
69 | JournalEntry::~JournalEntry() | 69 | JournalEntry::~JournalEntry() |
70 | { | 70 | { |
71 | } | 71 | } |
72 | 72 | ||
73 | void JournalEntry::setDate(const QDate &date) | 73 | void JournalEntry::setDate(const QDate &date) |
74 | { | 74 | { |
diff --git a/korganizer/kdatenavigator.cpp b/korganizer/kdatenavigator.cpp index 12e983b..7d0c516 100644 --- a/korganizer/kdatenavigator.cpp +++ b/korganizer/kdatenavigator.cpp | |||
@@ -332,33 +332,33 @@ int KDateNavigator::dayToIndex(int dayNum) | |||
332 | row = (dayNum+m_fstDayOfWk-1-(KGlobal::locale()->weekStartsMonday() ? 1 : 0)) / 7; | 332 | row = (dayNum+m_fstDayOfWk-1-(KGlobal::locale()->weekStartsMonday() ? 1 : 0)) / 7; |
333 | if (KGlobal::locale()->weekStartsMonday() && (m_fstDayOfWk == 1)) | 333 | if (KGlobal::locale()->weekStartsMonday() && (m_fstDayOfWk == 1)) |
334 | row++; | 334 | row++; |
335 | col = (dayNum+m_fstDayOfWk-1-(KGlobal::locale()->weekStartsMonday() ? 1 : 0)) % 7; | 335 | col = (dayNum+m_fstDayOfWk-1-(KGlobal::locale()->weekStartsMonday() ? 1 : 0)) % 7; |
336 | return row * 7 + col; | 336 | return row * 7 + col; |
337 | } | 337 | } |
338 | 338 | ||
339 | void KDateNavigator::wheelEvent (QWheelEvent *e) | 339 | void KDateNavigator::wheelEvent (QWheelEvent *e) |
340 | { | 340 | { |
341 | if(e->delta()>0) emit goPrevious(); | 341 | if(e->delta()>0) emit goPrevious(); |
342 | else emit goNext(); | 342 | else emit goNext(); |
343 | 343 | ||
344 | e->accept(); | 344 | e->accept(); |
345 | } | 345 | } |
346 | 346 | ||
347 | bool KDateNavigator::eventFilter (QObject *o,QEvent *e) | 347 | bool KDateNavigator::eventFilter (QObject *o,QEvent *e) |
348 | { | 348 | { |
349 | if (e->type() == QEvent::MouseButtonPress) { | 349 | if (e->type() == QEvent::MouseButtonPress) { |
350 | int i; | 350 | int i; |
351 | for(i=0;i<6;++i) { | 351 | for(i=0;i<6;++i) { |
352 | if (o == weeknos[i]) { | 352 | if (o == weeknos[i]) { |
353 | QDate weekstart = daymatrix->getDate(i*7); | 353 | QDate weekstart = daymatrix->getDate(i*7); |
354 | emit weekClicked(weekstart); | 354 | emit weekClicked(weekstart); |
355 | break; | 355 | break; |
356 | } | 356 | } |
357 | } | 357 | } |
358 | return true; | 358 | return true; |
359 | } else { | 359 | } else { |
360 | return false; | 360 | return false; |
361 | } | 361 | } |
362 | } | 362 | } |
363 | 363 | ||
364 | #include "kdatenavigator.moc" | 364 | //#include "kdatenavigator.moc" |
diff --git a/korganizer/koagenda.cpp b/korganizer/koagenda.cpp index 607c250..6532705 100644 --- a/korganizer/koagenda.cpp +++ b/korganizer/koagenda.cpp | |||
@@ -17,65 +17,64 @@ | |||
17 | 17 | ||
18 | You should have received a copy of the GNU General Public License | 18 | You should have received a copy of the GNU General Public License |
19 | along with this program; if not, write to the Free Software | 19 | along with this program; if not, write to the Free Software |
20 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 20 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
21 | 21 | ||
22 | As a special exception, permission is given to link this program | 22 | As a special exception, permission is given to link this program |
23 | with any edition of Qt, and distribute the resulting executable, | 23 | with any edition of Qt, and distribute the resulting executable, |
24 | without including the source code for Qt in the source distribution. | 24 | without including the source code for Qt in the source distribution. |
25 | */ | 25 | */ |
26 | 26 | ||
27 | #ifndef _WIN32_ | 27 | #ifndef _WIN32_ |
28 | #define protected public | 28 | #define protected public |
29 | #include <qwidget.h> | 29 | #include <qwidget.h> |
30 | #undef protected | 30 | #undef protected |
31 | #endif | 31 | #endif |
32 | #include <qintdict.h> | 32 | #include <qintdict.h> |
33 | #include <qdatetime.h> | 33 | #include <qdatetime.h> |
34 | #include <qapplication.h> | 34 | #include <qapplication.h> |
35 | #include <qpopupmenu.h> | 35 | #include <qpopupmenu.h> |
36 | #include <qcursor.h> | 36 | #include <qcursor.h> |
37 | #include <qpainter.h> | 37 | #include <qpainter.h> |
38 | 38 | ||
39 | #include <kdebug.h> | 39 | #include <kdebug.h> |
40 | #include <klocale.h> | 40 | #include <klocale.h> |
41 | #include <kiconloader.h> | 41 | #include <kiconloader.h> |
42 | #include <kglobal.h> | 42 | #include <kglobal.h> |
43 | 43 | ||
44 | #include "koagendaitem.h" | 44 | #include "koagendaitem.h" |
45 | #include "koprefs.h" | 45 | #include "koprefs.h" |
46 | #include "koglobals.h" | 46 | #include "koglobals.h" |
47 | 47 | ||
48 | #include "koagenda.h" | 48 | #include "koagenda.h" |
49 | #include "koagenda.moc" | ||
50 | 49 | ||
51 | #include <libkcal/event.h> | 50 | #include <libkcal/event.h> |
52 | #include <libkcal/todo.h> | 51 | #include <libkcal/todo.h> |
53 | 52 | ||
54 | #ifndef DESKTOP_VERSION | 53 | #ifndef DESKTOP_VERSION |
55 | #include <qpe/qpeapplication.h> | 54 | #include <qpe/qpeapplication.h> |
56 | #endif | 55 | #endif |
57 | 56 | ||
58 | //extern bool globalFlagBlockPainting; | 57 | //extern bool globalFlagBlockPainting; |
59 | extern int globalFlagBlockAgenda; | 58 | extern int globalFlagBlockAgenda; |
60 | extern int globalFlagBlockAgendaItemPaint; | 59 | extern int globalFlagBlockAgendaItemPaint; |
61 | extern int globalFlagBlockAgendaItemUpdate; | 60 | extern int globalFlagBlockAgendaItemUpdate; |
62 | extern int globalFlagBlockStartup; | 61 | extern int globalFlagBlockStartup; |
63 | 62 | ||
64 | //////////////////////////////////////////////////////////////////////////// | 63 | //////////////////////////////////////////////////////////////////////////// |
65 | MarcusBains::MarcusBains(KOAgenda *_agenda,const char *name) | 64 | MarcusBains::MarcusBains(KOAgenda *_agenda,const char *name) |
66 | : QFrame(_agenda->viewport(),name), agenda(_agenda) | 65 | : QFrame(_agenda->viewport(),name), agenda(_agenda) |
67 | { | 66 | { |
68 | setLineWidth(0); | 67 | setLineWidth(0); |
69 | setMargin(0); | 68 | setMargin(0); |
70 | setBackgroundColor(Qt::red); | 69 | setBackgroundColor(Qt::red); |
71 | minutes = new QTimer(this); | 70 | minutes = new QTimer(this); |
72 | connect(minutes, SIGNAL(timeout()), this, SLOT(updateLoc())); | 71 | connect(minutes, SIGNAL(timeout()), this, SLOT(updateLoc())); |
73 | minutes->start(0, true); | 72 | minutes->start(0, true); |
74 | 73 | ||
75 | mTimeBox = new QLabel(this); | 74 | mTimeBox = new QLabel(this); |
76 | mTimeBox->setAlignment(Qt::AlignRight | Qt::AlignBottom); | 75 | mTimeBox->setAlignment(Qt::AlignRight | Qt::AlignBottom); |
77 | QPalette pal = mTimeBox->palette(); | 76 | QPalette pal = mTimeBox->palette(); |
78 | pal.setColor(QColorGroup::Foreground, Qt::red); | 77 | pal.setColor(QColorGroup::Foreground, Qt::red); |
79 | mTimeBox->setPalette(pal); | 78 | mTimeBox->setPalette(pal); |
80 | //mTimeBox->setAutoMask(true); | 79 | //mTimeBox->setAutoMask(true); |
81 | 80 | ||
diff --git a/korganizer/koagendaitem.cpp b/korganizer/koagendaitem.cpp index 02fd33b..a39feb1 100644 --- a/korganizer/koagendaitem.cpp +++ b/korganizer/koagendaitem.cpp | |||
@@ -18,65 +18,65 @@ | |||
18 | */ | 18 | */ |
19 | 19 | ||
20 | #include <qlabel.h> | 20 | #include <qlabel.h> |
21 | #include <qlayout.h> | 21 | #include <qlayout.h> |
22 | #include <qhbox.h> | 22 | #include <qhbox.h> |
23 | #include <qvbox.h> | 23 | #include <qvbox.h> |
24 | #include <qtooltip.h> | 24 | #include <qtooltip.h> |
25 | #include <qwhatsthis.h> | 25 | #include <qwhatsthis.h> |
26 | #include <qdragobject.h> | 26 | #include <qdragobject.h> |
27 | #include <qdrawutil.h> | 27 | #include <qdrawutil.h> |
28 | #include <qpainter.h> | 28 | #include <qpainter.h> |
29 | 29 | ||
30 | #include <kiconloader.h> | 30 | #include <kiconloader.h> |
31 | #include <kdebug.h> | 31 | #include <kdebug.h> |
32 | #include <kglobal.h> | 32 | #include <kglobal.h> |
33 | #include <klocale.h> | 33 | #include <klocale.h> |
34 | #ifndef DESKTOP_VERSION | 34 | #ifndef DESKTOP_VERSION |
35 | #include <qpe/qpeapplication.h> | 35 | #include <qpe/qpeapplication.h> |
36 | #define AGENDA_ICON_SIZE 5 | 36 | #define AGENDA_ICON_SIZE 5 |
37 | #else | 37 | #else |
38 | #define AGENDA_ICON_SIZE 7 | 38 | #define AGENDA_ICON_SIZE 7 |
39 | #endif | 39 | #endif |
40 | #include <libkcal/icaldrag.h> | 40 | #include <libkcal/icaldrag.h> |
41 | #include <libkcal/vcaldrag.h> | 41 | #include <libkcal/vcaldrag.h> |
42 | #include <libkdepim/kincidenceformatter.h> | 42 | #include <libkdepim/kincidenceformatter.h> |
43 | extern int globalFlagBlockAgenda; | 43 | extern int globalFlagBlockAgenda; |
44 | extern int globalFlagBlockAgendaItemPaint; | 44 | extern int globalFlagBlockAgendaItemPaint; |
45 | extern int globalFlagBlockAgendaItemUpdate; | 45 | extern int globalFlagBlockAgendaItemUpdate; |
46 | 46 | ||
47 | #include "koprefs.h" | 47 | #include "koprefs.h" |
48 | 48 | ||
49 | #include "koagendaitem.h" | 49 | #include "koagendaitem.h" |
50 | #include "koagendaitem.moc" | 50 | //#include "koagendaitem.moc" |
51 | 51 | ||
52 | 52 | ||
53 | //-------------------------------------------------------------------------- | 53 | //-------------------------------------------------------------------------- |
54 | 54 | ||
55 | QToolTipGroup *KOAgendaItem::mToolTipGroup = 0; | 55 | QToolTipGroup *KOAgendaItem::mToolTipGroup = 0; |
56 | 56 | ||
57 | //-------------------------------------------------------------------------- | 57 | //-------------------------------------------------------------------------- |
58 | 58 | ||
59 | KOAgendaItem::KOAgendaItem(Incidence *incidence, QDate qd, QWidget *parent,bool allday, | 59 | KOAgendaItem::KOAgendaItem(Incidence *incidence, QDate qd, QWidget *parent,bool allday, |
60 | const char *name,WFlags) : | 60 | const char *name,WFlags) : |
61 | QWidget(parent, name), mIncidence(incidence), mDate(qd) | 61 | QWidget(parent, name), mIncidence(incidence), mDate(qd) |
62 | { | 62 | { |
63 | #ifndef DESKTOP_VERSION | 63 | #ifndef DESKTOP_VERSION |
64 | QPEApplication::setStylusOperation( this, QPEApplication::RightOnHold ); | 64 | QPEApplication::setStylusOperation( this, QPEApplication::RightOnHold ); |
65 | #endif | 65 | #endif |
66 | int wflags = getWFlags() |WRepaintNoErase;// WResizeNoErase | 66 | int wflags = getWFlags() |WRepaintNoErase;// WResizeNoErase |
67 | setWFlags ( wflags); | 67 | setWFlags ( wflags); |
68 | mAllDay = allday; | 68 | mAllDay = allday; |
69 | init ( incidence, qd ); | 69 | init ( incidence, qd ); |
70 | setMouseTracking(true); | 70 | setMouseTracking(true); |
71 | //setAcceptDrops(true); | 71 | //setAcceptDrops(true); |
72 | xPaintCoord = -1; | 72 | xPaintCoord = -1; |
73 | yPaintCoord = -1; | 73 | yPaintCoord = -1; |
74 | } | 74 | } |
75 | 75 | ||
76 | void KOAgendaItem::init ( Incidence *incidence, QDate qd ) | 76 | void KOAgendaItem::init ( Incidence *incidence, QDate qd ) |
77 | { | 77 | { |
78 | mIncidence = incidence; | 78 | mIncidence = incidence; |
79 | mDate = qd; | 79 | mDate = qd; |
80 | mFirstMultiItem = 0; | 80 | mFirstMultiItem = 0; |
81 | mNextMultiItem = 0; | 81 | mNextMultiItem = 0; |
82 | mLastMultiItem = 0; | 82 | mLastMultiItem = 0; |
diff --git a/korganizer/koagendaview.cpp b/korganizer/koagendaview.cpp index 9e057e4..77a3164 100644 --- a/korganizer/koagendaview.cpp +++ b/korganizer/koagendaview.cpp | |||
@@ -37,65 +37,65 @@ | |||
37 | #include <qpushbutton.h> | 37 | #include <qpushbutton.h> |
38 | #include <qapplication.h> | 38 | #include <qapplication.h> |
39 | 39 | ||
40 | #include <kapplication.h> | 40 | #include <kapplication.h> |
41 | #include <KDGanttMinimizeSplitter.h> | 41 | #include <KDGanttMinimizeSplitter.h> |
42 | #include <kdebug.h> | 42 | #include <kdebug.h> |
43 | #include <kstandarddirs.h> | 43 | #include <kstandarddirs.h> |
44 | #include <kiconloader.h> | 44 | #include <kiconloader.h> |
45 | #include <klocale.h> | 45 | #include <klocale.h> |
46 | #include <kconfig.h> | 46 | #include <kconfig.h> |
47 | #include <kglobal.h> | 47 | #include <kglobal.h> |
48 | #include "calendarview.h" | 48 | #include "calendarview.h" |
49 | #include "koviewmanager.h" | 49 | #include "koviewmanager.h" |
50 | 50 | ||
51 | #include <libkcal/calendar.h> | 51 | #include <libkcal/calendar.h> |
52 | #include <libkcal/icaldrag.h> | 52 | #include <libkcal/icaldrag.h> |
53 | #include <libkcal/dndfactory.h> | 53 | #include <libkcal/dndfactory.h> |
54 | 54 | ||
55 | #include <kcalendarsystem.h> | 55 | #include <kcalendarsystem.h> |
56 | 56 | ||
57 | #include "koglobals.h" | 57 | #include "koglobals.h" |
58 | #ifndef KORG_NOPLUGINS | 58 | #ifndef KORG_NOPLUGINS |
59 | #include "kocore.h" | 59 | #include "kocore.h" |
60 | #endif | 60 | #endif |
61 | #include "koprefs.h" | 61 | #include "koprefs.h" |
62 | #include "koagenda.h" | 62 | #include "koagenda.h" |
63 | #include "koagendaitem.h" | 63 | #include "koagendaitem.h" |
64 | #ifndef KORG_NOPRINTER | 64 | #ifndef KORG_NOPRINTER |
65 | #include "calprinter.h" | 65 | #include "calprinter.h" |
66 | #endif | 66 | #endif |
67 | 67 | ||
68 | #include "koagendaview.h" | 68 | #include "koagendaview.h" |
69 | #include "koagendaview.moc" | 69 | //#include "koagendaview.moc" |
70 | 70 | ||
71 | //extern bool globalFlagBlockPainting; | 71 | //extern bool globalFlagBlockPainting; |
72 | extern int globalFlagBlockAgenda; | 72 | extern int globalFlagBlockAgenda; |
73 | extern int globalFlagBlockStartup; | 73 | extern int globalFlagBlockStartup; |
74 | extern int globalFlagBlockAgendaItemPaint; | 74 | extern int globalFlagBlockAgendaItemPaint; |
75 | extern int globalFlagBlockAgendaItemUpdate; | 75 | extern int globalFlagBlockAgendaItemUpdate; |
76 | extern int globalFlagBlockLabel; | 76 | extern int globalFlagBlockLabel; |
77 | using namespace KOrg; | 77 | using namespace KOrg; |
78 | 78 | ||
79 | TimeLabels::TimeLabels(int rows,QWidget *parent,const char *name,WFlags f) : | 79 | TimeLabels::TimeLabels(int rows,QWidget *parent,const char *name,WFlags f) : |
80 | QScrollView(parent,name,f) | 80 | QScrollView(parent,name,f) |
81 | { | 81 | { |
82 | mRows = rows; | 82 | mRows = rows; |
83 | 83 | ||
84 | setMinimumHeight( 20 ); | 84 | setMinimumHeight( 20 ); |
85 | mCellHeight = KOPrefs::instance()->mHourSize*4; | 85 | mCellHeight = KOPrefs::instance()->mHourSize*4; |
86 | 86 | ||
87 | enableClipper(true); | 87 | enableClipper(true); |
88 | 88 | ||
89 | setHScrollBarMode(AlwaysOff); | 89 | setHScrollBarMode(AlwaysOff); |
90 | setVScrollBarMode(AlwaysOff); | 90 | setVScrollBarMode(AlwaysOff); |
91 | 91 | ||
92 | resizeContents(50,mRows * mCellHeight); | 92 | resizeContents(50,mRows * mCellHeight); |
93 | 93 | ||
94 | viewport()->setBackgroundMode( PaletteBackground ); | 94 | viewport()->setBackgroundMode( PaletteBackground ); |
95 | } | 95 | } |
96 | 96 | ||
97 | void TimeLabels::setCellHeight(int height) | 97 | void TimeLabels::setCellHeight(int height) |
98 | { | 98 | { |
99 | mCellHeight = height; | 99 | mCellHeight = height; |
100 | } | 100 | } |
101 | 101 | ||
diff --git a/korganizer/kocounterdialog.cpp b/korganizer/kocounterdialog.cpp index 8a9ae44..82a7072 100644 --- a/korganizer/kocounterdialog.cpp +++ b/korganizer/kocounterdialog.cpp | |||
@@ -1,59 +1,59 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of KOrganizer. | 2 | This file is part of KOrganizer. |
3 | Copyright (c) 2000,2001 Cornelius Schumacher <schumacher@kde.org> | 3 | Copyright (c) 2000,2001 Cornelius Schumacher <schumacher@kde.org> |
4 | 4 | ||
5 | This program is free software; you can redistribute it and/or modify | 5 | This program is free software; you can redistribute it and/or modify |
6 | it under the terms of the GNU General Public License as published by | 6 | it under the terms of the GNU General Public License as published by |
7 | the Free Software Foundation; either version 2 of the License, or | 7 | the Free Software Foundation; either version 2 of the License, or |
8 | (at your option) any later version. | 8 | (at your option) any later version. |
9 | 9 | ||
10 | This program is distributed in the hope that it will be useful, | 10 | This program is distributed in the hope that it will be useful, |
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
13 | GNU General Public License for more details. | 13 | GNU General Public License for more details. |
14 | 14 | ||
15 | You should have received a copy of the GNU General Public License | 15 | You should have received a copy of the GNU General Public License |
16 | along with this program; if not, write to the Free Software | 16 | along with this program; if not, write to the Free Software |
17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
18 | */ | 18 | */ |
19 | 19 | ||
20 | 20 | ||
21 | #include <klocale.h> | 21 | #include <klocale.h> |
22 | 22 | ||
23 | #include <libkcal/event.h> | 23 | #include <libkcal/event.h> |
24 | #include "koeventviewer.h" | 24 | #include "koeventviewer.h" |
25 | 25 | ||
26 | #include "kocounterdialog.h" | 26 | #include "kocounterdialog.h" |
27 | #include "kocounterdialog.moc" | 27 | //#include "kocounterdialog.moc" |
28 | 28 | ||
29 | KOCounterDialog::KOCounterDialog(QWidget *parent,const char *name) | 29 | KOCounterDialog::KOCounterDialog(QWidget *parent,const char *name) |
30 | : KDialogBase(parent,name,false,i18n("Counter-event Viewer"),User1|User2,User1, | 30 | : KDialogBase(parent,name,false,i18n("Counter-event Viewer"),User1|User2,User1, |
31 | false,i18n("Decline"),i18n("Accept")) | 31 | false,i18n("Decline"),i18n("Accept")) |
32 | { | 32 | { |
33 | mEventViewer = new KOEventViewer(this); | 33 | mEventViewer = new KOEventViewer(this); |
34 | setMainWidget(mEventViewer); | 34 | setMainWidget(mEventViewer); |
35 | 35 | ||
36 | connect(this,SIGNAL(user1Clicked()),this,SLOT(slotCancel())); | 36 | connect(this,SIGNAL(user1Clicked()),this,SLOT(slotCancel())); |
37 | connect(this,SIGNAL(user2Clicked()),this,SLOT(slotOk())); | 37 | connect(this,SIGNAL(user2Clicked()),this,SLOT(slotOk())); |
38 | 38 | ||
39 | // TODO: Set a sensible size (based on the content?). | 39 | // TODO: Set a sensible size (based on the content?). |
40 | setMinimumSize(300,200); | 40 | setMinimumSize(300,200); |
41 | resize(320,300); | 41 | resize(320,300); |
42 | } | 42 | } |
43 | 43 | ||
44 | KOCounterDialog::~KOCounterDialog() | 44 | KOCounterDialog::~KOCounterDialog() |
45 | { | 45 | { |
46 | } | 46 | } |
47 | 47 | ||
48 | void KOCounterDialog::setEvent(Event *event) | 48 | void KOCounterDialog::setEvent(Event *event) |
49 | { | 49 | { |
50 | mEventViewer->setEvent(event); | 50 | mEventViewer->setEvent(event); |
51 | } | 51 | } |
52 | 52 | ||
53 | void KOCounterDialog::addEvent(Event *event) | 53 | void KOCounterDialog::addEvent(Event *event) |
54 | { | 54 | { |
55 | mEventViewer->addEvent(event); | 55 | mEventViewer->addEvent(event); |
56 | } | 56 | } |
57 | 57 | ||
58 | void KOCounterDialog::setTodo(Todo *event) | 58 | void KOCounterDialog::setTodo(Todo *event) |
59 | { | 59 | { |
diff --git a/korganizer/kodaymatrix.cpp b/korganizer/kodaymatrix.cpp index 779d67c..fc00828 100644 --- a/korganizer/kodaymatrix.cpp +++ b/korganizer/kodaymatrix.cpp | |||
@@ -17,65 +17,64 @@ | |||
17 | along with this program; if not, write to the Free Software | 17 | along with this program; if not, write to the Free Software |
18 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 18 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
19 | 19 | ||
20 | As a special exception, permission is given to link this program | 20 | As a special exception, permission is given to link this program |
21 | with any edition of Qt, and distribute the resulting executable, | 21 | with any edition of Qt, and distribute the resulting executable, |
22 | without including the source code for Qt in the source distribution. | 22 | without including the source code for Qt in the source distribution. |
23 | */ | 23 | */ |
24 | 24 | ||
25 | #include <qevent.h> | 25 | #include <qevent.h> |
26 | #include <qpainter.h> | 26 | #include <qpainter.h> |
27 | #include <qptrlist.h> | 27 | #include <qptrlist.h> |
28 | 28 | ||
29 | #include <kglobal.h> | 29 | #include <kglobal.h> |
30 | #include <kdebug.h> | 30 | #include <kdebug.h> |
31 | #include <klocale.h> | 31 | #include <klocale.h> |
32 | 32 | ||
33 | #include <libkcal/vcaldrag.h> | 33 | #include <libkcal/vcaldrag.h> |
34 | #include <libkcal/icaldrag.h> | 34 | #include <libkcal/icaldrag.h> |
35 | #include <libkcal/dndfactory.h> | 35 | #include <libkcal/dndfactory.h> |
36 | #include <libkcal/calendarresources.h> | 36 | #include <libkcal/calendarresources.h> |
37 | #include <libkcal/resourcecalendar.h> | 37 | #include <libkcal/resourcecalendar.h> |
38 | #include <kresources/resourceselectdialog.h> | 38 | #include <kresources/resourceselectdialog.h> |
39 | 39 | ||
40 | #include <kcalendarsystem.h> | 40 | #include <kcalendarsystem.h> |
41 | 41 | ||
42 | #ifndef KORG_NOPLUGINS | 42 | #ifndef KORG_NOPLUGINS |
43 | #include "kocore.h" | 43 | #include "kocore.h" |
44 | #endif | 44 | #endif |
45 | #include "koprefs.h" | 45 | #include "koprefs.h" |
46 | #include "koglobals.h" | 46 | #include "koglobals.h" |
47 | 47 | ||
48 | #include "kodaymatrix.h" | 48 | #include "kodaymatrix.h" |
49 | #include "kodaymatrix.moc" | ||
50 | 49 | ||
51 | // ============================================================================ | 50 | // ============================================================================ |
52 | // D Y N A M I C T I P | 51 | // D Y N A M I C T I P |
53 | // ============================================================================ | 52 | // ============================================================================ |
54 | 53 | ||
55 | DynamicTip::DynamicTip( QWidget * parent ) | 54 | DynamicTip::DynamicTip( QWidget * parent ) |
56 | : QToolTip( parent ) | 55 | : QToolTip( parent ) |
57 | { | 56 | { |
58 | matrix = (KODayMatrix*)parent; | 57 | matrix = (KODayMatrix*)parent; |
59 | } | 58 | } |
60 | 59 | ||
61 | 60 | ||
62 | void DynamicTip::maybeTip( const QPoint &pos ) | 61 | void DynamicTip::maybeTip( const QPoint &pos ) |
63 | { | 62 | { |
64 | //calculate which cell of the matrix the mouse is in | 63 | //calculate which cell of the matrix the mouse is in |
65 | QRect sz = matrix->frameRect(); | 64 | QRect sz = matrix->frameRect(); |
66 | int dheight = sz.height()*7 / 42; | 65 | int dheight = sz.height()*7 / 42; |
67 | int dwidth = sz.width() / 7; | 66 | int dwidth = sz.width() / 7; |
68 | int row = pos.y()/dheight; | 67 | int row = pos.y()/dheight; |
69 | int col = pos.x()/dwidth; | 68 | int col = pos.x()/dwidth; |
70 | 69 | ||
71 | QRect rct(col*dwidth, row*dheight, dwidth, dheight); | 70 | QRect rct(col*dwidth, row*dheight, dwidth, dheight); |
72 | 71 | ||
73 | // kdDebug() << "DynamicTip::maybeTip matrix cell index [" << | 72 | // kdDebug() << "DynamicTip::maybeTip matrix cell index [" << |
74 | // col << "][" << row << "] => " <<(col+row*7) << endl; | 73 | // col << "][" << row << "] => " <<(col+row*7) << endl; |
75 | 74 | ||
76 | //show holiday names only | 75 | //show holiday names only |
77 | QString str = matrix->getHolidayLabel(col+row*7); | 76 | QString str = matrix->getHolidayLabel(col+row*7); |
78 | if (str.isEmpty()) return; | 77 | if (str.isEmpty()) return; |
79 | tip(rct, str); | 78 | tip(rct, str); |
80 | } | 79 | } |
81 | 80 | ||
diff --git a/korganizer/kodialogmanager.cpp b/korganizer/kodialogmanager.cpp index caf7599..58198a2 100644 --- a/korganizer/kodialogmanager.cpp +++ b/korganizer/kodialogmanager.cpp | |||
@@ -11,65 +11,64 @@ | |||
11 | 11 | ||
12 | This program is distributed in the hope that it will be useful, | 12 | This program is distributed in the hope that it will be useful, |
13 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 13 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
14 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.See the | 14 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.See the |
15 | GNU General Public License for more details. | 15 | GNU General Public License for more details. |
16 | 16 | ||
17 | You should have received a copy of the GNU General Public License | 17 | You should have received a copy of the GNU General Public License |
18 | along with this program; if not, write to the Free Software | 18 | along with this program; if not, write to the Free Software |
19 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 19 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
20 | */ | 20 | */ |
21 | 21 | ||
22 | #include <libkdepim/categoryeditdialog.h> | 22 | #include <libkdepim/categoryeditdialog.h> |
23 | 23 | ||
24 | #include "calendarview.h" | 24 | #include "calendarview.h" |
25 | #include "incomingdialog.h" | 25 | #include "incomingdialog.h" |
26 | #include "outgoingdialog.h" | 26 | #include "outgoingdialog.h" |
27 | #include "koprefsdialog.h" | 27 | #include "koprefsdialog.h" |
28 | #include "koeventeditor.h" | 28 | #include "koeventeditor.h" |
29 | #include "koprefs.h" | 29 | #include "koprefs.h" |
30 | #include "datenavigator.h" | 30 | #include "datenavigator.h" |
31 | #include "kotodoeditor.h" | 31 | #include "kotodoeditor.h" |
32 | #include "searchdialog.h" | 32 | #include "searchdialog.h" |
33 | #include "filtereditdialog.h" | 33 | #include "filtereditdialog.h" |
34 | #ifndef KORG_NOPLUGINS | 34 | #ifndef KORG_NOPLUGINS |
35 | #include "plugindialog.h" | 35 | #include "plugindialog.h" |
36 | #endif | 36 | #endif |
37 | #ifndef KORG_NOARCHIVE | 37 | #ifndef KORG_NOARCHIVE |
38 | #include "archivedialog.h" | 38 | #include "archivedialog.h" |
39 | #endif | 39 | #endif |
40 | 40 | ||
41 | #include "kconfig.h" | 41 | #include "kconfig.h" |
42 | #include "kodialogmanager.h" | 42 | #include "kodialogmanager.h" |
43 | #include "kodialogmanager.moc" | ||
44 | 43 | ||
45 | KODialogManager::KODialogManager( CalendarView *mainView ) : | 44 | KODialogManager::KODialogManager( CalendarView *mainView ) : |
46 | QObject(), mMainView( mainView ) | 45 | QObject(), mMainView( mainView ) |
47 | { | 46 | { |
48 | mOutgoingDialog = 0; | 47 | mOutgoingDialog = 0; |
49 | mIncomingDialog = 0; | 48 | mIncomingDialog = 0; |
50 | mOptionsDialog = 0; | 49 | mOptionsDialog = 0; |
51 | mSearchDialog = 0; | 50 | mSearchDialog = 0; |
52 | mArchiveDialog = 0; | 51 | mArchiveDialog = 0; |
53 | mFilterEditDialog = 0; | 52 | mFilterEditDialog = 0; |
54 | mPluginDialog = 0; | 53 | mPluginDialog = 0; |
55 | 54 | ||
56 | // mCategoryEditDialog = new KPIM::CategoryEditDialog(KOPrefs::instance(),mMainView); | 55 | // mCategoryEditDialog = new KPIM::CategoryEditDialog(KOPrefs::instance(),mMainView); |
57 | //KOGlobals::fitDialogToScreen( mCategoryEditDialog ); | 56 | //KOGlobals::fitDialogToScreen( mCategoryEditDialog ); |
58 | } | 57 | } |
59 | 58 | ||
60 | KODialogManager::~KODialogManager() | 59 | KODialogManager::~KODialogManager() |
61 | { | 60 | { |
62 | delete mOutgoingDialog; | 61 | delete mOutgoingDialog; |
63 | delete mIncomingDialog; | 62 | delete mIncomingDialog; |
64 | delete mOptionsDialog; | 63 | delete mOptionsDialog; |
65 | delete mSearchDialog; | 64 | delete mSearchDialog; |
66 | #ifndef KORG_NOARCHIVE | 65 | #ifndef KORG_NOARCHIVE |
67 | delete mArchiveDialog; | 66 | delete mArchiveDialog; |
68 | #endif | 67 | #endif |
69 | delete mFilterEditDialog; | 68 | delete mFilterEditDialog; |
70 | #ifndef KORG_NOPLUGINS | 69 | #ifndef KORG_NOPLUGINS |
71 | delete mPluginDialog; | 70 | delete mPluginDialog; |
72 | #endif | 71 | #endif |
73 | } | 72 | } |
74 | 73 | ||
75 | OutgoingDialog *KODialogManager::outgoingDialog() | 74 | OutgoingDialog *KODialogManager::outgoingDialog() |
diff --git a/korganizer/koeditordetails.cpp b/korganizer/koeditordetails.cpp index 7c4c382..c0e7bdd 100644 --- a/korganizer/koeditordetails.cpp +++ b/korganizer/koeditordetails.cpp | |||
@@ -16,65 +16,64 @@ | |||
16 | along with this program; if not, write to the Free Software | 16 | along with this program; if not, write to the Free Software |
17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
18 | 18 | ||
19 | As a special exception, permission is given to link this program | 19 | As a special exception, permission is given to link this program |
20 | with any edition of Qt, and distribute the resulting executable, | 20 | with any edition of Qt, and distribute the resulting executable, |
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 <qfiledialog.h> |
26 | #include <qlayout.h> | 26 | #include <qlayout.h> |
27 | #include <qvbox.h> | 27 | #include <qvbox.h> |
28 | #include <qbuttongroup.h> | 28 | #include <qbuttongroup.h> |
29 | #include <qvgroupbox.h> | 29 | #include <qvgroupbox.h> |
30 | #include <qwidgetstack.h> | 30 | #include <qwidgetstack.h> |
31 | #include <qdatetime.h> | 31 | #include <qdatetime.h> |
32 | #include <qapp.h> | 32 | #include <qapp.h> |
33 | 33 | ||
34 | #include <klocale.h> | 34 | #include <klocale.h> |
35 | #include <kglobal.h> | 35 | #include <kglobal.h> |
36 | #include <kiconloader.h> | 36 | #include <kiconloader.h> |
37 | #include <kstandarddirs.h> | 37 | #include <kstandarddirs.h> |
38 | #include <kmessagebox.h> | 38 | #include <kmessagebox.h> |
39 | #ifndef KORG_NOKABC | 39 | #ifndef KORG_NOKABC |
40 | #include <kabc/addresseedialog.h> | 40 | #include <kabc/addresseedialog.h> |
41 | #endif | 41 | #endif |
42 | 42 | ||
43 | #include <libkcal/incidence.h> | 43 | #include <libkcal/incidence.h> |
44 | 44 | ||
45 | #include "koprefs.h" | 45 | #include "koprefs.h" |
46 | 46 | ||
47 | #include "koeditordetails.h" | 47 | #include "koeditordetails.h" |
48 | #include "koeditordetails.moc" | ||
49 | 48 | ||
50 | template <> | 49 | template <> |
51 | CustomListViewItem<class Attendee *>::~CustomListViewItem() | 50 | CustomListViewItem<class Attendee *>::~CustomListViewItem() |
52 | { | 51 | { |
53 | delete mData; | 52 | delete mData; |
54 | } | 53 | } |
55 | 54 | ||
56 | template <> | 55 | template <> |
57 | void CustomListViewItem<class Attendee *>::updateItem() | 56 | void CustomListViewItem<class Attendee *>::updateItem() |
58 | { | 57 | { |
59 | setText(0,mData->name()); | 58 | setText(0,mData->name()); |
60 | setText(1,mData->email()); | 59 | setText(1,mData->email()); |
61 | setText(2,mData->roleStr()); | 60 | setText(2,mData->roleStr()); |
62 | setText(3,mData->statusStr()); | 61 | setText(3,mData->statusStr()); |
63 | if (mData->RSVP() && !mData->email().isEmpty()) | 62 | if (mData->RSVP() && !mData->email().isEmpty()) |
64 | setPixmap(4,SmallIcon("mailappt")); | 63 | setPixmap(4,SmallIcon("mailappt")); |
65 | else | 64 | else |
66 | setPixmap(4,SmallIcon("nomailappt")); | 65 | setPixmap(4,SmallIcon("nomailappt")); |
67 | } | 66 | } |
68 | 67 | ||
69 | 68 | ||
70 | KOEditorDetails::KOEditorDetails (int spacing,QWidget* parent,const char* name) | 69 | KOEditorDetails::KOEditorDetails (int spacing,QWidget* parent,const char* name) |
71 | : QWidget( parent, name), mDisableItemUpdate( false ) | 70 | : QWidget( parent, name), mDisableItemUpdate( false ) |
72 | { | 71 | { |
73 | QGridLayout *topLayout = new QGridLayout(this); | 72 | QGridLayout *topLayout = new QGridLayout(this); |
74 | topLayout->setSpacing(spacing); | 73 | topLayout->setSpacing(spacing); |
75 | 74 | ||
76 | QString organizer = KOPrefs::instance()->email(); | 75 | QString organizer = KOPrefs::instance()->email(); |
77 | mOrganizerLabel = new QLabel(i18n("Organizer: %1").arg(organizer),this); | 76 | mOrganizerLabel = new QLabel(i18n("Organizer: %1").arg(organizer),this); |
78 | 77 | ||
79 | mListView = new KListView(this,"mListView"); | 78 | mListView = new KListView(this,"mListView"); |
80 | mListView->addColumn(i18n("Name"),180); | 79 | mListView->addColumn(i18n("Name"),180); |
diff --git a/korganizer/koeditorgeneral.cpp b/korganizer/koeditorgeneral.cpp index ad1389f..94e1f4c 100644 --- a/korganizer/koeditorgeneral.cpp +++ b/korganizer/koeditorgeneral.cpp | |||
@@ -21,65 +21,64 @@ | |||
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 <qwidget.h> | 24 | #include <qwidget.h> |
25 | #include <qtooltip.h> | 25 | #include <qtooltip.h> |
26 | #include <qlayout.h> | 26 | #include <qlayout.h> |
27 | #include <qvbox.h> | 27 | #include <qvbox.h> |
28 | #include <qbuttongroup.h> | 28 | #include <qbuttongroup.h> |
29 | #include <qvgroupbox.h> | 29 | #include <qvgroupbox.h> |
30 | #include <qwidgetstack.h> | 30 | #include <qwidgetstack.h> |
31 | #include <qdatetime.h> | 31 | #include <qdatetime.h> |
32 | #include <qfile.h> | 32 | #include <qfile.h> |
33 | 33 | ||
34 | 34 | ||
35 | #include <kglobal.h> | 35 | #include <kglobal.h> |
36 | #include <kdebug.h> | 36 | #include <kdebug.h> |
37 | #include <klocale.h> | 37 | #include <klocale.h> |
38 | #include <kiconloader.h> | 38 | #include <kiconloader.h> |
39 | #include <kmessagebox.h> | 39 | #include <kmessagebox.h> |
40 | #include <kfiledialog.h> | 40 | #include <kfiledialog.h> |
41 | #include <kstandarddirs.h> | 41 | #include <kstandarddirs.h> |
42 | 42 | ||
43 | #include <libkcal/todo.h> | 43 | #include <libkcal/todo.h> |
44 | #include <libkcal/event.h> | 44 | #include <libkcal/event.h> |
45 | #include <libkdepim/categoryselectdialog.h> | 45 | #include <libkdepim/categoryselectdialog.h> |
46 | #include <libkdepim/kdateedit.h> | 46 | #include <libkdepim/kdateedit.h> |
47 | 47 | ||
48 | #include "koprefs.h" | 48 | #include "koprefs.h" |
49 | #include "koglobals.h" | 49 | #include "koglobals.h" |
50 | 50 | ||
51 | #include "koeditorgeneral.h" | 51 | #include "koeditorgeneral.h" |
52 | #include "kolocationbox.h" | 52 | #include "kolocationbox.h" |
53 | #include "koeditorgeneral.moc" | ||
54 | #ifndef DESKTOP_VERSION | 53 | #ifndef DESKTOP_VERSION |
55 | #include <qpe/qpeapplication.h> | 54 | #include <qpe/qpeapplication.h> |
56 | #else | 55 | #else |
57 | #include <qapplication.h> | 56 | #include <qapplication.h> |
58 | #endif | 57 | #endif |
59 | 58 | ||
60 | KOEditorGeneral::KOEditorGeneral(QObject* parent, const char* name) : | 59 | KOEditorGeneral::KOEditorGeneral(QObject* parent, const char* name) : |
61 | QObject( parent, name) | 60 | QObject( parent, name) |
62 | { | 61 | { |
63 | } | 62 | } |
64 | 63 | ||
65 | KOEditorGeneral::~KOEditorGeneral() | 64 | KOEditorGeneral::~KOEditorGeneral() |
66 | { | 65 | { |
67 | } | 66 | } |
68 | 67 | ||
69 | void KOEditorGeneral::initHeader(QWidget *parent,QBoxLayout *topLayout) | 68 | void KOEditorGeneral::initHeader(QWidget *parent,QBoxLayout *topLayout) |
70 | { | 69 | { |
71 | QGridLayout *headerLayout = new QGridLayout(topLayout); | 70 | QGridLayout *headerLayout = new QGridLayout(topLayout); |
72 | 71 | ||
73 | #if 0 | 72 | #if 0 |
74 | mOwnerLabel = new QLabel(i18n("Owner:"),parent); | 73 | mOwnerLabel = new QLabel(i18n("Owner:"),parent); |
75 | headerLayout->addMultiCellWidget(mOwnerLabel,0,0,0,1); | 74 | headerLayout->addMultiCellWidget(mOwnerLabel,0,0,0,1); |
76 | #endif | 75 | #endif |
77 | 76 | ||
78 | QLabel *summaryLabel = new QLabel(i18n("Summary:"),parent); | 77 | QLabel *summaryLabel = new QLabel(i18n("Summary:"),parent); |
79 | headerLayout->addWidget(summaryLabel,1,0); | 78 | headerLayout->addWidget(summaryLabel,1,0); |
80 | 79 | ||
81 | mSummaryEdit = new KOLocationBox(TRUE,parent, 10); | 80 | mSummaryEdit = new KOLocationBox(TRUE,parent, 10); |
82 | mSummaryEdit->setSizePolicy( QSizePolicy( QSizePolicy::Preferred ,QSizePolicy::MinimumExpanding ,FALSE) ); | 81 | mSummaryEdit->setSizePolicy( QSizePolicy( QSizePolicy::Preferred ,QSizePolicy::MinimumExpanding ,FALSE) ); |
83 | //mSummaryEdit->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)5 ,(QSizePolicy::SizeType)3 ,FALSE) ); | 82 | //mSummaryEdit->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)5 ,(QSizePolicy::SizeType)3 ,FALSE) ); |
84 | //qDebug("h %d %d ", summaryLabel->sizeHint().height(),mSummaryEdit->sizeHint().height() ); | 83 | //qDebug("h %d %d ", summaryLabel->sizeHint().height(),mSummaryEdit->sizeHint().height() ); |
85 | int hei = (summaryLabel->sizeHint().height() + mSummaryEdit->sizeHint().height())/2; | 84 | int hei = (summaryLabel->sizeHint().height() + mSummaryEdit->sizeHint().height())/2; |
diff --git a/korganizer/koeditorgeneralevent.cpp b/korganizer/koeditorgeneralevent.cpp index 9b93e7e..42c3df1 100644 --- a/korganizer/koeditorgeneralevent.cpp +++ b/korganizer/koeditorgeneralevent.cpp | |||
@@ -16,65 +16,64 @@ | |||
16 | along with this program; if not, write to the Free Software | 16 | along with this program; if not, write to the Free Software |
17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
18 | 18 | ||
19 | As a special exception, permission is given to link this program | 19 | As a special exception, permission is given to link this program |
20 | with any edition of Qt, and distribute the resulting executable, | 20 | with any edition of Qt, and distribute the resulting executable, |
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 <qlayout.h> | 25 | #include <qlayout.h> |
26 | #include <qvbox.h> | 26 | #include <qvbox.h> |
27 | #include <qbuttongroup.h> | 27 | #include <qbuttongroup.h> |
28 | #include <qvgroupbox.h> | 28 | #include <qvgroupbox.h> |
29 | #include <qwidgetstack.h> | 29 | #include <qwidgetstack.h> |
30 | #include <qdatetime.h> | 30 | #include <qdatetime.h> |
31 | 31 | ||
32 | #include <kdebug.h> | 32 | #include <kdebug.h> |
33 | #include <kglobal.h> | 33 | #include <kglobal.h> |
34 | #include <klocale.h> | 34 | #include <klocale.h> |
35 | #include <kiconloader.h> | 35 | #include <kiconloader.h> |
36 | #include <kmessagebox.h> | 36 | #include <kmessagebox.h> |
37 | #include <kfiledialog.h> | 37 | #include <kfiledialog.h> |
38 | #include <kstandarddirs.h> | 38 | #include <kstandarddirs.h> |
39 | 39 | ||
40 | #include <libkcal/event.h> | 40 | #include <libkcal/event.h> |
41 | 41 | ||
42 | #include <libkdepim/kdateedit.h> | 42 | #include <libkdepim/kdateedit.h> |
43 | 43 | ||
44 | #include "koprefs.h" | 44 | #include "koprefs.h" |
45 | 45 | ||
46 | #include "koeditorgeneralevent.h" | 46 | #include "koeditorgeneralevent.h" |
47 | #include "kolocationbox.h" | 47 | #include "kolocationbox.h" |
48 | #include "koeditorgeneralevent.moc" | ||
49 | 48 | ||
50 | KOEditorGeneralEvent::KOEditorGeneralEvent(QObject* parent, | 49 | KOEditorGeneralEvent::KOEditorGeneralEvent(QObject* parent, |
51 | const char* name) : | 50 | const char* name) : |
52 | KOEditorGeneral( parent, name) | 51 | KOEditorGeneral( parent, name) |
53 | { | 52 | { |
54 | connect(this,SIGNAL(dateTimesChanged(QDateTime,QDateTime)), | 53 | connect(this,SIGNAL(dateTimesChanged(QDateTime,QDateTime)), |
55 | SLOT(setDuration())); | 54 | SLOT(setDuration())); |
56 | connect(this,SIGNAL(dateTimesChanged(QDateTime,QDateTime)), | 55 | connect(this,SIGNAL(dateTimesChanged(QDateTime,QDateTime)), |
57 | SLOT(emitDateTimeStr())); | 56 | SLOT(emitDateTimeStr())); |
58 | } | 57 | } |
59 | 58 | ||
60 | KOEditorGeneralEvent::~KOEditorGeneralEvent() | 59 | KOEditorGeneralEvent::~KOEditorGeneralEvent() |
61 | { | 60 | { |
62 | } | 61 | } |
63 | 62 | ||
64 | void KOEditorGeneralEvent::finishSetup() | 63 | void KOEditorGeneralEvent::finishSetup() |
65 | { | 64 | { |
66 | 65 | ||
67 | //disabled | 66 | //disabled |
68 | // QWidget::setTabOrder( mSummaryEdit, mLocationEdit ); | 67 | // QWidget::setTabOrder( mSummaryEdit, mLocationEdit ); |
69 | // QWidget::setTabOrder( mLocationEdit, mStartDateEdit ); | 68 | // QWidget::setTabOrder( mLocationEdit, mStartDateEdit ); |
70 | // QWidget::setTabOrder( mStartDateEdit, mStartTimeEdit ); | 69 | // QWidget::setTabOrder( mStartDateEdit, mStartTimeEdit ); |
71 | // QWidget::setTabOrder( mStartTimeEdit, mEndDateEdit ); | 70 | // QWidget::setTabOrder( mStartTimeEdit, mEndDateEdit ); |
72 | // QWidget::setTabOrder( mEndDateEdit, mEndTimeEdit ); | 71 | // QWidget::setTabOrder( mEndDateEdit, mEndTimeEdit ); |
73 | // QWidget::setTabOrder( mEndTimeEdit, mNoTimeButton ); | 72 | // QWidget::setTabOrder( mEndTimeEdit, mNoTimeButton ); |
74 | // QWidget::setTabOrder( mNoTimeButton, mAlarmButton ); | 73 | // QWidget::setTabOrder( mNoTimeButton, mAlarmButton ); |
75 | // QWidget::setTabOrder( mAlarmButton, mAlarmTimeEdit ); | 74 | // QWidget::setTabOrder( mAlarmButton, mAlarmTimeEdit ); |
76 | // QWidget::setTabOrder( mFreeTimeCombo, mCategoriesButton ); | 75 | // QWidget::setTabOrder( mFreeTimeCombo, mCategoriesButton ); |
77 | // QWidget::setTabOrder( mCategoriesButton, mSecrecyCombo ); | 76 | // QWidget::setTabOrder( mCategoriesButton, mSecrecyCombo ); |
78 | // QWidget::setTabOrder( mSecrecyCombo, mDescriptionEdit ); | 77 | // QWidget::setTabOrder( mSecrecyCombo, mDescriptionEdit ); |
79 | 78 | ||
80 | 79 | ||
diff --git a/korganizer/koeditorgeneraltodo.cpp b/korganizer/koeditorgeneraltodo.cpp index 57837bb..7db7da0 100644 --- a/korganizer/koeditorgeneraltodo.cpp +++ b/korganizer/koeditorgeneraltodo.cpp | |||
@@ -19,65 +19,64 @@ | |||
19 | As a special exception, permission is given to link this program | 19 | As a special exception, permission is given to link this program |
20 | with any edition of Qt, and distribute the resulting executable, | 20 | with any edition of Qt, and distribute the resulting executable, |
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 <qfiledialog.h> |
26 | #include <qlayout.h> | 26 | #include <qlayout.h> |
27 | #include <qvbox.h> | 27 | #include <qvbox.h> |
28 | #include <qbuttongroup.h> | 28 | #include <qbuttongroup.h> |
29 | #include <qvgroupbox.h> | 29 | #include <qvgroupbox.h> |
30 | #include <qwidgetstack.h> | 30 | #include <qwidgetstack.h> |
31 | #include <qdatetime.h> | 31 | #include <qdatetime.h> |
32 | 32 | ||
33 | #include <kglobal.h> | 33 | #include <kglobal.h> |
34 | #include <klocale.h> | 34 | #include <klocale.h> |
35 | #include <kiconloader.h> | 35 | #include <kiconloader.h> |
36 | #include <kmessagebox.h> | 36 | #include <kmessagebox.h> |
37 | #include <kdebug.h> | 37 | #include <kdebug.h> |
38 | #include <krestrictedline.h> | 38 | #include <krestrictedline.h> |
39 | #include <kstandarddirs.h> | 39 | #include <kstandarddirs.h> |
40 | #include <kfiledialog.h> | 40 | #include <kfiledialog.h> |
41 | 41 | ||
42 | #include <libkcal/todo.h> | 42 | #include <libkcal/todo.h> |
43 | 43 | ||
44 | #include <libkdepim/kdateedit.h> | 44 | #include <libkdepim/kdateedit.h> |
45 | 45 | ||
46 | #include "koprefs.h" | 46 | #include "koprefs.h" |
47 | #include "ktimeedit.h" | 47 | #include "ktimeedit.h" |
48 | 48 | ||
49 | #include "koeditorgeneraltodo.h" | 49 | #include "koeditorgeneraltodo.h" |
50 | #include "kolocationbox.h" | 50 | #include "kolocationbox.h" |
51 | #include "koeditorgeneraltodo.moc" | ||
52 | 51 | ||
53 | KOEditorGeneralTodo::KOEditorGeneralTodo(QObject* parent, | 52 | KOEditorGeneralTodo::KOEditorGeneralTodo(QObject* parent, |
54 | const char* name) | 53 | const char* name) |
55 | : KOEditorGeneral( parent, name) | 54 | : KOEditorGeneral( parent, name) |
56 | { | 55 | { |
57 | } | 56 | } |
58 | 57 | ||
59 | KOEditorGeneralTodo::~KOEditorGeneralTodo() | 58 | KOEditorGeneralTodo::~KOEditorGeneralTodo() |
60 | { | 59 | { |
61 | } | 60 | } |
62 | 61 | ||
63 | void KOEditorGeneralTodo::finishSetup() | 62 | void KOEditorGeneralTodo::finishSetup() |
64 | { | 63 | { |
65 | 64 | ||
66 | // QWidget::setTabOrder(mSummaryEdit, mLocationEdit); | 65 | // QWidget::setTabOrder(mSummaryEdit, mLocationEdit); |
67 | // QWidget::setTabOrder(mLocationEdit, mDueCheck); | 66 | // QWidget::setTabOrder(mLocationEdit, mDueCheck); |
68 | // QWidget::setTabOrder(mDueCheck, mDueDateEdit); | 67 | // QWidget::setTabOrder(mDueCheck, mDueDateEdit); |
69 | // QWidget::setTabOrder(mDueDateEdit, mDueTimeEdit); | 68 | // QWidget::setTabOrder(mDueDateEdit, mDueTimeEdit); |
70 | // QWidget::setTabOrder(mDueTimeEdit, mStartCheck); | 69 | // QWidget::setTabOrder(mDueTimeEdit, mStartCheck); |
71 | // QWidget::setTabOrder(mStartCheck, mStartDateEdit); | 70 | // QWidget::setTabOrder(mStartCheck, mStartDateEdit); |
72 | // QWidget::setTabOrder(mStartDateEdit, mStartTimeEdit); | 71 | // QWidget::setTabOrder(mStartDateEdit, mStartTimeEdit); |
73 | // QWidget::setTabOrder(mStartTimeEdit, mTimeButton); | 72 | // QWidget::setTabOrder(mStartTimeEdit, mTimeButton); |
74 | // QWidget::setTabOrder(mTimeButton, mCompletedCombo); | 73 | // QWidget::setTabOrder(mTimeButton, mCompletedCombo); |
75 | // QWidget::setTabOrder(mCompletedCombo, mPriorityCombo); | 74 | // QWidget::setTabOrder(mCompletedCombo, mPriorityCombo); |
76 | // QWidget::setTabOrder(mPriorityCombo, mAlarmButton); | 75 | // QWidget::setTabOrder(mPriorityCombo, mAlarmButton); |
77 | // QWidget::setTabOrder(mAlarmButton, mCategoriesButton); | 76 | // QWidget::setTabOrder(mAlarmButton, mCategoriesButton); |
78 | // QWidget::setTabOrder(mCategoriesButton, mSecrecyCombo); | 77 | // QWidget::setTabOrder(mCategoriesButton, mSecrecyCombo); |
79 | // QWidget::setTabOrder(mSecrecyCombo, mDescriptionEdit); | 78 | // QWidget::setTabOrder(mSecrecyCombo, mDescriptionEdit); |
80 | mSummaryEdit->load(KOLocationBox::SUMMARYTODO); | 79 | mSummaryEdit->load(KOLocationBox::SUMMARYTODO); |
81 | mSummaryEdit->setFocus(); | 80 | mSummaryEdit->setFocus(); |
82 | } | 81 | } |
83 | 82 | ||
diff --git a/korganizer/koeditorrecurrence.cpp b/korganizer/koeditorrecurrence.cpp index d82172f..98356fe 100644 --- a/korganizer/koeditorrecurrence.cpp +++ b/korganizer/koeditorrecurrence.cpp | |||
@@ -19,65 +19,64 @@ | |||
19 | As a special exception, permission is given to link this program | 19 | As a special exception, permission is given to link this program |
20 | with any edition of Qt, and distribute the resulting executable, | 20 | with any edition of Qt, and distribute the resulting executable, |
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 <qfiledialog.h> |
26 | #include <qlayout.h> | 26 | #include <qlayout.h> |
27 | #include <qvbox.h> | 27 | #include <qvbox.h> |
28 | #include <qbuttongroup.h> | 28 | #include <qbuttongroup.h> |
29 | #include <qvgroupbox.h> | 29 | #include <qvgroupbox.h> |
30 | #include <qwidgetstack.h> | 30 | #include <qwidgetstack.h> |
31 | #include <qdatetime.h> | 31 | #include <qdatetime.h> |
32 | #include <qlistbox.h> | 32 | #include <qlistbox.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 | 36 | ||
37 | #include <kdialog.h> | 37 | #include <kdialog.h> |
38 | #include <kglobal.h> | 38 | #include <kglobal.h> |
39 | #include <klocale.h> | 39 | #include <klocale.h> |
40 | #include <kiconloader.h> | 40 | #include <kiconloader.h> |
41 | #include <kdebug.h> | 41 | #include <kdebug.h> |
42 | #include <knumvalidator.h> | 42 | #include <knumvalidator.h> |
43 | 43 | ||
44 | #include <libkcal/event.h> | 44 | #include <libkcal/event.h> |
45 | 45 | ||
46 | #include <libkdepim/kdateedit.h> | 46 | #include <libkdepim/kdateedit.h> |
47 | 47 | ||
48 | #include "koprefs.h" | 48 | #include "koprefs.h" |
49 | 49 | ||
50 | #include "koeditorrecurrence.h" | 50 | #include "koeditorrecurrence.h" |
51 | #include "koeditorrecurrence.moc" | ||
52 | 51 | ||
53 | /////////////////////////// RecurBase /////////////////////////////// | 52 | /////////////////////////// RecurBase /////////////////////////////// |
54 | 53 | ||
55 | RecurBase::RecurBase( QWidget *parent, const char *name ) : | 54 | RecurBase::RecurBase( QWidget *parent, const char *name ) : |
56 | QWidget( parent, name ) | 55 | QWidget( parent, name ) |
57 | { | 56 | { |
58 | mFrequencyEdit = new QSpinBox( 1, 9999, 1, this ); | 57 | mFrequencyEdit = new QSpinBox( 1, 9999, 1, this ); |
59 | mFrequencyEdit->setValue( 1 ); | 58 | mFrequencyEdit->setValue( 1 ); |
60 | } | 59 | } |
61 | 60 | ||
62 | QWidget *RecurBase::frequencyEdit() | 61 | QWidget *RecurBase::frequencyEdit() |
63 | { | 62 | { |
64 | return mFrequencyEdit; | 63 | return mFrequencyEdit; |
65 | } | 64 | } |
66 | 65 | ||
67 | void RecurBase::setFrequency( int f ) | 66 | void RecurBase::setFrequency( int f ) |
68 | { | 67 | { |
69 | if ( f < 1 ) f = 1; | 68 | if ( f < 1 ) f = 1; |
70 | 69 | ||
71 | mFrequencyEdit->setValue( f ); | 70 | mFrequencyEdit->setValue( f ); |
72 | } | 71 | } |
73 | 72 | ||
74 | int RecurBase::frequency() | 73 | int RecurBase::frequency() |
75 | { | 74 | { |
76 | return mFrequencyEdit->value(); | 75 | return mFrequencyEdit->value(); |
77 | } | 76 | } |
78 | 77 | ||
79 | /////////////////////////// RecurDaily /////////////////////////////// | 78 | /////////////////////////// RecurDaily /////////////////////////////// |
80 | 79 | ||
81 | RecurDaily::RecurDaily( QWidget *parent, const char *name ) : | 80 | RecurDaily::RecurDaily( QWidget *parent, const char *name ) : |
82 | RecurBase( parent, name ) | 81 | RecurBase( parent, name ) |
83 | { | 82 | { |
diff --git a/korganizer/koeventeditor.cpp b/korganizer/koeventeditor.cpp index b3edec6..0ff99a4 100644 --- a/korganizer/koeventeditor.cpp +++ b/korganizer/koeventeditor.cpp | |||
@@ -18,65 +18,64 @@ | |||
18 | 18 | ||
19 | As a special exception, permission is given to link this program | 19 | As a special exception, permission is given to link this program |
20 | with any edition of Qt, and distribute the resulting executable, | 20 | with any edition of Qt, and distribute the resulting executable, |
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 <qframe.h> | 25 | #include <qframe.h> |
26 | #include <qpixmap.h> | 26 | #include <qpixmap.h> |
27 | #include <qhbox.h> | 27 | #include <qhbox.h> |
28 | #include <qdir.h> | 28 | #include <qdir.h> |
29 | #include <qlayout.h> | 29 | #include <qlayout.h> |
30 | #include <qwidgetstack.h> | 30 | #include <qwidgetstack.h> |
31 | #include <qapplication.h> | 31 | #include <qapplication.h> |
32 | 32 | ||
33 | #include <kiconloader.h> | 33 | #include <kiconloader.h> |
34 | #include <kstandarddirs.h> | 34 | #include <kstandarddirs.h> |
35 | #include <kdebug.h> | 35 | #include <kdebug.h> |
36 | #include <klocale.h> | 36 | #include <klocale.h> |
37 | #include <kfiledialog.h> | 37 | #include <kfiledialog.h> |
38 | #include <kmessagebox.h> | 38 | #include <kmessagebox.h> |
39 | #include <libkcal/calendarresources.h> | 39 | #include <libkcal/calendarresources.h> |
40 | #include <libkcal/resourcecalendar.h> | 40 | #include <libkcal/resourcecalendar.h> |
41 | #include <kresources/resourceselectdialog.h> | 41 | #include <kresources/resourceselectdialog.h> |
42 | 42 | ||
43 | #include <libkdepim/categoryselectdialog.h> | 43 | #include <libkdepim/categoryselectdialog.h> |
44 | #include <libkcal/calendarlocal.h> | 44 | #include <libkcal/calendarlocal.h> |
45 | #include <libkcal/icalformat.h> | 45 | #include <libkcal/icalformat.h> |
46 | 46 | ||
47 | #include "koprefs.h" | 47 | #include "koprefs.h" |
48 | 48 | ||
49 | #include "koeventeditor.h" | 49 | #include "koeventeditor.h" |
50 | #include "koeventeditor.moc" | ||
51 | extern int globalFlagBlockAgenda; | 50 | extern int globalFlagBlockAgenda; |
52 | 51 | ||
53 | KOEventEditor::KOEventEditor( Calendar *calendar, QWidget *parent ) : | 52 | KOEventEditor::KOEventEditor( Calendar *calendar, QWidget *parent ) : |
54 | KOIncidenceEditor( i18n("Edit Event"), calendar, parent ) | 53 | KOIncidenceEditor( i18n("Edit Event"), calendar, parent ) |
55 | { | 54 | { |
56 | mEvent = 0; | 55 | mEvent = 0; |
57 | init(); | 56 | init(); |
58 | } | 57 | } |
59 | 58 | ||
60 | KOEventEditor::~KOEventEditor() | 59 | KOEventEditor::~KOEventEditor() |
61 | { | 60 | { |
62 | //emit dialogClose( mEvent ); | 61 | //emit dialogClose( mEvent ); |
63 | } | 62 | } |
64 | 63 | ||
65 | void KOEventEditor::init() | 64 | void KOEventEditor::init() |
66 | { | 65 | { |
67 | 66 | ||
68 | setupGeneral(); | 67 | setupGeneral(); |
69 | setupAttendeesTab(); | 68 | setupAttendeesTab(); |
70 | setupRecurrence(); | 69 | setupRecurrence(); |
71 | 70 | ||
72 | // Propagate date time settings to recurrence tab | 71 | // Propagate date time settings to recurrence tab |
73 | connect(mGeneral,SIGNAL(dateTimesChanged(QDateTime,QDateTime)), | 72 | connect(mGeneral,SIGNAL(dateTimesChanged(QDateTime,QDateTime)), |
74 | mRecurrence,SLOT(setDateTimes(QDateTime,QDateTime))); | 73 | mRecurrence,SLOT(setDateTimes(QDateTime,QDateTime))); |
75 | connect(mGeneral,SIGNAL(dateTimeStrChanged(const QString &)), | 74 | connect(mGeneral,SIGNAL(dateTimeStrChanged(const QString &)), |
76 | mRecurrence,SLOT(setDateTimeStr(const QString &))); | 75 | mRecurrence,SLOT(setDateTimeStr(const QString &))); |
77 | 76 | ||
78 | // Category dialog | 77 | // Category dialog |
79 | // connect(mGeneral,SIGNAL(openCategoryDialog()),mCategoryDialog,SLOT(show())); | 78 | // connect(mGeneral,SIGNAL(openCategoryDialog()),mCategoryDialog,SLOT(show())); |
80 | //connect(mCategoryDialog,SIGNAL(categoriesSelected(const QString &)), | 79 | //connect(mCategoryDialog,SIGNAL(categoriesSelected(const QString &)), |
81 | // mGeneral,SLOT(setCategories(const QString &))); | 80 | // mGeneral,SLOT(setCategories(const QString &))); |
82 | 81 | ||
diff --git a/korganizer/koeventpopupmenu.cpp b/korganizer/koeventpopupmenu.cpp index 410bceb..b274810 100644 --- a/korganizer/koeventpopupmenu.cpp +++ b/korganizer/koeventpopupmenu.cpp | |||
@@ -1,65 +1,64 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of KOrganizer. | 2 | This file is part of KOrganizer. |
3 | Copyright (c) 2000,2001 Cornelius Schumacher <schumacher@kde.org> | 3 | Copyright (c) 2000,2001 Cornelius Schumacher <schumacher@kde.org> |
4 | 4 | ||
5 | This program is free software; you can redistribute it and/or modify | 5 | This program is free software; you can redistribute it and/or modify |
6 | it under the terms of the GNU General Public License as published by | 6 | it under the terms of the GNU General Public License as published by |
7 | the Free Software Foundation; either version 2 of the License, or | 7 | the Free Software Foundation; either version 2 of the License, or |
8 | (at your option) any later version. | 8 | (at your option) any later version. |
9 | 9 | ||
10 | This program is distributed in the hope that it will be useful, | 10 | This program is distributed in the hope that it will be useful, |
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
13 | GNU General Public License for more details. | 13 | GNU General Public License for more details. |
14 | 14 | ||
15 | You should have received a copy of the GNU General Public License | 15 | You should have received a copy of the GNU General Public License |
16 | along with this program; if not, write to the Free Software | 16 | along with this program; if not, write to the Free Software |
17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
18 | 18 | ||
19 | As a special exception, permission is given to link this program | 19 | As a special exception, permission is given to link this program |
20 | with any edition of Qt, and distribute the resulting executable, | 20 | with any edition of Qt, and distribute the resulting executable, |
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 <qcursor.h> | 24 | #include <qcursor.h> |
25 | 25 | ||
26 | #include <klocale.h> | 26 | #include <klocale.h> |
27 | #include <kdebug.h> | 27 | #include <kdebug.h> |
28 | #include <kiconloader.h> | 28 | #include <kiconloader.h> |
29 | 29 | ||
30 | #include <libkcal/event.h> | 30 | #include <libkcal/event.h> |
31 | 31 | ||
32 | #include "koeventpopupmenu.h" | 32 | #include "koeventpopupmenu.h" |
33 | #include "koeventpopupmenu.moc" | ||
34 | 33 | ||
35 | KOEventPopupMenu::KOEventPopupMenu() | 34 | KOEventPopupMenu::KOEventPopupMenu() |
36 | { | 35 | { |
37 | mCurrentIncidence = 0; | 36 | mCurrentIncidence = 0; |
38 | mHasAdditionalItems = false; | 37 | mHasAdditionalItems = false; |
39 | 38 | ||
40 | insertItem (i18n("&Show"),this,SLOT(popupShow())); | 39 | insertItem (i18n("&Show"),this,SLOT(popupShow())); |
41 | mEditOnlyItems.append(insertItem (i18n("&Edit..."),this,SLOT(popupEdit()))); | 40 | mEditOnlyItems.append(insertItem (i18n("&Edit..."),this,SLOT(popupEdit()))); |
42 | mEditOnlyItems.append(insertItem (i18n("&Delete"), | 41 | mEditOnlyItems.append(insertItem (i18n("&Delete"), |
43 | this,SLOT(popupDelete()))); | 42 | this,SLOT(popupDelete()))); |
44 | mEditOnlyItems.append(insertItem (i18n("&Clone..."), | 43 | mEditOnlyItems.append(insertItem (i18n("&Clone..."), |
45 | this,SLOT(popupClone()))); | 44 | this,SLOT(popupClone()))); |
46 | mEditOnlyItems.append(insertItem (i18n("&Move..."), | 45 | mEditOnlyItems.append(insertItem (i18n("&Move..."), |
47 | this,SLOT(popupMove()))); | 46 | this,SLOT(popupMove()))); |
48 | #ifndef DESKTOP_VERSION | 47 | #ifndef DESKTOP_VERSION |
49 | mEditOnlyItems.append(insertItem (i18n("&Beam..."), | 48 | mEditOnlyItems.append(insertItem (i18n("&Beam..."), |
50 | this,SLOT(popupBeam()))); | 49 | this,SLOT(popupBeam()))); |
51 | #endif | 50 | #endif |
52 | mEditOnlyItems.append(insertItem (i18n("&Toggle Cancel"), | 51 | mEditOnlyItems.append(insertItem (i18n("&Toggle Cancel"), |
53 | this,SLOT(popupCancel()))); | 52 | this,SLOT(popupCancel()))); |
54 | } | 53 | } |
55 | 54 | ||
56 | void KOEventPopupMenu::showIncidencePopup(Incidence *incidence) | 55 | void KOEventPopupMenu::showIncidencePopup(Incidence *incidence) |
57 | { | 56 | { |
58 | mCurrentIncidence = incidence; | 57 | mCurrentIncidence = incidence; |
59 | 58 | ||
60 | if (mCurrentIncidence) { | 59 | if (mCurrentIncidence) { |
61 | // Enable/Disabled menu items only valid for editable events. | 60 | // Enable/Disabled menu items only valid for editable events. |
62 | QValueList<int>::Iterator it; | 61 | QValueList<int>::Iterator it; |
63 | for( it = mEditOnlyItems.begin(); it != mEditOnlyItems.end(); ++it ) { | 62 | for( it = mEditOnlyItems.begin(); it != mEditOnlyItems.end(); ++it ) { |
64 | setItemEnabled(*it,!mCurrentIncidence->isReadOnly()); | 63 | setItemEnabled(*it,!mCurrentIncidence->isReadOnly()); |
65 | } | 64 | } |
diff --git a/korganizer/koeventview.cpp b/korganizer/koeventview.cpp index 4553b0b..bce2626 100644 --- a/korganizer/koeventview.cpp +++ b/korganizer/koeventview.cpp | |||
@@ -4,65 +4,64 @@ | |||
4 | 4 | ||
5 | This program is free software; you can redistribute it and/or modify | 5 | This program is free software; you can redistribute it and/or modify |
6 | it under the terms of the GNU General Public License as published by | 6 | it under the terms of the GNU General Public License as published by |
7 | the Free Software Foundation; either version 2 of the License, or | 7 | the Free Software Foundation; either version 2 of the License, or |
8 | (at your option) any later version. | 8 | (at your option) any later version. |
9 | 9 | ||
10 | This program is distributed in the hope that it will be useful, | 10 | This program is distributed in the hope that it will be useful, |
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
13 | GNU General Public License for more details. | 13 | GNU General Public License for more details. |
14 | 14 | ||
15 | You should have received a copy of the GNU General Public License | 15 | You should have received a copy of the GNU General Public License |
16 | along with this program; if not, write to the Free Software | 16 | along with this program; if not, write to the Free Software |
17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
18 | 18 | ||
19 | As a special exception, permission is given to link this program | 19 | As a special exception, permission is given to link this program |
20 | with any edition of Qt, and distribute the resulting executable, | 20 | with any edition of Qt, and distribute the resulting executable, |
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 <qpopupmenu.h> | 24 | #include <qpopupmenu.h> |
25 | #include <qcursor.h> | 25 | #include <qcursor.h> |
26 | 26 | ||
27 | #include <klocale.h> | 27 | #include <klocale.h> |
28 | #include <kdebug.h> | 28 | #include <kdebug.h> |
29 | #include <kiconloader.h> | 29 | #include <kiconloader.h> |
30 | #include <kmessagebox.h> | 30 | #include <kmessagebox.h> |
31 | 31 | ||
32 | #include <libkcal/calendar.h> | 32 | #include <libkcal/calendar.h> |
33 | #include "koprefs.h" | 33 | #include "koprefs.h" |
34 | #include "koeventview.h" | 34 | #include "koeventview.h" |
35 | using namespace KOrg; | 35 | using namespace KOrg; |
36 | #include "koeventview.moc" | ||
37 | 36 | ||
38 | //--------------------------------------------------------------------------- | 37 | //--------------------------------------------------------------------------- |
39 | 38 | ||
40 | KOEventView::KOEventView(Calendar *cal,QWidget *parent,const char *name) | 39 | KOEventView::KOEventView(Calendar *cal,QWidget *parent,const char *name) |
41 | : KOrg::BaseView(cal,parent,name) | 40 | : KOrg::BaseView(cal,parent,name) |
42 | { | 41 | { |
43 | } | 42 | } |
44 | 43 | ||
45 | //--------------------------------------------------------------------------- | 44 | //--------------------------------------------------------------------------- |
46 | 45 | ||
47 | KOEventView::~KOEventView() | 46 | KOEventView::~KOEventView() |
48 | { | 47 | { |
49 | } | 48 | } |
50 | 49 | ||
51 | //--------------------------------------------------------------------------- | 50 | //--------------------------------------------------------------------------- |
52 | 51 | ||
53 | KOEventPopupMenu *KOEventView::eventPopup() | 52 | KOEventPopupMenu *KOEventView::eventPopup() |
54 | { | 53 | { |
55 | KOEventPopupMenu *eventPopup = new KOEventPopupMenu; | 54 | KOEventPopupMenu *eventPopup = new KOEventPopupMenu; |
56 | 55 | ||
57 | connect(eventPopup,SIGNAL(editIncidenceSignal(Incidence *)), | 56 | connect(eventPopup,SIGNAL(editIncidenceSignal(Incidence *)), |
58 | SIGNAL(editIncidenceSignal(Incidence *))); | 57 | SIGNAL(editIncidenceSignal(Incidence *))); |
59 | connect(eventPopup,SIGNAL(showIncidenceSignal(Incidence *)), | 58 | connect(eventPopup,SIGNAL(showIncidenceSignal(Incidence *)), |
60 | SIGNAL(showIncidenceSignal(Incidence *))); | 59 | SIGNAL(showIncidenceSignal(Incidence *))); |
61 | connect(eventPopup,SIGNAL(deleteIncidenceSignal(Incidence *)), | 60 | connect(eventPopup,SIGNAL(deleteIncidenceSignal(Incidence *)), |
62 | SIGNAL(deleteIncidenceSignal(Incidence *))); | 61 | SIGNAL(deleteIncidenceSignal(Incidence *))); |
63 | connect(eventPopup,SIGNAL(cancelIncidenceSignal(Incidence *)), | 62 | connect(eventPopup,SIGNAL(cancelIncidenceSignal(Incidence *)), |
64 | SIGNAL(cancelIncidenceSignal(Incidence *))); | 63 | SIGNAL(cancelIncidenceSignal(Incidence *))); |
65 | connect(eventPopup,SIGNAL(cloneIncidenceSignal(Incidence *)), | 64 | connect(eventPopup,SIGNAL(cloneIncidenceSignal(Incidence *)), |
66 | SIGNAL(cloneIncidenceSignal(Incidence *))); | 65 | SIGNAL(cloneIncidenceSignal(Incidence *))); |
67 | connect(eventPopup,SIGNAL(beamIncidenceSignal(Incidence *)), | 66 | connect(eventPopup,SIGNAL(beamIncidenceSignal(Incidence *)), |
68 | SIGNAL(beamIncidenceSignal(Incidence *))); | 67 | SIGNAL(beamIncidenceSignal(Incidence *))); |
@@ -100,34 +99,32 @@ void KOEventView::popupEdit() | |||
100 | void KOEventView::popupDelete() | 99 | void KOEventView::popupDelete() |
101 | { | 100 | { |
102 | emit deleteIncidenceSignal(mCurrentIncidence); | 101 | emit deleteIncidenceSignal(mCurrentIncidence); |
103 | } | 102 | } |
104 | void KOEventView::popupClone() | 103 | void KOEventView::popupClone() |
105 | { | 104 | { |
106 | emit cloneIncidenceSignal(mCurrentIncidence); | 105 | emit cloneIncidenceSignal(mCurrentIncidence); |
107 | } | 106 | } |
108 | void KOEventView::popupCancel() | 107 | void KOEventView::popupCancel() |
109 | { | 108 | { |
110 | emit cancelIncidenceSignal(mCurrentIncidence); | 109 | emit cancelIncidenceSignal(mCurrentIncidence); |
111 | } | 110 | } |
112 | 111 | ||
113 | //--------------------------------------------------------------------------- | 112 | //--------------------------------------------------------------------------- |
114 | 113 | ||
115 | void KOEventView::defaultAction( Incidence *incidence ) | 114 | void KOEventView::defaultAction( Incidence *incidence ) |
116 | { | 115 | { |
117 | 116 | ||
118 | if ( !incidence ) return; | 117 | if ( !incidence ) return; |
119 | 118 | ||
120 | if ( incidence->isReadOnly() ) | 119 | if ( incidence->isReadOnly() ) |
121 | emit showIncidenceSignal(incidence); | 120 | emit showIncidenceSignal(incidence); |
122 | else { | 121 | else { |
123 | if ( KOPrefs::instance()->mEditOnDoubleClick ) | 122 | if ( KOPrefs::instance()->mEditOnDoubleClick ) |
124 | emit editIncidenceSignal(incidence); | 123 | emit editIncidenceSignal(incidence); |
125 | else | 124 | else |
126 | emit showIncidenceSignal(incidence); | 125 | emit showIncidenceSignal(incidence); |
127 | } | 126 | } |
128 | } | 127 | } |
129 | 128 | ||
130 | //--------------------------------------------------------------------------- | 129 | //--------------------------------------------------------------------------- |
131 | 130 | ||
132 | #include "baseview.moc" | ||
133 | |||
diff --git a/korganizer/koeventviewer.cpp b/korganizer/koeventviewer.cpp index 9f8bd9b..bac66d3 100644 --- a/korganizer/koeventviewer.cpp +++ b/korganizer/koeventviewer.cpp | |||
@@ -17,65 +17,64 @@ | |||
17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
18 | */ | 18 | */ |
19 | 19 | ||
20 | #include <qcstring.h> | 20 | #include <qcstring.h> |
21 | #include <qwhatsthis.h> | 21 | #include <qwhatsthis.h> |
22 | #include <qdialog.h> | 22 | #include <qdialog.h> |
23 | #include <qapplication.h> | 23 | #include <qapplication.h> |
24 | #include <qlabel.h> | 24 | #include <qlabel.h> |
25 | #include <qlayout.h> | 25 | #include <qlayout.h> |
26 | 26 | ||
27 | #include <klocale.h> | 27 | #include <klocale.h> |
28 | #include <kapplication.h> | 28 | #include <kapplication.h> |
29 | #include <libkcal/event.h> | 29 | #include <libkcal/event.h> |
30 | #include <libkcal/todo.h> | 30 | #include <libkcal/todo.h> |
31 | #include <kdebug.h> | 31 | #include <kdebug.h> |
32 | #include <kiconloader.h> | 32 | #include <kiconloader.h> |
33 | #include <krun.h> | 33 | #include <krun.h> |
34 | #include <kglobal.h> | 34 | #include <kglobal.h> |
35 | #include <kprocess.h> | 35 | #include <kprocess.h> |
36 | #include "koprefs.h" | 36 | #include "koprefs.h" |
37 | 37 | ||
38 | #include <libkdepim/addresseeview.h> | 38 | #include <libkdepim/addresseeview.h> |
39 | #include <kabc/stdaddressbook.h> | 39 | #include <kabc/stdaddressbook.h> |
40 | 40 | ||
41 | #ifndef KORG_NODCOP | 41 | #ifndef KORG_NODCOP |
42 | #include <dcopclient.h> | 42 | #include <dcopclient.h> |
43 | #include "korganizer.h" | 43 | #include "korganizer.h" |
44 | #include "koprefs.h" | 44 | #include "koprefs.h" |
45 | #include "actionmanager.h" | 45 | #include "actionmanager.h" |
46 | #endif | 46 | #endif |
47 | 47 | ||
48 | #include "koeventviewer.h" | 48 | #include "koeventviewer.h" |
49 | #include "koeventviewer.moc" | ||
50 | #ifndef KORG_NOKABC | 49 | #ifndef KORG_NOKABC |
51 | #include <kabc/stdaddressbook.h> | 50 | #include <kabc/stdaddressbook.h> |
52 | #define size count | 51 | #define size count |
53 | #endif | 52 | #endif |
54 | KOEventViewer::KOEventViewer(QWidget *parent,const char *name) | 53 | KOEventViewer::KOEventViewer(QWidget *parent,const char *name) |
55 | : QTextBrowser(parent,name) | 54 | : QTextBrowser(parent,name) |
56 | { | 55 | { |
57 | mSyncMode = false; | 56 | mSyncMode = false; |
58 | mColorMode = 0; | 57 | mColorMode = 0; |
59 | } | 58 | } |
60 | 59 | ||
61 | KOEventViewer::~KOEventViewer() | 60 | KOEventViewer::~KOEventViewer() |
62 | { | 61 | { |
63 | } | 62 | } |
64 | 63 | ||
65 | void KOEventViewer::setSource(const QString& n) | 64 | void KOEventViewer::setSource(const QString& n) |
66 | { | 65 | { |
67 | KABC::StdAddressBook* AddressBook = KABC::StdAddressBook::self( true ); | 66 | KABC::StdAddressBook* AddressBook = KABC::StdAddressBook::self( true ); |
68 | KABC::AddressBook::Iterator it; | 67 | KABC::AddressBook::Iterator it; |
69 | for( it = AddressBook->begin(); it != AddressBook->end(); ++it ) { | 68 | for( it = AddressBook->begin(); it != AddressBook->end(); ++it ) { |
70 | // LR I do not understand, why the uid string is different on zaurus and desktop | 69 | // LR I do not understand, why the uid string is different on zaurus and desktop |
71 | #ifdef DESKTOP_VERSION | 70 | #ifdef DESKTOP_VERSION |
72 | QString uid = "uid://"+(*it).uid(); | 71 | QString uid = "uid://"+(*it).uid(); |
73 | #else | 72 | #else |
74 | QString uid = "uid:"+(*it).uid(); | 73 | QString uid = "uid:"+(*it).uid(); |
75 | #endif | 74 | #endif |
76 | //qDebug("for *%s* +%s+ ", n.latin1(), uid.latin1()); | 75 | //qDebug("for *%s* +%s+ ", n.latin1(), uid.latin1()); |
77 | if (n == uid ) { | 76 | if (n == uid ) { |
78 | //qDebug("found %s ",(*it).mobileHomePhone().latin1() ); | 77 | //qDebug("found %s ",(*it).mobileHomePhone().latin1() ); |
79 | QDialog dia( this,"dia123", true ); | 78 | QDialog dia( this,"dia123", true ); |
80 | dia.setCaption( i18n("Details of attendee") ); | 79 | dia.setCaption( i18n("Details of attendee") ); |
81 | QVBoxLayout lay ( &dia ); | 80 | QVBoxLayout lay ( &dia ); |
diff --git a/korganizer/koeventviewerdialog.cpp b/korganizer/koeventviewerdialog.cpp index 64ab94d..be183eb 100644 --- a/korganizer/koeventviewerdialog.cpp +++ b/korganizer/koeventviewerdialog.cpp | |||
@@ -1,63 +1,62 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of KOrganizer. | 2 | This file is part of KOrganizer. |
3 | Copyright (c) 2000,2001 Cornelius Schumacher <schumacher@kde.org> | 3 | Copyright (c) 2000,2001 Cornelius Schumacher <schumacher@kde.org> |
4 | 4 | ||
5 | This program is free software; you can redistribute it and/or modify | 5 | This program is free software; you can redistribute it and/or modify |
6 | it under the terms of the GNU General Public License as published by | 6 | it under the terms of the GNU General Public License as published by |
7 | the Free Software Foundation; either version 2 of the License, or | 7 | the Free Software Foundation; either version 2 of the License, or |
8 | (at your option) any later version. | 8 | (at your option) any later version. |
9 | 9 | ||
10 | This program is distributed in the hope that it will be useful, | 10 | This program is distributed in the hope that it will be useful, |
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
13 | GNU General Public License for more details. | 13 | GNU General Public License for more details. |
14 | 14 | ||
15 | You should have received a copy of the GNU General Public License | 15 | You should have received a copy of the GNU General Public License |
16 | along with this program; if not, write to the Free Software | 16 | along with this program; if not, write to the Free Software |
17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
18 | */ | 18 | */ |
19 | 19 | ||
20 | #include <klocale.h> | 20 | #include <klocale.h> |
21 | 21 | ||
22 | #include <libkcal/event.h> | 22 | #include <libkcal/event.h> |
23 | #include <qpushbutton.h> | 23 | #include <qpushbutton.h> |
24 | 24 | ||
25 | #include "koeventviewer.h" | 25 | #include "koeventviewer.h" |
26 | #include "koprefs.h" | 26 | #include "koprefs.h" |
27 | #include <libkcal/todo.h> | 27 | #include <libkcal/todo.h> |
28 | #include "qapp.h" | 28 | #include "qapp.h" |
29 | 29 | ||
30 | #include "koeventviewerdialog.h" | 30 | #include "koeventviewerdialog.h" |
31 | #include "koeventviewerdialog.moc" | ||
32 | extern int globalFlagBlockAgenda; | 31 | extern int globalFlagBlockAgenda; |
33 | 32 | ||
34 | KOEventViewerDialog::KOEventViewerDialog(QWidget *parent,const char *name) | 33 | KOEventViewerDialog::KOEventViewerDialog(QWidget *parent,const char *name) |
35 | : KDialogBase(parent,name, | 34 | : KDialogBase(parent,name, |
36 | #ifndef DESKTOP_VERSION | 35 | #ifndef DESKTOP_VERSION |
37 | true , | 36 | true , |
38 | #else | 37 | #else |
39 | false, | 38 | false, |
40 | #endif | 39 | #endif |
41 | i18n("Event Viewer"),Ok|User1|Close,Close, false, i18n("Agenda")) | 40 | i18n("Event Viewer"),Ok|User1|Close,Close, false, i18n("Agenda")) |
42 | { | 41 | { |
43 | 42 | ||
44 | mEventViewer = new KOEventViewer(this); | 43 | mEventViewer = new KOEventViewer(this); |
45 | mEventViewer->setFont( KOPrefs::instance()->mEventViewFont ); | 44 | mEventViewer->setFont( KOPrefs::instance()->mEventViewFont ); |
46 | setMainWidget(mEventViewer); | 45 | setMainWidget(mEventViewer); |
47 | setButtonText(Ok, i18n("Edit") ); | 46 | setButtonText(Ok, i18n("Edit") ); |
48 | 47 | ||
49 | QObject::connect(findButton( Ok ),SIGNAL(clicked()), | 48 | QObject::connect(findButton( Ok ),SIGNAL(clicked()), |
50 | SLOT(editIncidence())); | 49 | SLOT(editIncidence())); |
51 | QObject::connect(this,SIGNAL(user1Clicked()), | 50 | QObject::connect(this,SIGNAL(user1Clicked()), |
52 | SLOT(showIncidence())); | 51 | SLOT(showIncidence())); |
53 | mIncidence = 0; | 52 | mIncidence = 0; |
54 | // TODO: Set a sensible size (based on the content?). | 53 | // TODO: Set a sensible size (based on the content?). |
55 | //showMaximized(); | 54 | //showMaximized(); |
56 | //qDebug("++++++++++++KOEventViewerDialog() "); | 55 | //qDebug("++++++++++++KOEventViewerDialog() "); |
57 | // if ( KOPrefs::instance()->mCompactDialogs ) { | 56 | // if ( KOPrefs::instance()->mCompactDialogs ) { |
58 | // setFixedSize( 240,284 ); | 57 | // setFixedSize( 240,284 ); |
59 | // move( 0, 15 ); | 58 | // move( 0, 15 ); |
60 | // } else { | 59 | // } else { |
61 | // setMinimumSize(300,200); | 60 | // setMinimumSize(300,200); |
62 | // resize(320,300); | 61 | // resize(320,300); |
63 | // } | 62 | // } |
diff --git a/korganizer/kofilterview.cpp b/korganizer/kofilterview.cpp index b22bc54..1479208 100644 --- a/korganizer/kofilterview.cpp +++ b/korganizer/kofilterview.cpp | |||
@@ -1,63 +1,62 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of KOrganizer. | 2 | This file is part of KOrganizer. |
3 | Copyright (c) 2001 Cornelius Schumacher <schumacher@kde.org> | 3 | Copyright (c) 2001 Cornelius Schumacher <schumacher@kde.org> |
4 | 4 | ||
5 | This program is free software; you can redistribute it and/or modify | 5 | This program is free software; you can redistribute it and/or modify |
6 | it under the terms of the GNU General Public License as published by | 6 | it under the terms of the GNU General Public License as published by |
7 | the Free Software Foundation; either version 2 of the License, or | 7 | the Free Software Foundation; either version 2 of the License, or |
8 | (at your option) any later version. | 8 | (at your option) any later version. |
9 | 9 | ||
10 | This program is distributed in the hope that it will be useful, | 10 | This program is distributed in the hope that it will be useful, |
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
13 | GNU General Public License for more details. | 13 | GNU General Public License for more details. |
14 | 14 | ||
15 | You should have received a copy of the GNU General Public License | 15 | You should have received a copy of the GNU General Public License |
16 | along with this program; if not, write to the Free Software | 16 | along with this program; if not, write to the Free Software |
17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
18 | 18 | ||
19 | As a special exception, permission is given to link this program | 19 | As a special exception, permission is given to link this program |
20 | with any edition of Qt, and distribute the resulting executable, | 20 | with any edition of Qt, and distribute the resulting executable, |
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 <qcheckbox.h> | 24 | #include <qcheckbox.h> |
25 | #include <qcombobox.h> | 25 | #include <qcombobox.h> |
26 | #include <qpushbutton.h> | 26 | #include <qpushbutton.h> |
27 | 27 | ||
28 | #include <libkcal/calfilter.h> | 28 | #include <libkcal/calfilter.h> |
29 | 29 | ||
30 | #include "kofilterview.h" | 30 | #include "kofilterview.h" |
31 | #include "kofilterview.moc" | ||
32 | 31 | ||
33 | KOFilterView::KOFilterView(QPtrList<CalFilter> *filterList,QWidget* parent, | 32 | KOFilterView::KOFilterView(QPtrList<CalFilter> *filterList,QWidget* parent, |
34 | const char* name,WFlags fl ) | 33 | const char* name,WFlags fl ) |
35 | : KOFilterView_base(parent,name,fl) | 34 | : KOFilterView_base(parent,name,fl) |
36 | { | 35 | { |
37 | mFilters = filterList; | 36 | mFilters = filterList; |
38 | 37 | ||
39 | connect(mSelectionCombo,SIGNAL(activated(int)),SIGNAL(filterChanged())); | 38 | connect(mSelectionCombo,SIGNAL(activated(int)),SIGNAL(filterChanged())); |
40 | connect(mEnabledCheck,SIGNAL(clicked()),SIGNAL(filterChanged())); | 39 | connect(mEnabledCheck,SIGNAL(clicked()),SIGNAL(filterChanged())); |
41 | connect(mEditButton,SIGNAL(clicked()),SIGNAL(editFilters())); | 40 | connect(mEditButton,SIGNAL(clicked()),SIGNAL(editFilters())); |
42 | } | 41 | } |
43 | 42 | ||
44 | KOFilterView::~KOFilterView() | 43 | KOFilterView::~KOFilterView() |
45 | { | 44 | { |
46 | // no need to delete child widgets, Qt does it all for us | 45 | // no need to delete child widgets, Qt does it all for us |
47 | } | 46 | } |
48 | 47 | ||
49 | bool KOFilterView::filtersEnabled() | 48 | bool KOFilterView::filtersEnabled() |
50 | { | 49 | { |
51 | return mEnabledCheck->isChecked(); | 50 | return mEnabledCheck->isChecked(); |
52 | } | 51 | } |
53 | 52 | ||
54 | void KOFilterView::setFiltersEnabled(bool set) | 53 | void KOFilterView::setFiltersEnabled(bool set) |
55 | { | 54 | { |
56 | mEnabledCheck->setChecked(set); | 55 | mEnabledCheck->setChecked(set); |
57 | emit filterChanged(); | 56 | emit filterChanged(); |
58 | } | 57 | } |
59 | 58 | ||
60 | 59 | ||
61 | void KOFilterView::updateFilters() | 60 | void KOFilterView::updateFilters() |
62 | { | 61 | { |
63 | mSelectionCombo->clear(); | 62 | mSelectionCombo->clear(); |
diff --git a/korganizer/koincidenceeditor.cpp b/korganizer/koincidenceeditor.cpp index e10a188..51df123 100644 --- a/korganizer/koincidenceeditor.cpp +++ b/korganizer/koincidenceeditor.cpp | |||
@@ -16,65 +16,64 @@ | |||
16 | along with this program; if not, write to the Free Software | 16 | along with this program; if not, write to the Free Software |
17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
18 | 18 | ||
19 | As a special exception, permission is given to link this program | 19 | As a special exception, permission is given to link this program |
20 | with any edition of Qt, and distribute the resulting executable, | 20 | with any edition of Qt, and distribute the resulting executable, |
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 <qframe.h> | 25 | #include <qframe.h> |
26 | #include <qpixmap.h> | 26 | #include <qpixmap.h> |
27 | #include <qlayout.h> | 27 | #include <qlayout.h> |
28 | #include <qwidgetstack.h> | 28 | #include <qwidgetstack.h> |
29 | #include <qdatetime.h> | 29 | #include <qdatetime.h> |
30 | #include <qdir.h> | 30 | #include <qdir.h> |
31 | 31 | ||
32 | #include <kdebug.h> | 32 | #include <kdebug.h> |
33 | #include <klocale.h> | 33 | #include <klocale.h> |
34 | #include <kstandarddirs.h> | 34 | #include <kstandarddirs.h> |
35 | #include <kmessagebox.h> | 35 | #include <kmessagebox.h> |
36 | #include <kfiledialog.h> | 36 | #include <kfiledialog.h> |
37 | 37 | ||
38 | #include <libkdepim/categoryselectdialog.h> | 38 | #include <libkdepim/categoryselectdialog.h> |
39 | #include <libkdepim/kinputdialog.h> | 39 | #include <libkdepim/kinputdialog.h> |
40 | 40 | ||
41 | #include <libkcal/calendarlocal.h> | 41 | #include <libkcal/calendarlocal.h> |
42 | #include <libkcal/icalformat.h> | 42 | #include <libkcal/icalformat.h> |
43 | 43 | ||
44 | #include "koprefs.h" | 44 | #include "koprefs.h" |
45 | #include "koglobals.h" | 45 | #include "koglobals.h" |
46 | 46 | ||
47 | #include "koincidenceeditor.h" | 47 | #include "koincidenceeditor.h" |
48 | #include "koincidenceeditor.moc" | ||
49 | 48 | ||
50 | KOIncidenceEditor::KOIncidenceEditor( const QString &caption, | 49 | KOIncidenceEditor::KOIncidenceEditor( const QString &caption, |
51 | Calendar *calendar, QWidget *parent ) : | 50 | Calendar *calendar, QWidget *parent ) : |
52 | KDialogBase( Tabbed, caption, Ok | Apply | Cancel |/* Default | */User1, Ok, | 51 | KDialogBase( Tabbed, caption, Ok | Apply | Cancel |/* Default | */User1, Ok, |
53 | parent, caption, true, false ), | 52 | parent, caption, true, false ), |
54 | mSaveTemplateDialog( 0 ) | 53 | mSaveTemplateDialog( 0 ) |
55 | { | 54 | { |
56 | mCalendar = calendar; | 55 | mCalendar = calendar; |
57 | 56 | ||
58 | setButtonText( Default, i18n("Template...") ); | 57 | setButtonText( Default, i18n("Template...") ); |
59 | 58 | ||
60 | QString saveTemplateText; | 59 | QString saveTemplateText; |
61 | // if ( KOPrefs::instance()->mCompactDialogs ) { | 60 | // if ( KOPrefs::instance()->mCompactDialogs ) { |
62 | // showButton( User1, false ); | 61 | // showButton( User1, false ); |
63 | // showButton( Apply, false ); | 62 | // showButton( Apply, false ); |
64 | // } else { | 63 | // } else { |
65 | showButton( Apply, false ); | 64 | showButton( Apply, false ); |
66 | saveTemplateText = i18n("Ok+Agenda"); | 65 | saveTemplateText = i18n("Ok+Agenda"); |
67 | // } | 66 | // } |
68 | setButtonText( User1, saveTemplateText ); | 67 | setButtonText( User1, saveTemplateText ); |
69 | 68 | ||
70 | //mCategoryDialog = new KPIM::CategorySelectDialog( KOPrefs::instance(), this ); | 69 | //mCategoryDialog = new KPIM::CategorySelectDialog( KOPrefs::instance(), this ); |
71 | // KOGlobals::fitDialogToScreen( mCategoryDialog ); | 70 | // KOGlobals::fitDialogToScreen( mCategoryDialog ); |
72 | 71 | ||
73 | //connect(mCategoryDialog,SIGNAL(editCategories()),SIGNAL(editCategories())); | 72 | //connect(mCategoryDialog,SIGNAL(editCategories()),SIGNAL(editCategories())); |
74 | 73 | ||
75 | //connect( this, SIGNAL( defaultClicked() ), SLOT( slotLoadTemplate() ) ); | 74 | //connect( this, SIGNAL( defaultClicked() ), SLOT( slotLoadTemplate() ) ); |
76 | // connect( this, SIGNAL( user1Clicked() ), SLOT( slotSaveTemplate() ) ); | 75 | // connect( this, SIGNAL( user1Clicked() ), SLOT( slotSaveTemplate() ) ); |
77 | connect( this, SIGNAL( user1Clicked() ), SLOT( slotShowIncidence() ) ); | 76 | connect( this, SIGNAL( user1Clicked() ), SLOT( slotShowIncidence() ) ); |
78 | } | 77 | } |
79 | 78 | ||
80 | KOIncidenceEditor::~KOIncidenceEditor() | 79 | KOIncidenceEditor::~KOIncidenceEditor() |
diff --git a/korganizer/kojournalview.cpp b/korganizer/kojournalview.cpp index 579f24d..6e6a939 100644 --- a/korganizer/kojournalview.cpp +++ b/korganizer/kojournalview.cpp | |||
@@ -8,65 +8,64 @@ | |||
8 | (at your option) any later version. | 8 | (at your option) any later version. |
9 | 9 | ||
10 | This program is distributed in the hope that it will be useful, | 10 | This program is distributed in the hope that it will be useful, |
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
13 | GNU General Public License for more details. | 13 | GNU General Public License for more details. |
14 | 14 | ||
15 | You should have received a copy of the GNU General Public License | 15 | You should have received a copy of the GNU General Public License |
16 | along with this program; if not, write to the Free Software | 16 | along with this program; if not, write to the Free Software |
17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
18 | 18 | ||
19 | As a special exception, permission is given to link this program | 19 | As a special exception, permission is given to link this program |
20 | with any edition of Qt, and distribute the resulting executable, | 20 | with any edition of Qt, and distribute the resulting executable, |
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 | // | 24 | // |
25 | // View of Journal entries | 25 | // View of Journal entries |
26 | 26 | ||
27 | #include <qlayout.h> | 27 | #include <qlayout.h> |
28 | #include <qpopupmenu.h> | 28 | #include <qpopupmenu.h> |
29 | 29 | ||
30 | #include <klocale.h> | 30 | #include <klocale.h> |
31 | #include <kdebug.h> | 31 | #include <kdebug.h> |
32 | #include "koprefs.h" | 32 | #include "koprefs.h" |
33 | 33 | ||
34 | #include <libkcal/calendar.h> | 34 | #include <libkcal/calendar.h> |
35 | 35 | ||
36 | #include "journalentry.h" | 36 | #include "journalentry.h" |
37 | 37 | ||
38 | #include "kojournalview.h" | 38 | #include "kojournalview.h" |
39 | using namespace KOrg; | 39 | using namespace KOrg; |
40 | #include "kojournalview.moc" | ||
41 | 40 | ||
42 | KOJournalView::KOJournalView(Calendar *calendar, QWidget *parent, | 41 | KOJournalView::KOJournalView(Calendar *calendar, QWidget *parent, |
43 | const char *name) | 42 | const char *name) |
44 | : KOrg::BaseView(calendar, parent, name) | 43 | : KOrg::BaseView(calendar, parent, name) |
45 | { | 44 | { |
46 | mEntry = new JournalEntry(calendar,this); | 45 | mEntry = new JournalEntry(calendar,this); |
47 | mEntry->setFont ( KOPrefs::instance()->mJornalViewFont ); | 46 | mEntry->setFont ( KOPrefs::instance()->mJornalViewFont ); |
48 | QBoxLayout *topLayout = new QVBoxLayout(this); | 47 | QBoxLayout *topLayout = new QVBoxLayout(this); |
49 | topLayout->addWidget(mEntry); | 48 | topLayout->addWidget(mEntry); |
50 | connect ( mEntry,SIGNAL(deleteJournal(Journal *) ),this ,SIGNAL(deleteJournal(Journal *) ) ) ; | 49 | connect ( mEntry,SIGNAL(deleteJournal(Journal *) ),this ,SIGNAL(deleteJournal(Journal *) ) ) ; |
51 | } | 50 | } |
52 | 51 | ||
53 | KOJournalView::~KOJournalView() | 52 | KOJournalView::~KOJournalView() |
54 | { | 53 | { |
55 | } | 54 | } |
56 | 55 | ||
57 | int KOJournalView::currentDateCount() | 56 | int KOJournalView::currentDateCount() |
58 | { | 57 | { |
59 | return 0; | 58 | return 0; |
60 | } | 59 | } |
61 | 60 | ||
62 | QPtrList<Incidence> KOJournalView::selectedIncidences() | 61 | QPtrList<Incidence> KOJournalView::selectedIncidences() |
63 | { | 62 | { |
64 | QPtrList<Incidence> eventList; | 63 | QPtrList<Incidence> eventList; |
65 | 64 | ||
66 | return eventList; | 65 | return eventList; |
67 | } | 66 | } |
68 | void KOJournalView::updateConfig() | 67 | void KOJournalView::updateConfig() |
69 | { | 68 | { |
70 | mEntry->setFont ( KOPrefs::instance()->mJornalViewFont ); | 69 | mEntry->setFont ( KOPrefs::instance()->mJornalViewFont ); |
71 | } | 70 | } |
72 | void KOJournalView::updateView() | 71 | void KOJournalView::updateView() |
diff --git a/korganizer/kolistview.cpp b/korganizer/kolistview.cpp index b6061d0..9a3ba73 100644 --- a/korganizer/kolistview.cpp +++ b/korganizer/kolistview.cpp | |||
@@ -30,65 +30,64 @@ | |||
30 | #include <qfileinfo.h> | 30 | #include <qfileinfo.h> |
31 | #include <qmessagebox.h> | 31 | #include <qmessagebox.h> |
32 | #include <qdialog.h> | 32 | #include <qdialog.h> |
33 | #include <qtextstream.h> | 33 | #include <qtextstream.h> |
34 | #include <qdir.h> | 34 | #include <qdir.h> |
35 | 35 | ||
36 | #include <klocale.h> | 36 | #include <klocale.h> |
37 | #include <kdebug.h> | 37 | #include <kdebug.h> |
38 | #include <kiconloader.h> | 38 | #include <kiconloader.h> |
39 | #include <kglobal.h> | 39 | #include <kglobal.h> |
40 | 40 | ||
41 | #include <libkcal/calendar.h> | 41 | #include <libkcal/calendar.h> |
42 | #include <libkcal/calendarlocal.h> | 42 | #include <libkcal/calendarlocal.h> |
43 | #include <libkcal/icalformat.h> | 43 | #include <libkcal/icalformat.h> |
44 | #include <libkcal/vcalformat.h> | 44 | #include <libkcal/vcalformat.h> |
45 | #include <libkcal/recurrence.h> | 45 | #include <libkcal/recurrence.h> |
46 | #include <libkcal/filestorage.h> | 46 | #include <libkcal/filestorage.h> |
47 | #include <libkdepim/categoryselectdialog.h> | 47 | #include <libkdepim/categoryselectdialog.h> |
48 | #ifndef DESKTOP_VERSION | 48 | #ifndef DESKTOP_VERSION |
49 | #include <qpe/qpeapplication.h> | 49 | #include <qpe/qpeapplication.h> |
50 | #else | 50 | #else |
51 | #include <qapplication.h> | 51 | #include <qapplication.h> |
52 | #endif | 52 | #endif |
53 | 53 | ||
54 | #ifndef KORG_NOPRINTER | 54 | #ifndef KORG_NOPRINTER |
55 | #include "calprinter.h" | 55 | #include "calprinter.h" |
56 | #endif | 56 | #endif |
57 | #include "koglobals.h" | 57 | #include "koglobals.h" |
58 | #include "koprefs.h" | 58 | #include "koprefs.h" |
59 | #include "kfiledialog.h" | 59 | #include "kfiledialog.h" |
60 | 60 | ||
61 | #include "kolistview.h" | 61 | #include "kolistview.h" |
62 | #include "kolistview.moc" | ||
63 | 62 | ||
64 | ListItemVisitor::ListItemVisitor(KOListViewItem *item, QDate date ) | 63 | ListItemVisitor::ListItemVisitor(KOListViewItem *item, QDate date ) |
65 | { | 64 | { |
66 | mItem = item; | 65 | mItem = item; |
67 | mDate = date; | 66 | mDate = date; |
68 | } | 67 | } |
69 | 68 | ||
70 | ListItemVisitor::~ListItemVisitor() | 69 | ListItemVisitor::~ListItemVisitor() |
71 | { | 70 | { |
72 | } | 71 | } |
73 | 72 | ||
74 | bool ListItemVisitor::visit(Event *e) | 73 | bool ListItemVisitor::visit(Event *e) |
75 | { | 74 | { |
76 | 75 | ||
77 | bool ok = false; | 76 | bool ok = false; |
78 | QString start, end; | 77 | QString start, end; |
79 | if ( e->doesRecur() ) { | 78 | if ( e->doesRecur() ) { |
80 | QDate d = e->getNextOccurence( QDateTime( mDate, QTime(0,0,0)), &ok ).date(); | 79 | QDate d = e->getNextOccurence( QDateTime( mDate, QTime(0,0,0)), &ok ).date(); |
81 | if ( ok ) { | 80 | if ( ok ) { |
82 | int days = e->dtStart().date().daysTo(e->dtEnd().date() ); | 81 | int days = e->dtStart().date().daysTo(e->dtEnd().date() ); |
83 | start = KGlobal::locale()->formatDate(d,true); | 82 | start = KGlobal::locale()->formatDate(d,true); |
84 | end = KGlobal::locale()->formatDate(d.addDays( days),true); | 83 | end = KGlobal::locale()->formatDate(d.addDays( days),true); |
85 | } | 84 | } |
86 | 85 | ||
87 | } | 86 | } |
88 | if ( ! ok ) { | 87 | if ( ! ok ) { |
89 | start =e->dtStartDateStr(); | 88 | start =e->dtStartDateStr(); |
90 | end = e->dtEndDateStr(); | 89 | end = e->dtEndDateStr(); |
91 | } | 90 | } |
92 | mItem->setText(0,e->summary()); | 91 | mItem->setText(0,e->summary()); |
93 | mItem->setText(1,start); | 92 | mItem->setText(1,start); |
94 | mItem->setText(2,e->dtStartTimeStr()); | 93 | mItem->setText(2,e->dtStartTimeStr()); |
diff --git a/korganizer/komonthview.cpp b/korganizer/komonthview.cpp index c4bc51b..df60564 100644 --- a/korganizer/komonthview.cpp +++ b/korganizer/komonthview.cpp | |||
@@ -23,65 +23,64 @@ | |||
23 | #include <qkeycode.h> | 23 | #include <qkeycode.h> |
24 | #include <qhbox.h> | 24 | #include <qhbox.h> |
25 | #include <qvbox.h> | 25 | #include <qvbox.h> |
26 | #include <qpushbutton.h> | 26 | #include <qpushbutton.h> |
27 | #include <qtooltip.h> | 27 | #include <qtooltip.h> |
28 | #include <qpainter.h> | 28 | #include <qpainter.h> |
29 | #include <qwhatsthis.h> | 29 | #include <qwhatsthis.h> |
30 | #ifndef DESKTOP_VERSION | 30 | #ifndef DESKTOP_VERSION |
31 | #include <qpe/qpeapplication.h> | 31 | #include <qpe/qpeapplication.h> |
32 | #else | 32 | #else |
33 | #include <qapplication.h> | 33 | #include <qapplication.h> |
34 | #endif | 34 | #endif |
35 | 35 | ||
36 | #include <kdebug.h> | 36 | #include <kdebug.h> |
37 | #include <klocale.h> | 37 | #include <klocale.h> |
38 | #include <kglobal.h> | 38 | #include <kglobal.h> |
39 | #include <kconfig.h> | 39 | #include <kconfig.h> |
40 | #include <kiconloader.h> | 40 | #include <kiconloader.h> |
41 | 41 | ||
42 | #include <kcalendarsystem.h> | 42 | #include <kcalendarsystem.h> |
43 | 43 | ||
44 | #ifndef KORG_NOPRINTER | 44 | #ifndef KORG_NOPRINTER |
45 | #include "calprinter.h" | 45 | #include "calprinter.h" |
46 | #endif | 46 | #endif |
47 | #include "koprefs.h" | 47 | #include "koprefs.h" |
48 | #ifndef KORG_NOPLUGINS | 48 | #ifndef KORG_NOPLUGINS |
49 | #include "kocore.h" | 49 | #include "kocore.h" |
50 | #endif | 50 | #endif |
51 | #include "koglobals.h" | 51 | #include "koglobals.h" |
52 | #include <libkdepim/kincidenceformatter.h> | 52 | #include <libkdepim/kincidenceformatter.h> |
53 | 53 | ||
54 | #include "komonthview.h" | 54 | #include "komonthview.h" |
55 | #include "komonthview.moc" | ||
56 | 55 | ||
57 | #define PIXMAP_SIZE 5 | 56 | #define PIXMAP_SIZE 5 |
58 | 57 | ||
59 | class KNOWhatsThis :public QWhatsThis | 58 | class KNOWhatsThis :public QWhatsThis |
60 | { | 59 | { |
61 | public: | 60 | public: |
62 | KNOWhatsThis( KNoScrollListBox* sbox ) : QWhatsThis( sbox ), _wid( sbox) { }; | 61 | KNOWhatsThis( KNoScrollListBox* sbox ) : QWhatsThis( sbox ), _wid( sbox) { }; |
63 | 62 | ||
64 | protected: | 63 | protected: |
65 | virtual QString text( const QPoint& p) | 64 | virtual QString text( const QPoint& p) |
66 | { | 65 | { |
67 | return _wid->getWhatsThisText(p) ; | 66 | return _wid->getWhatsThisText(p) ; |
68 | }; | 67 | }; |
69 | private: | 68 | private: |
70 | KNoScrollListBox* _wid; | 69 | KNoScrollListBox* _wid; |
71 | 70 | ||
72 | }; | 71 | }; |
73 | 72 | ||
74 | 73 | ||
75 | KNoScrollListBox::KNoScrollListBox(QWidget *parent,const char *name) | 74 | KNoScrollListBox::KNoScrollListBox(QWidget *parent,const char *name) |
76 | : QListBox(parent, name) | 75 | : QListBox(parent, name) |
77 | { | 76 | { |
78 | #ifndef DESKTOP_VERSION | 77 | #ifndef DESKTOP_VERSION |
79 | QPEApplication::setStylusOperation( viewport(), QPEApplication::RightOnHold ); | 78 | QPEApplication::setStylusOperation( viewport(), QPEApplication::RightOnHold ); |
80 | #endif | 79 | #endif |
81 | new KNOWhatsThis(this); | 80 | new KNOWhatsThis(this); |
82 | } | 81 | } |
83 | 82 | ||
84 | QString KNoScrollListBox::getWhatsThisText(QPoint p) | 83 | QString KNoScrollListBox::getWhatsThisText(QPoint p) |
85 | { | 84 | { |
86 | QListBoxItem* item = itemAt ( p ); | 85 | QListBoxItem* item = itemAt ( p ); |
87 | if ( ! item ) { | 86 | if ( ! item ) { |
diff --git a/korganizer/koprefsdialog.cpp b/korganizer/koprefsdialog.cpp index 04fffe2..da6644f 100644 --- a/korganizer/koprefsdialog.cpp +++ b/korganizer/koprefsdialog.cpp | |||
@@ -38,65 +38,64 @@ | |||
38 | #include <qdatetime.h> | 38 | #include <qdatetime.h> |
39 | #include <qcheckbox.h> | 39 | #include <qcheckbox.h> |
40 | #include <qradiobutton.h> | 40 | #include <qradiobutton.h> |
41 | #include <qpushbutton.h> | 41 | #include <qpushbutton.h> |
42 | #include <qstrlist.h> | 42 | #include <qstrlist.h> |
43 | #include <qapplication.h> | 43 | #include <qapplication.h> |
44 | 44 | ||
45 | #include <kcolorbutton.h> | 45 | #include <kcolorbutton.h> |
46 | #include <kdebug.h> | 46 | #include <kdebug.h> |
47 | #include <klocale.h> | 47 | #include <klocale.h> |
48 | #include <kglobal.h> | 48 | #include <kglobal.h> |
49 | #include <kfontdialog.h> | 49 | #include <kfontdialog.h> |
50 | #include <kfiledialog.h> | 50 | #include <kfiledialog.h> |
51 | #include <kmessagebox.h> | 51 | #include <kmessagebox.h> |
52 | #include <kcolordialog.h> | 52 | #include <kcolordialog.h> |
53 | #include <kiconloader.h> | 53 | #include <kiconloader.h> |
54 | #include <kemailsettings.h> | 54 | #include <kemailsettings.h> |
55 | #include <kstandarddirs.h> | 55 | #include <kstandarddirs.h> |
56 | 56 | ||
57 | #include <kurlrequester.h> | 57 | #include <kurlrequester.h> |
58 | #include <klineedit.h> | 58 | #include <klineedit.h> |
59 | 59 | ||
60 | #if defined(USE_SOLARIS) | 60 | #if defined(USE_SOLARIS) |
61 | #include <sys/param.h> | 61 | #include <sys/param.h> |
62 | 62 | ||
63 | #define ZONEINFODIR "/usr/share/lib/zoneinfo" | 63 | #define ZONEINFODIR "/usr/share/lib/zoneinfo" |
64 | #define INITFILE "/etc/default/init" | 64 | #define INITFILE "/etc/default/init" |
65 | #endif | 65 | #endif |
66 | 66 | ||
67 | #include "koprefs.h" | 67 | #include "koprefs.h" |
68 | 68 | ||
69 | #include "koprefsdialog.h" | 69 | #include "koprefsdialog.h" |
70 | #include "koprefsdialog.moc" | ||
71 | 70 | ||
72 | 71 | ||
73 | KOPrefsDialog::KOPrefsDialog(QWidget *parent, char *name, bool modal) : | 72 | KOPrefsDialog::KOPrefsDialog(QWidget *parent, char *name, bool modal) : |
74 | KPrefsDialog(KOPrefs::instance(),parent,name,true) | 73 | KPrefsDialog(KOPrefs::instance(),parent,name,true) |
75 | { | 74 | { |
76 | 75 | ||
77 | setCaption( i18n("Preferences - some settings need a restart (nr)")); | 76 | setCaption( i18n("Preferences - some settings need a restart (nr)")); |
78 | mCategoryDict.setAutoDelete(true); | 77 | mCategoryDict.setAutoDelete(true); |
79 | 78 | ||
80 | KGlobal::locale()->insertCatalogue("timezones"); | 79 | KGlobal::locale()->insertCatalogue("timezones"); |
81 | 80 | ||
82 | setupMainTab(); | 81 | setupMainTab(); |
83 | setupLocaleTab(); | 82 | setupLocaleTab(); |
84 | setupTimeZoneTab(); | 83 | setupTimeZoneTab(); |
85 | setupTimeTab(); | 84 | setupTimeTab(); |
86 | setupLocaleDateTab(); | 85 | setupLocaleDateTab(); |
87 | setupFontsTab(); | 86 | setupFontsTab(); |
88 | setupColorsTab(); | 87 | setupColorsTab(); |
89 | setupViewsTab(); | 88 | setupViewsTab(); |
90 | //setupSyncTab(); | 89 | //setupSyncTab(); |
91 | //setupSyncAlgTab(); | 90 | //setupSyncAlgTab(); |
92 | //setupPrinterTab(); | 91 | //setupPrinterTab(); |
93 | //setupGroupSchedulingTab(); | 92 | //setupGroupSchedulingTab(); |
94 | //setupGroupAutomationTab(); | 93 | //setupGroupAutomationTab(); |
95 | } | 94 | } |
96 | 95 | ||
97 | 96 | ||
98 | KOPrefsDialog::~KOPrefsDialog() | 97 | KOPrefsDialog::~KOPrefsDialog() |
99 | { | 98 | { |
100 | } | 99 | } |
101 | 100 | ||
102 | void KOPrefsDialog::setupLocaleDateTab() | 101 | void KOPrefsDialog::setupLocaleDateTab() |
diff --git a/korganizer/kosyncprefsdialog.cpp b/korganizer/kosyncprefsdialog.cpp index 2e051f2..b7e4265 100644 --- a/korganizer/kosyncprefsdialog.cpp +++ b/korganizer/kosyncprefsdialog.cpp | |||
@@ -34,65 +34,64 @@ | |||
34 | #include <qvbox.h> | 34 | #include <qvbox.h> |
35 | #include <qhbox.h> | 35 | #include <qhbox.h> |
36 | #include <qspinbox.h> | 36 | #include <qspinbox.h> |
37 | #include <qdatetime.h> | 37 | #include <qdatetime.h> |
38 | #include <qcheckbox.h> | 38 | #include <qcheckbox.h> |
39 | #include <qradiobutton.h> | 39 | #include <qradiobutton.h> |
40 | #include <qpushbutton.h> | 40 | #include <qpushbutton.h> |
41 | #include <qstrlist.h> | 41 | #include <qstrlist.h> |
42 | #include <qapplication.h> | 42 | #include <qapplication.h> |
43 | 43 | ||
44 | #include <kcolorbutton.h> | 44 | #include <kcolorbutton.h> |
45 | #include <kdebug.h> | 45 | #include <kdebug.h> |
46 | #include <klocale.h> | 46 | #include <klocale.h> |
47 | #include <kglobal.h> | 47 | #include <kglobal.h> |
48 | #include <kfontdialog.h> | 48 | #include <kfontdialog.h> |
49 | #include <kmessagebox.h> | 49 | #include <kmessagebox.h> |
50 | #include <kcolordialog.h> | 50 | #include <kcolordialog.h> |
51 | #include <kiconloader.h> | 51 | #include <kiconloader.h> |
52 | #include <kemailsettings.h> | 52 | #include <kemailsettings.h> |
53 | #include <kstandarddirs.h> | 53 | #include <kstandarddirs.h> |
54 | #include <kfiledialog.h> | 54 | #include <kfiledialog.h> |
55 | #include <kmessagebox.h> | 55 | #include <kmessagebox.h> |
56 | 56 | ||
57 | #include <kurlrequester.h> | 57 | #include <kurlrequester.h> |
58 | #include <klineedit.h> | 58 | #include <klineedit.h> |
59 | #include <libkdepim/ksyncprofile.h> | 59 | #include <libkdepim/ksyncprofile.h> |
60 | 60 | ||
61 | 61 | ||
62 | #include "koprefs.h" | 62 | #include "koprefs.h" |
63 | 63 | ||
64 | #include "kosyncprefsdialog.h" | 64 | #include "kosyncprefsdialog.h" |
65 | #include "koglobals.h" | 65 | #include "koglobals.h" |
66 | #include "kosyncprefsdialog.moc" | ||
67 | 66 | ||
68 | 67 | ||
69 | KOSyncPrefsDialog::KOSyncPrefsDialog(QWidget *parent, char *name, bool modal) : | 68 | KOSyncPrefsDialog::KOSyncPrefsDialog(QWidget *parent, char *name, bool modal) : |
70 | KDialog(parent,name,true) | 69 | KDialog(parent,name,true) |
71 | { | 70 | { |
72 | 71 | ||
73 | setCaption( i18n("Synchronization Preferences")); | 72 | setCaption( i18n("Synchronization Preferences")); |
74 | 73 | ||
75 | mSyncProfiles.setAutoDelete( true ); | 74 | mSyncProfiles.setAutoDelete( true ); |
76 | setupSyncAlgTab(); | 75 | setupSyncAlgTab(); |
77 | } | 76 | } |
78 | 77 | ||
79 | 78 | ||
80 | KOSyncPrefsDialog::~KOSyncPrefsDialog() | 79 | KOSyncPrefsDialog::~KOSyncPrefsDialog() |
81 | { | 80 | { |
82 | } | 81 | } |
83 | 82 | ||
84 | #include <qlayout.h> | 83 | #include <qlayout.h> |
85 | #include <qscrollview.h> | 84 | #include <qscrollview.h> |
86 | void KOSyncPrefsDialog::setupSyncAlgTab() | 85 | void KOSyncPrefsDialog::setupSyncAlgTab() |
87 | { | 86 | { |
88 | QLabel * lab; | 87 | QLabel * lab; |
89 | //QFrame *page = addPage(i18n("Sync Prefs"),0,0); | 88 | //QFrame *page = addPage(i18n("Sync Prefs"),0,0); |
90 | QVBox * mainbox = new QVBox( this ); | 89 | QVBox * mainbox = new QVBox( this ); |
91 | QScrollView* sv = new QScrollView( mainbox ); | 90 | QScrollView* sv = new QScrollView( mainbox ); |
92 | QHBoxLayout * lay = new QHBoxLayout( this ); | 91 | QHBoxLayout * lay = new QHBoxLayout( this ); |
93 | lay->addWidget( mainbox ); | 92 | lay->addWidget( mainbox ); |
94 | QHBox * b_box = new QHBox( mainbox ); | 93 | QHBox * b_box = new QHBox( mainbox ); |
95 | 94 | ||
96 | QPushButton* button = new QPushButton( i18n("Ok"), b_box ); | 95 | QPushButton* button = new QPushButton( i18n("Ok"), b_box ); |
97 | connect ( button, SIGNAL( clicked()), this, SLOT (slotOK() ) ); | 96 | connect ( button, SIGNAL( clicked()), this, SLOT (slotOK() ) ); |
98 | button = new QPushButton( i18n("Cancel"), b_box ); | 97 | button = new QPushButton( i18n("Cancel"), b_box ); |
diff --git a/korganizer/kotimespanview.cpp b/korganizer/kotimespanview.cpp index 266a403..3265a3a 100644 --- a/korganizer/kotimespanview.cpp +++ b/korganizer/kotimespanview.cpp | |||
@@ -1,41 +1,40 @@ | |||
1 | #include <qlayout.h> | 1 | #include <qlayout.h> |
2 | 2 | ||
3 | #include <kconfig.h> | 3 | #include <kconfig.h> |
4 | 4 | ||
5 | #include "timespanview.h" | 5 | #include "timespanview.h" |
6 | #include "koglobals.h" | 6 | #include "koglobals.h" |
7 | 7 | ||
8 | #include "kotimespanview.h" | 8 | #include "kotimespanview.h" |
9 | #include "kotimespanview.moc" | ||
10 | 9 | ||
11 | KOTimeSpanView::KOTimeSpanView(Calendar *calendar, QWidget *parent, | 10 | KOTimeSpanView::KOTimeSpanView(Calendar *calendar, QWidget *parent, |
12 | const char *name) : | 11 | const char *name) : |
13 | KOEventView( calendar, parent, name ) | 12 | KOEventView( calendar, parent, name ) |
14 | { | 13 | { |
15 | QBoxLayout *topLayout = new QVBoxLayout( this ); | 14 | QBoxLayout *topLayout = new QVBoxLayout( this ); |
16 | 15 | ||
17 | mTimeSpanView = new TimeSpanView( this ); | 16 | mTimeSpanView = new TimeSpanView( this ); |
18 | topLayout->addWidget( mTimeSpanView ); | 17 | topLayout->addWidget( mTimeSpanView ); |
19 | 18 | ||
20 | connect( mTimeSpanView, SIGNAL( dateRangeChanged() ), SLOT( updateView() ) ); | 19 | connect( mTimeSpanView, SIGNAL( dateRangeChanged() ), SLOT( updateView() ) ); |
21 | } | 20 | } |
22 | 21 | ||
23 | KOTimeSpanView::~KOTimeSpanView() | 22 | KOTimeSpanView::~KOTimeSpanView() |
24 | { | 23 | { |
25 | } | 24 | } |
26 | 25 | ||
27 | void KOTimeSpanView::readSettings() | 26 | void KOTimeSpanView::readSettings() |
28 | { | 27 | { |
29 | readSettings(KOGlobals::config()); | 28 | readSettings(KOGlobals::config()); |
30 | } | 29 | } |
31 | 30 | ||
32 | void KOTimeSpanView::readSettings(KConfig *config) | 31 | void KOTimeSpanView::readSettings(KConfig *config) |
33 | { | 32 | { |
34 | // kdDebug() << "KOTimeSpanView::readSettings()" << endl; | 33 | // kdDebug() << "KOTimeSpanView::readSettings()" << endl; |
35 | 34 | ||
36 | config->setGroup("Views"); | 35 | config->setGroup("Views"); |
37 | 36 | ||
38 | QValueList<int> sizes = config->readIntListEntry("Separator TimeSpanView"); | 37 | QValueList<int> sizes = config->readIntListEntry("Separator TimeSpanView"); |
39 | if (sizes.count() == 2) { | 38 | if (sizes.count() == 2) { |
40 | mTimeSpanView->setSplitterSizes(sizes); | 39 | mTimeSpanView->setSplitterSizes(sizes); |
41 | } | 40 | } |
diff --git a/korganizer/kotodoeditor.cpp b/korganizer/kotodoeditor.cpp index 1c44f2b..abeb068 100644 --- a/korganizer/kotodoeditor.cpp +++ b/korganizer/kotodoeditor.cpp | |||
@@ -18,65 +18,64 @@ | |||
18 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 18 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
19 | 19 | ||
20 | As a special exception, permission is given to link this program | 20 | As a special exception, permission is given to link this program |
21 | with any edition of Qt, and distribute the resulting executable, | 21 | with any edition of Qt, and distribute the resulting executable, |
22 | without including the source code for Qt in the source distribution. | 22 | without including the source code for Qt in the source distribution. |
23 | */ | 23 | */ |
24 | 24 | ||
25 | #include <qtooltip.h> | 25 | #include <qtooltip.h> |
26 | #include <qframe.h> | 26 | #include <qframe.h> |
27 | #include <qpixmap.h> | 27 | #include <qpixmap.h> |
28 | #include <qlayout.h> | 28 | #include <qlayout.h> |
29 | #include <qhbox.h> | 29 | #include <qhbox.h> |
30 | #include <qdir.h> | 30 | #include <qdir.h> |
31 | #include <qdatetime.h> | 31 | #include <qdatetime.h> |
32 | #include <qapplication.h> | 32 | #include <qapplication.h> |
33 | 33 | ||
34 | #include <kiconloader.h> | 34 | #include <kiconloader.h> |
35 | #include <klocale.h> | 35 | #include <klocale.h> |
36 | #include <kfiledialog.h> | 36 | #include <kfiledialog.h> |
37 | #include <kstandarddirs.h> | 37 | #include <kstandarddirs.h> |
38 | #include <kmessagebox.h> | 38 | #include <kmessagebox.h> |
39 | 39 | ||
40 | #include <libkdepim/categoryselectdialog.h> | 40 | #include <libkdepim/categoryselectdialog.h> |
41 | #include <libkcal/calendarlocal.h> | 41 | #include <libkcal/calendarlocal.h> |
42 | #include <libkcal/calendarresources.h> | 42 | #include <libkcal/calendarresources.h> |
43 | #include <libkcal/resourcecalendar.h> | 43 | #include <libkcal/resourcecalendar.h> |
44 | #include <libkcal/icalformat.h> | 44 | #include <libkcal/icalformat.h> |
45 | #include <kresources/resourceselectdialog.h> | 45 | #include <kresources/resourceselectdialog.h> |
46 | 46 | ||
47 | #include "koprefs.h" | 47 | #include "koprefs.h" |
48 | 48 | ||
49 | #include "kotodoeditor.h" | 49 | #include "kotodoeditor.h" |
50 | #include "kotodoeditor.moc" | ||
51 | extern int globalFlagBlockAgenda; | 50 | extern int globalFlagBlockAgenda; |
52 | 51 | ||
53 | KOTodoEditor::KOTodoEditor( Calendar *calendar, QWidget *parent ) : | 52 | KOTodoEditor::KOTodoEditor( Calendar *calendar, QWidget *parent ) : |
54 | KOIncidenceEditor( i18n("Edit To-Do"), calendar, parent ) | 53 | KOIncidenceEditor( i18n("Edit To-Do"), calendar, parent ) |
55 | { | 54 | { |
56 | mTodo = 0; | 55 | mTodo = 0; |
57 | mRelatedTodo = 0; | 56 | mRelatedTodo = 0; |
58 | findButton(User1)->hide(); | 57 | findButton(User1)->hide(); |
59 | init(); | 58 | init(); |
60 | } | 59 | } |
61 | 60 | ||
62 | KOTodoEditor::~KOTodoEditor() | 61 | KOTodoEditor::~KOTodoEditor() |
63 | { | 62 | { |
64 | emit dialogClose( mTodo ); | 63 | emit dialogClose( mTodo ); |
65 | } | 64 | } |
66 | 65 | ||
67 | void KOTodoEditor::init() | 66 | void KOTodoEditor::init() |
68 | { | 67 | { |
69 | setupGeneral(); | 68 | setupGeneral(); |
70 | setupAttendeesTab(); | 69 | setupAttendeesTab(); |
71 | } | 70 | } |
72 | void KOTodoEditor::setCategories( QString s ) | 71 | void KOTodoEditor::setCategories( QString s ) |
73 | { | 72 | { |
74 | mGeneral->setCategories(s); | 73 | mGeneral->setCategories(s); |
75 | } | 74 | } |
76 | void KOTodoEditor::setSecrecy( int sec ) | 75 | void KOTodoEditor::setSecrecy( int sec ) |
77 | { | 76 | { |
78 | mGeneral->setSecrecy( sec ); | 77 | mGeneral->setSecrecy( sec ); |
79 | } | 78 | } |
80 | void KOTodoEditor::reload() | 79 | void KOTodoEditor::reload() |
81 | { | 80 | { |
82 | if ( mTodo ) readTodo( mTodo ); | 81 | if ( mTodo ) readTodo( mTodo ); |
diff --git a/korganizer/kotodoview.cpp b/korganizer/kotodoview.cpp index 0708a69..d9e0a03 100644 --- a/korganizer/kotodoview.cpp +++ b/korganizer/kotodoview.cpp | |||
@@ -23,65 +23,64 @@ | |||
23 | 23 | ||
24 | #include <qlayout.h> | 24 | #include <qlayout.h> |
25 | #include <qheader.h> | 25 | #include <qheader.h> |
26 | #include <qcursor.h> | 26 | #include <qcursor.h> |
27 | 27 | ||
28 | #include <qvbox.h> | 28 | #include <qvbox.h> |
29 | #include <kdebug.h> | 29 | #include <kdebug.h> |
30 | #include "koprefs.h" | 30 | #include "koprefs.h" |
31 | #include <klocale.h> | 31 | #include <klocale.h> |
32 | #include <kglobal.h> | 32 | #include <kglobal.h> |
33 | #include <kiconloader.h> | 33 | #include <kiconloader.h> |
34 | #include <kmessagebox.h> | 34 | #include <kmessagebox.h> |
35 | 35 | ||
36 | #include <libkcal/icaldrag.h> | 36 | #include <libkcal/icaldrag.h> |
37 | #include <libkcal/vcaldrag.h> | 37 | #include <libkcal/vcaldrag.h> |
38 | #include <libkcal/calfilter.h> | 38 | #include <libkcal/calfilter.h> |
39 | #include <libkcal/dndfactory.h> | 39 | #include <libkcal/dndfactory.h> |
40 | #include <libkcal/calendarresources.h> | 40 | #include <libkcal/calendarresources.h> |
41 | #include <libkcal/resourcecalendar.h> | 41 | #include <libkcal/resourcecalendar.h> |
42 | #include <kresources/resourceselectdialog.h> | 42 | #include <kresources/resourceselectdialog.h> |
43 | #ifndef DESKTOP_VERSION | 43 | #ifndef DESKTOP_VERSION |
44 | #include <qpe/qpeapplication.h> | 44 | #include <qpe/qpeapplication.h> |
45 | #else | 45 | #else |
46 | #include <qapplication.h> | 46 | #include <qapplication.h> |
47 | #endif | 47 | #endif |
48 | #ifndef KORG_NOPRINTER | 48 | #ifndef KORG_NOPRINTER |
49 | #include "calprinter.h" | 49 | #include "calprinter.h" |
50 | #endif | 50 | #endif |
51 | #include "docprefs.h" | 51 | #include "docprefs.h" |
52 | 52 | ||
53 | #include "kotodoview.h" | 53 | #include "kotodoview.h" |
54 | using namespace KOrg; | 54 | using namespace KOrg; |
55 | #include "kotodoview.moc" | ||
56 | 55 | ||
57 | KOTodoListView::KOTodoListView(Calendar *calendar,QWidget *parent, | 56 | KOTodoListView::KOTodoListView(Calendar *calendar,QWidget *parent, |
58 | const char *name) : | 57 | const char *name) : |
59 | KListView(parent,name) | 58 | KListView(parent,name) |
60 | { | 59 | { |
61 | mCalendar = calendar; | 60 | mCalendar = calendar; |
62 | #ifndef DESKTOP_VERSION | 61 | #ifndef DESKTOP_VERSION |
63 | QPEApplication::setStylusOperation(viewport(), QPEApplication::RightOnHold ); | 62 | QPEApplication::setStylusOperation(viewport(), QPEApplication::RightOnHold ); |
64 | #endif | 63 | #endif |
65 | mOldCurrent = 0; | 64 | mOldCurrent = 0; |
66 | mMousePressed = false; | 65 | mMousePressed = false; |
67 | 66 | ||
68 | setAcceptDrops(true); | 67 | setAcceptDrops(true); |
69 | viewport()->setAcceptDrops(true); | 68 | viewport()->setAcceptDrops(true); |
70 | int size = 16; | 69 | int size = 16; |
71 | if (qApp->desktop()->width() < 300 ) | 70 | if (qApp->desktop()->width() < 300 ) |
72 | size = 12; | 71 | size = 12; |
73 | setTreeStepSize( size + 6 ); | 72 | setTreeStepSize( size + 6 ); |
74 | 73 | ||
75 | } | 74 | } |
76 | 75 | ||
77 | void KOTodoListView::contentsDragEnterEvent(QDragEnterEvent *e) | 76 | void KOTodoListView::contentsDragEnterEvent(QDragEnterEvent *e) |
78 | { | 77 | { |
79 | #ifndef KORG_NODND | 78 | #ifndef KORG_NODND |
80 | // kdDebug() << "KOTodoListView::contentsDragEnterEvent" << endl; | 79 | // kdDebug() << "KOTodoListView::contentsDragEnterEvent" << endl; |
81 | if ( !ICalDrag::canDecode( e ) && !VCalDrag::canDecode( e ) && | 80 | if ( !ICalDrag::canDecode( e ) && !VCalDrag::canDecode( e ) && |
82 | !QTextDrag::canDecode( e ) ) { | 81 | !QTextDrag::canDecode( e ) ) { |
83 | e->ignore(); | 82 | e->ignore(); |
84 | return; | 83 | return; |
85 | } | 84 | } |
86 | 85 | ||
87 | mOldCurrent = currentItem(); | 86 | mOldCurrent = currentItem(); |
diff --git a/korganizer/koviewmanager.cpp b/korganizer/koviewmanager.cpp index 88d69c6..fc2bc77 100644 --- a/korganizer/koviewmanager.cpp +++ b/korganizer/koviewmanager.cpp | |||
@@ -17,65 +17,64 @@ | |||
17 | You should have received a copy of the GNU General Public License | 17 | You should have received a copy of the GNU General Public License |
18 | along with this program; if not, write to the Free Software | 18 | along with this program; if not, write to the Free Software |
19 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 19 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
20 | 20 | ||
21 | As a special exception, permission is given to link this program | 21 | As a special exception, permission is given to link this program |
22 | with any edition of Qt, and distribute the resulting executable, | 22 | with any edition of Qt, and distribute the resulting executable, |
23 | without including the source code for Qt in the source distribution. | 23 | without including the source code for Qt in the source distribution. |
24 | */ | 24 | */ |
25 | 25 | ||
26 | #include <qwidgetstack.h> | 26 | #include <qwidgetstack.h> |
27 | 27 | ||
28 | #include <kconfig.h> | 28 | #include <kconfig.h> |
29 | #include <kglobal.h> | 29 | #include <kglobal.h> |
30 | #ifndef DESKTOP_VERSION | 30 | #ifndef DESKTOP_VERSION |
31 | #include <qpe/qpeapplication.h> | 31 | #include <qpe/qpeapplication.h> |
32 | #else | 32 | #else |
33 | #include <qapplication.h> | 33 | #include <qapplication.h> |
34 | #endif | 34 | #endif |
35 | #include "calendarview.h" | 35 | #include "calendarview.h" |
36 | #include "datenavigator.h" | 36 | #include "datenavigator.h" |
37 | #include "kotodoview.h" | 37 | #include "kotodoview.h" |
38 | #include "koagendaview.h" | 38 | #include "koagendaview.h" |
39 | #include "kodialogmanager.h" | 39 | #include "kodialogmanager.h" |
40 | #include "komonthview.h" | 40 | #include "komonthview.h" |
41 | #include "kolistview.h" | 41 | #include "kolistview.h" |
42 | #include "kowhatsnextview.h" | 42 | #include "kowhatsnextview.h" |
43 | #include "kojournalview.h" | 43 | #include "kojournalview.h" |
44 | #include "kotimespanview.h" | 44 | #include "kotimespanview.h" |
45 | #include "koprefs.h" | 45 | #include "koprefs.h" |
46 | #include "navigatorbar.h" | 46 | #include "navigatorbar.h" |
47 | 47 | ||
48 | #include "koviewmanager.h" | 48 | #include "koviewmanager.h" |
49 | #include "koviewmanager.moc" | ||
50 | //extern bool externFlagMonthviewBlockPainting; | 49 | //extern bool externFlagMonthviewBlockPainting; |
51 | 50 | ||
52 | //bool globalFlagBlockPainting = false; | 51 | //bool globalFlagBlockPainting = false; |
53 | int globalFlagBlockAgenda = 0; | 52 | int globalFlagBlockAgenda = 0; |
54 | int globalFlagBlockLabel = 0; | 53 | int globalFlagBlockLabel = 0; |
55 | int globalFlagBlockAgendaItemPaint = 1; | 54 | int globalFlagBlockAgendaItemPaint = 1; |
56 | int globalFlagBlockAgendaItemUpdate = 1; | 55 | int globalFlagBlockAgendaItemUpdate = 1; |
57 | 56 | ||
58 | 57 | ||
59 | KOViewManager::KOViewManager( CalendarView *mainView ) : | 58 | KOViewManager::KOViewManager( CalendarView *mainView ) : |
60 | QObject(), mMainView( mainView ) | 59 | QObject(), mMainView( mainView ) |
61 | { | 60 | { |
62 | mCurrentView = 0; | 61 | mCurrentView = 0; |
63 | 62 | ||
64 | mWhatsNextView = 0; | 63 | mWhatsNextView = 0; |
65 | mTodoView = 0; | 64 | mTodoView = 0; |
66 | mAgendaView = 0; | 65 | mAgendaView = 0; |
67 | mMonthView = 0; | 66 | mMonthView = 0; |
68 | mListView = 0; | 67 | mListView = 0; |
69 | mJournalView = 0; | 68 | mJournalView = 0; |
70 | mTimeSpanView = 0; | 69 | mTimeSpanView = 0; |
71 | mCurrentAgendaView = 0 ; | 70 | mCurrentAgendaView = 0 ; |
72 | mFlagShowNextxDays = false; | 71 | mFlagShowNextxDays = false; |
73 | } | 72 | } |
74 | 73 | ||
75 | KOViewManager::~KOViewManager() | 74 | KOViewManager::~KOViewManager() |
76 | { | 75 | { |
77 | } | 76 | } |
78 | 77 | ||
79 | 78 | ||
80 | KOrg::BaseView *KOViewManager::currentView() | 79 | KOrg::BaseView *KOViewManager::currentView() |
81 | { | 80 | { |
diff --git a/korganizer/kowhatsnextview.cpp b/korganizer/kowhatsnextview.cpp index ffaea37..0547a2e 100644 --- a/korganizer/kowhatsnextview.cpp +++ b/korganizer/kowhatsnextview.cpp | |||
@@ -13,65 +13,64 @@ | |||
13 | GNU General Public License for more details. | 13 | GNU General Public License for more details. |
14 | 14 | ||
15 | You should have received a copy of the GNU General Public License | 15 | You should have received a copy of the GNU General Public License |
16 | along with this program; if not, write to the Free Software | 16 | along with this program; if not, write to the Free Software |
17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
18 | */ | 18 | */ |
19 | 19 | ||
20 | #include <qlayout.h> | 20 | #include <qlayout.h> |
21 | #include <qtextbrowser.h> | 21 | #include <qtextbrowser.h> |
22 | #include <qtextcodec.h> | 22 | #include <qtextcodec.h> |
23 | #include <qfileinfo.h> | 23 | #include <qfileinfo.h> |
24 | #include <qlabel.h> | 24 | #include <qlabel.h> |
25 | 25 | ||
26 | #include <qapplication.h> | 26 | #include <qapplication.h> |
27 | 27 | ||
28 | #include <kglobal.h> | 28 | #include <kglobal.h> |
29 | #include <klocale.h> | 29 | #include <klocale.h> |
30 | #include <kdebug.h> | 30 | #include <kdebug.h> |
31 | #include <kiconloader.h> | 31 | #include <kiconloader.h> |
32 | #include <kmessagebox.h> | 32 | #include <kmessagebox.h> |
33 | 33 | ||
34 | #include <libkcal/calendar.h> | 34 | #include <libkcal/calendar.h> |
35 | 35 | ||
36 | #ifndef KORG_NOPRINTER | 36 | #ifndef KORG_NOPRINTER |
37 | #include "calprinter.h" | 37 | #include "calprinter.h" |
38 | #endif | 38 | #endif |
39 | #include "koglobals.h" | 39 | #include "koglobals.h" |
40 | #include "koprefs.h" | 40 | #include "koprefs.h" |
41 | #include "koeventviewerdialog.h" | 41 | #include "koeventviewerdialog.h" |
42 | 42 | ||
43 | #include "kowhatsnextview.h" | 43 | #include "kowhatsnextview.h" |
44 | using namespace KOrg; | 44 | using namespace KOrg; |
45 | #include "kowhatsnextview.moc" | ||
46 | 45 | ||
47 | void WhatsNextTextBrowser::setSource(const QString& n) | 46 | void WhatsNextTextBrowser::setSource(const QString& n) |
48 | { | 47 | { |
49 | 48 | ||
50 | if (n.startsWith("event:")) { | 49 | if (n.startsWith("event:")) { |
51 | emit showIncidence(n); | 50 | emit showIncidence(n); |
52 | return; | 51 | return; |
53 | } else if (n.startsWith("todo:")) { | 52 | } else if (n.startsWith("todo:")) { |
54 | emit showIncidence(n); | 53 | emit showIncidence(n); |
55 | return; | 54 | return; |
56 | } else { | 55 | } else { |
57 | QTextBrowser::setSource(n); | 56 | QTextBrowser::setSource(n); |
58 | } | 57 | } |
59 | } | 58 | } |
60 | 59 | ||
61 | KOWhatsNextView::KOWhatsNextView(Calendar *calendar, QWidget *parent, | 60 | KOWhatsNextView::KOWhatsNextView(Calendar *calendar, QWidget *parent, |
62 | const char *name) | 61 | const char *name) |
63 | : KOrg::BaseView(calendar, parent, name) | 62 | : KOrg::BaseView(calendar, parent, name) |
64 | { | 63 | { |
65 | // mDateLabel = | 64 | // mDateLabel = |
66 | // new QLabel(KGlobal::locale()->formatDate(QDate::currentDate()),this); | 65 | // new QLabel(KGlobal::locale()->formatDate(QDate::currentDate()),this); |
67 | // mDateLabel->setMargin(2); | 66 | // mDateLabel->setMargin(2); |
68 | // mDateLabel->setAlignment(AlignCenter); | 67 | // mDateLabel->setAlignment(AlignCenter); |
69 | setFont( KOPrefs::instance()->mWhatsNextFont ); | 68 | setFont( KOPrefs::instance()->mWhatsNextFont ); |
70 | mView = new WhatsNextTextBrowser(this); | 69 | mView = new WhatsNextTextBrowser(this); |
71 | connect(mView,SIGNAL(showIncidence(const QString &)),SLOT(showIncidence(const QString &))); | 70 | connect(mView,SIGNAL(showIncidence(const QString &)),SLOT(showIncidence(const QString &))); |
72 | 71 | ||
73 | mEventViewer = 0; | 72 | mEventViewer = 0; |
74 | 73 | ||
75 | QBoxLayout *topLayout = new QVBoxLayout(this); | 74 | QBoxLayout *topLayout = new QVBoxLayout(this); |
76 | // topLayout->addWidget(mDateLabel); | 75 | // topLayout->addWidget(mDateLabel); |
77 | topLayout->addWidget(mView); | 76 | topLayout->addWidget(mView); |
diff --git a/korganizer/ktimeedit.cpp b/korganizer/ktimeedit.cpp index f9720f6..cf07a1a 100644 --- a/korganizer/ktimeedit.cpp +++ b/korganizer/ktimeedit.cpp | |||
@@ -6,65 +6,64 @@ | |||
6 | it under the terms of the GNU General Public License as published by | 6 | it under the terms of the GNU General Public License as published by |
7 | the Free Software Foundation; either version 2 of the License, or | 7 | the Free Software Foundation; either version 2 of the License, or |
8 | (at your option) any later version. | 8 | (at your option) any later version. |
9 | 9 | ||
10 | This program is distributed in the hope that it will be useful, | 10 | This program is distributed in the hope that it will be useful, |
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
13 | GNU General Public License for more details. | 13 | GNU General Public License for more details. |
14 | 14 | ||
15 | You should have received a copy of the GNU General Public License | 15 | You should have received a copy of the GNU General Public License |
16 | along with this program; if not, write to the Free Software | 16 | along with this program; if not, write to the Free Software |
17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
18 | 18 | ||
19 | As a special exception, permission is given to link this program | 19 | As a special exception, permission is given to link this program |
20 | with any edition of Qt, and distribute the resulting executable, | 20 | with any edition of Qt, and distribute the resulting executable, |
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 <qkeycode.h> | 24 | #include <qkeycode.h> |
25 | #include <qcombobox.h> | 25 | #include <qcombobox.h> |
26 | #include <qdatetime.h> | 26 | #include <qdatetime.h> |
27 | #include <qlineedit.h> | 27 | #include <qlineedit.h> |
28 | #include <qapplication.h> | 28 | #include <qapplication.h> |
29 | 29 | ||
30 | #include <kmessagebox.h> | 30 | #include <kmessagebox.h> |
31 | #include <kglobal.h> | 31 | #include <kglobal.h> |
32 | #include <kdebug.h> | 32 | #include <kdebug.h> |
33 | #include <klocale.h> | 33 | #include <klocale.h> |
34 | 34 | ||
35 | #include "ktimeedit.h" | 35 | #include "ktimeedit.h" |
36 | #include "koprefs.h" | 36 | #include "koprefs.h" |
37 | #include <qvalidator.h> | 37 | #include <qvalidator.h> |
38 | #include "ktimeedit.moc" | ||
39 | 38 | ||
40 | // Validator for a time value with only hours and minutes (no seconds) | 39 | // Validator for a time value with only hours and minutes (no seconds) |
41 | // Mostly locale aware. Author: David Faure <faure@kde.org> | 40 | // Mostly locale aware. Author: David Faure <faure@kde.org> |
42 | class KOTimeValidator : public QValidator | 41 | class KOTimeValidator : public QValidator |
43 | { | 42 | { |
44 | public: | 43 | public: |
45 | KOTimeValidator(QWidget* parent, const char* name=0) : QValidator(parent, name) {} | 44 | KOTimeValidator(QWidget* parent, const char* name=0) : QValidator(parent, name) {} |
46 | 45 | ||
47 | virtual State validate(QString& str, int& /*cursorPos*/) const | 46 | virtual State validate(QString& str, int& /*cursorPos*/) const |
48 | { | 47 | { |
49 | return Acceptable; | 48 | return Acceptable; |
50 | bool ok = false; | 49 | bool ok = false; |
51 | // TODO use KLocale::WithoutSeconds in HEAD | 50 | // TODO use KLocale::WithoutSeconds in HEAD |
52 | /*QTime time =*/ KGlobal::locale()->readTime(str, &ok); | 51 | /*QTime time =*/ KGlobal::locale()->readTime(str, &ok); |
53 | if ( ok ) | 52 | if ( ok ) |
54 | return Acceptable; | 53 | return Acceptable; |
55 | // readTime doesn't help knowing when the string is "Intermediate". | 54 | // readTime doesn't help knowing when the string is "Intermediate". |
56 | int length = str.length(); | 55 | int length = str.length(); |
57 | if ( !str ) // empty string? | 56 | if ( !str ) // empty string? |
58 | return Invalid; // there should always be a ':' in it, right? | 57 | return Invalid; // there should always be a ':' in it, right? |
59 | // HACK. Not fully locale aware etc. (esp. the separator is '.' in sv_SE...) | 58 | // HACK. Not fully locale aware etc. (esp. the separator is '.' in sv_SE...) |
60 | QChar sep = ':'; | 59 | QChar sep = ':'; |
61 | // I want to allow "HH:", ":MM" and ":" to make editing easier | 60 | // I want to allow "HH:", ":MM" and ":" to make editing easier |
62 | if ( str[0] == sep ) | 61 | if ( str[0] == sep ) |
63 | { | 62 | { |
64 | if ( length == 1 ) // just ":" | 63 | if ( length == 1 ) // just ":" |
65 | return Intermediate; | 64 | return Intermediate; |
66 | QString minutes = str.mid(1); | 65 | QString minutes = str.mid(1); |
67 | int m = minutes.toInt(&ok); | 66 | int m = minutes.toInt(&ok); |
68 | if ( ok && m >= 0 && m < 60 ) | 67 | if ( ok && m >= 0 && m < 60 ) |
69 | return Intermediate; | 68 | return Intermediate; |
70 | } else if ( str.at(str.length()-1) == sep ) | 69 | } else if ( str.at(str.length()-1) == sep ) |
diff --git a/korganizer/lineview.cpp b/korganizer/lineview.cpp index f1ff29f..e72e41c 100644 --- a/korganizer/lineview.cpp +++ b/korganizer/lineview.cpp | |||
@@ -1,40 +1,39 @@ | |||
1 | #include <qpainter.h> | 1 | #include <qpainter.h> |
2 | 2 | ||
3 | #include <kdebug.h> | 3 | #include <kdebug.h> |
4 | 4 | ||
5 | #include "koprefs.h" | 5 | #include "koprefs.h" |
6 | 6 | ||
7 | #include "lineview.h" | 7 | #include "lineview.h" |
8 | #include "lineview.moc" | ||
9 | 8 | ||
10 | LineView::LineView( QWidget *parent, const char *name ) : | 9 | LineView::LineView( QWidget *parent, const char *name ) : |
11 | QScrollView( parent, name ) | 10 | QScrollView( parent, name ) |
12 | { | 11 | { |
13 | mPixelWidth = 1000; | 12 | mPixelWidth = 1000; |
14 | 13 | ||
15 | mLines.setAutoDelete( true ); | 14 | mLines.setAutoDelete( true ); |
16 | 15 | ||
17 | resizeContents( mPixelWidth, contentsHeight() ); | 16 | resizeContents( mPixelWidth, contentsHeight() ); |
18 | 17 | ||
19 | viewport()->setBackgroundColor(KOPrefs::instance()->mAgendaBgColor); | 18 | viewport()->setBackgroundColor(KOPrefs::instance()->mAgendaBgColor); |
20 | } | 19 | } |
21 | 20 | ||
22 | LineView::~LineView() | 21 | LineView::~LineView() |
23 | { | 22 | { |
24 | } | 23 | } |
25 | 24 | ||
26 | int LineView::pixelWidth() | 25 | int LineView::pixelWidth() |
27 | { | 26 | { |
28 | return mPixelWidth; | 27 | return mPixelWidth; |
29 | } | 28 | } |
30 | 29 | ||
31 | void LineView::addLine( int start, int end ) | 30 | void LineView::addLine( int start, int end ) |
32 | { | 31 | { |
33 | int count = mLines.count(); | 32 | int count = mLines.count(); |
34 | 33 | ||
35 | if( start < 0 ) start = 0; | 34 | if( start < 0 ) start = 0; |
36 | if( end > mPixelWidth) end = mPixelWidth; | 35 | if( end > mPixelWidth) end = mPixelWidth; |
37 | 36 | ||
38 | kdDebug() << "LineView::addLine() col: " << count << " start: " << start | 37 | kdDebug() << "LineView::addLine() col: " << count << " start: " << start |
39 | << " end: " << end << endl; | 38 | << " end: " << end << endl; |
40 | 39 | ||
diff --git a/korganizer/navigatorbar.cpp b/korganizer/navigatorbar.cpp index 1052a99..f339c67 100644 --- a/korganizer/navigatorbar.cpp +++ b/korganizer/navigatorbar.cpp | |||
@@ -167,33 +167,32 @@ void NavigatorBar::selectMonth() | |||
167 | if ( QApplication::desktop()->width() >= 480 ) | 167 | if ( QApplication::desktop()->width() >= 480 ) |
168 | size = 18; | 168 | size = 18; |
169 | KDateInternalMonthPicker* picker = new KDateInternalMonthPicker(size, popup); | 169 | KDateInternalMonthPicker* picker = new KDateInternalMonthPicker(size, popup); |
170 | // ----- | 170 | // ----- |
171 | picker->resize(picker->sizeHint()); | 171 | picker->resize(picker->sizeHint()); |
172 | popup->setMainWidget(picker); | 172 | popup->setMainWidget(picker); |
173 | picker->setFocus(); | 173 | picker->setFocus(); |
174 | connect(picker, SIGNAL(closeMe(int)), popup, SLOT(close(int))); | 174 | connect(picker, SIGNAL(closeMe(int)), popup, SLOT(close(int))); |
175 | if(popup->exec(mSelectMonth->mapToGlobal(QPoint(0, mSelectMonth->height())))) | 175 | if(popup->exec(mSelectMonth->mapToGlobal(QPoint(0, mSelectMonth->height())))) |
176 | { | 176 | { |
177 | month = picker->getResult(); | 177 | month = picker->getResult(); |
178 | emit monthSelected ( month ); | 178 | emit monthSelected ( month ); |
179 | } else { | 179 | } else { |
180 | KNotifyClient::beep(); | 180 | KNotifyClient::beep(); |
181 | } | 181 | } |
182 | delete popup; | 182 | delete popup; |
183 | } | 183 | } |
184 | void NavigatorBar::selectDates( const KCal::DateList &dateList ) | 184 | void NavigatorBar::selectDates( const KCal::DateList &dateList ) |
185 | { | 185 | { |
186 | if (dateList.count() > 0) { | 186 | if (dateList.count() > 0) { |
187 | QDate date = dateList.first(); | 187 | QDate date = dateList.first(); |
188 | 188 | ||
189 | const KCalendarSystem *calSys = KOGlobals::self()->calendarSystem(); | 189 | const KCalendarSystem *calSys = KOGlobals::self()->calendarSystem(); |
190 | 190 | ||
191 | // compute the label at the top of the navigator | 191 | // compute the label at the top of the navigator |
192 | QString dtstr = i18n(calSys->monthName( date )) + " '" + | 192 | QString dtstr = i18n(calSys->monthName( date )) + " '" + |
193 | QString::number( calSys->year( date ) ).right(2); | 193 | QString::number( calSys->year( date ) ).right(2); |
194 | 194 | ||
195 | mSelectMonth->setText( dtstr ); | 195 | mSelectMonth->setText( dtstr ); |
196 | } | 196 | } |
197 | } | 197 | } |
198 | 198 | ||
199 | #include "navigatorbar.moc" | ||
diff --git a/korganizer/outgoingdialog.cpp b/korganizer/outgoingdialog.cpp index 4eb64f3..0fc90c4 100644 --- a/korganizer/outgoingdialog.cpp +++ b/korganizer/outgoingdialog.cpp | |||
@@ -362,33 +362,32 @@ void OutgoingDialog::loadMessages() | |||
362 | bool inserted = false; | 362 | bool inserted = false; |
363 | QMap<IncidenceBase*, QString>::Iterator iter; | 363 | QMap<IncidenceBase*, QString>::Iterator iter; |
364 | for ( iter = mMessageMap.begin(); iter != mMessageMap.end(); ++iter ) { | 364 | for ( iter = mMessageMap.begin(); iter != mMessageMap.end(); ++iter ) { |
365 | if (iter.data() == outgoingDirName + "/" + (*it)) inserted = true; | 365 | if (iter.data() == outgoingDirName + "/" + (*it)) inserted = true; |
366 | } | 366 | } |
367 | if (!inserted) { | 367 | if (!inserted) { |
368 | kdDebug() << "OutgoingDialog::loadMessage(): got message '" | 368 | kdDebug() << "OutgoingDialog::loadMessage(): got message '" |
369 | << (*it) << "'" << endl; | 369 | << (*it) << "'" << endl; |
370 | IncidenceBase *inc = message->event(); | 370 | IncidenceBase *inc = message->event(); |
371 | new ScheduleItemOut(mMessageListView,inc,method,recipients); | 371 | new ScheduleItemOut(mMessageListView,inc,method,recipients); |
372 | mMessageMap[message->event()]=outgoingDirName + "/" + (*it); | 372 | mMessageMap[message->event()]=outgoingDirName + "/" + (*it); |
373 | } | 373 | } |
374 | } else { | 374 | } else { |
375 | QString errorMessage; | 375 | QString errorMessage; |
376 | if (mFormat->exception()) { | 376 | if (mFormat->exception()) { |
377 | errorMessage = mFormat->exception()->message(); | 377 | errorMessage = mFormat->exception()->message(); |
378 | } | 378 | } |
379 | kdDebug() << "OutgoingDialog::loadMessage(): Error parsing " | 379 | kdDebug() << "OutgoingDialog::loadMessage(): Error parsing " |
380 | "message: " << errorMessage << endl; | 380 | "message: " << errorMessage << endl; |
381 | } | 381 | } |
382 | f.close(); | 382 | f.close(); |
383 | } | 383 | } |
384 | } | 384 | } |
385 | } | 385 | } |
386 | emit numMessagesChanged(mMessageListView->childCount()); | 386 | emit numMessagesChanged(mMessageListView->childCount()); |
387 | } | 387 | } |
388 | 388 | ||
389 | void OutgoingDialog::setDocumentId( const QString &id ) | 389 | void OutgoingDialog::setDocumentId( const QString &id ) |
390 | { | 390 | { |
391 | mDocPrefs->setDoc( id ); | 391 | mDocPrefs->setDoc( id ); |
392 | } | 392 | } |
393 | 393 | ||
394 | #include "outgoingdialog.moc" | ||
diff --git a/korganizer/outgoingdialog_base.cpp b/korganizer/outgoingdialog_base.cpp index e5b913a..1873b44 100644 --- a/korganizer/outgoingdialog_base.cpp +++ b/korganizer/outgoingdialog_base.cpp | |||
@@ -76,34 +76,32 @@ OutgoingDialog_base::OutgoingDialog_base( QWidget* parent, const char* name, boo | |||
76 | OutgoingDialog_base::~OutgoingDialog_base() | 76 | OutgoingDialog_base::~OutgoingDialog_base() |
77 | { | 77 | { |
78 | // no need to delete child widgets, Qt does it all for us | 78 | // no need to delete child widgets, Qt does it all for us |
79 | } | 79 | } |
80 | 80 | ||
81 | /* | 81 | /* |
82 | * Sets the strings of the subwidgets using the current | 82 | * Sets the strings of the subwidgets using the current |
83 | * language. | 83 | * language. |
84 | */ | 84 | */ |
85 | void OutgoingDialog_base::languageChange() | 85 | void OutgoingDialog_base::languageChange() |
86 | { | 86 | { |
87 | setCaption( tr2i18n( "Scheduler - Outgoing Messages" ) ); | 87 | setCaption( tr2i18n( "Scheduler - Outgoing Messages" ) ); |
88 | mMessageListView->header()->setLabel( 0, tr2i18n( "Summary" ) ); | 88 | mMessageListView->header()->setLabel( 0, tr2i18n( "Summary" ) ); |
89 | mMessageListView->header()->setLabel( 1, tr2i18n( "Start Date" ) ); | 89 | mMessageListView->header()->setLabel( 1, tr2i18n( "Start Date" ) ); |
90 | mMessageListView->header()->setLabel( 2, tr2i18n( "Start Time" ) ); | 90 | mMessageListView->header()->setLabel( 2, tr2i18n( "Start Time" ) ); |
91 | mMessageListView->header()->setLabel( 3, tr2i18n( "End Date" ) ); | 91 | mMessageListView->header()->setLabel( 3, tr2i18n( "End Date" ) ); |
92 | mMessageListView->header()->setLabel( 4, tr2i18n( "End Time" ) ); | 92 | mMessageListView->header()->setLabel( 4, tr2i18n( "End Time" ) ); |
93 | mMessageListView->header()->setLabel( 5, tr2i18n( "Method" ) ); | 93 | mMessageListView->header()->setLabel( 5, tr2i18n( "Method" ) ); |
94 | PushButton5->setText( tr2i18n( "&Send Messages" ) ); | 94 | PushButton5->setText( tr2i18n( "&Send Messages" ) ); |
95 | PushButton7->setText( tr2i18n( "&Remove" ) ); | 95 | PushButton7->setText( tr2i18n( "&Remove" ) ); |
96 | PushButton6->setText( tr2i18n( "&Close" ) ); | 96 | PushButton6->setText( tr2i18n( "&Close" ) ); |
97 | } | 97 | } |
98 | 98 | ||
99 | void OutgoingDialog_base::send() | 99 | void OutgoingDialog_base::send() |
100 | { | 100 | { |
101 | qWarning( "OutgoingDialog_base::send(): Not implemented yet" ); | 101 | qWarning( "OutgoingDialog_base::send(): Not implemented yet" ); |
102 | } | 102 | } |
103 | 103 | ||
104 | void OutgoingDialog_base::deleteItem() | 104 | void OutgoingDialog_base::deleteItem() |
105 | { | 105 | { |
106 | qWarning( "OutgoingDialog_base::deleteItem(): Not implemented yet" ); | 106 | qWarning( "OutgoingDialog_base::deleteItem(): Not implemented yet" ); |
107 | } | 107 | } |
108 | |||
109 | #include "outgoingdialog_base.moc" | ||
diff --git a/korganizer/publishdialog.cpp b/korganizer/publishdialog.cpp index 176595a..4323b91 100644 --- a/korganizer/publishdialog.cpp +++ b/korganizer/publishdialog.cpp | |||
@@ -119,34 +119,32 @@ void PublishDialog::openAddressbook() | |||
119 | mNameLineEdit->setEnabled(true); | 119 | mNameLineEdit->setEnabled(true); |
120 | mEmailLineEdit->setEnabled(true); | 120 | mEmailLineEdit->setEnabled(true); |
121 | QListViewItem *item = new QListViewItem(mAddressListView); | 121 | QListViewItem *item = new QListViewItem(mAddressListView); |
122 | mAddressListView->setSelected(item,true); | 122 | mAddressListView->setSelected(item,true); |
123 | mNameLineEdit->setText(a.realName()); | 123 | mNameLineEdit->setText(a.realName()); |
124 | mEmailLineEdit->setText(a.preferredEmail()); | 124 | mEmailLineEdit->setText(a.preferredEmail()); |
125 | mAddressListView->insertItem(item); | 125 | mAddressListView->insertItem(item); |
126 | } | 126 | } |
127 | } | 127 | } |
128 | #endif | 128 | #endif |
129 | } | 129 | } |
130 | 130 | ||
131 | void PublishDialog::updateItem() | 131 | void PublishDialog::updateItem() |
132 | { | 132 | { |
133 | QListViewItem *item; | 133 | QListViewItem *item; |
134 | item = mAddressListView->selectedItem(); | 134 | item = mAddressListView->selectedItem(); |
135 | if (!item) return; | 135 | if (!item) return; |
136 | item->setText(0,mNameLineEdit->text()); | 136 | item->setText(0,mNameLineEdit->text()); |
137 | item->setText(1,mEmailLineEdit->text()); | 137 | item->setText(1,mEmailLineEdit->text()); |
138 | } | 138 | } |
139 | 139 | ||
140 | void PublishDialog::updateInput() | 140 | void PublishDialog::updateInput() |
141 | { | 141 | { |
142 | QListViewItem *item; | 142 | QListViewItem *item; |
143 | item = mAddressListView->selectedItem(); | 143 | item = mAddressListView->selectedItem(); |
144 | if (!item) return; | 144 | if (!item) return; |
145 | mNameLineEdit->setEnabled(true); | 145 | mNameLineEdit->setEnabled(true); |
146 | mEmailLineEdit->setEnabled(true); | 146 | mEmailLineEdit->setEnabled(true); |
147 | QString mail = item->text(1); | 147 | QString mail = item->text(1); |
148 | mNameLineEdit->setText(item->text(0)); | 148 | mNameLineEdit->setText(item->text(0)); |
149 | mEmailLineEdit->setText(mail); | 149 | mEmailLineEdit->setText(mail); |
150 | } | 150 | } |
151 | |||
152 | #include "publishdialog.moc" | ||
diff --git a/korganizer/publishdialog_base.cpp b/korganizer/publishdialog_base.cpp index 75e4746..683f7e9 100644 --- a/korganizer/publishdialog_base.cpp +++ b/korganizer/publishdialog_base.cpp | |||
@@ -129,34 +129,32 @@ void PublishDialog_base::languageChange() | |||
129 | { | 129 | { |
130 | setCaption( tr2i18n( "Form1" ) ); | 130 | setCaption( tr2i18n( "Form1" ) ); |
131 | mAddressListView->header()->setLabel( 0, tr2i18n( "Name" ) ); | 131 | mAddressListView->header()->setLabel( 0, tr2i18n( "Name" ) ); |
132 | mAddressListView->header()->setLabel( 1, tr2i18n( "Email" ) ); | 132 | mAddressListView->header()->setLabel( 1, tr2i18n( "Email" ) ); |
133 | TextLabel1->setText( tr2i18n( "Name:" ) ); | 133 | TextLabel1->setText( tr2i18n( "Name:" ) ); |
134 | TextLabel2->setText( tr2i18n( "Email:" ) ); | 134 | TextLabel2->setText( tr2i18n( "Email:" ) ); |
135 | PushButton10->setText( tr2i18n( "&New" ) ); | 135 | PushButton10->setText( tr2i18n( "&New" ) ); |
136 | PushButton12->setText( tr2i18n( "&Addressbook" ) ); | 136 | PushButton12->setText( tr2i18n( "&Addressbook" ) ); |
137 | PushButton11->setText( tr2i18n( "&Remove" ) ); | 137 | PushButton11->setText( tr2i18n( "&Remove" ) ); |
138 | PushButton9->setText( tr2i18n( "&OK" ) ); | 138 | PushButton9->setText( tr2i18n( "&OK" ) ); |
139 | PushButton8->setText( tr2i18n( "&Cancel" ) ); | 139 | PushButton8->setText( tr2i18n( "&Cancel" ) ); |
140 | } | 140 | } |
141 | 141 | ||
142 | void PublishDialog_base::addItem() | 142 | void PublishDialog_base::addItem() |
143 | { | 143 | { |
144 | qWarning( "PublishDialog_base::addItem(): Not implemented yet" ); | 144 | qWarning( "PublishDialog_base::addItem(): Not implemented yet" ); |
145 | } | 145 | } |
146 | 146 | ||
147 | void PublishDialog_base::removeItem() | 147 | void PublishDialog_base::removeItem() |
148 | { | 148 | { |
149 | qWarning( "PublishDialog_base::removeItem(): Not implemented yet" ); | 149 | qWarning( "PublishDialog_base::removeItem(): Not implemented yet" ); |
150 | } | 150 | } |
151 | 151 | ||
152 | void PublishDialog_base::openAddressbook() | 152 | void PublishDialog_base::openAddressbook() |
153 | { | 153 | { |
154 | qWarning( "PublishDialog_base::openAddressbook(): Not implemented yet" ); | 154 | qWarning( "PublishDialog_base::openAddressbook(): Not implemented yet" ); |
155 | } | 155 | } |
156 | 156 | ||
157 | void PublishDialog_base::updateItem() | 157 | void PublishDialog_base::updateItem() |
158 | { | 158 | { |
159 | qWarning( "PublishDialog_base::updateItem(): Not implemented yet" ); | 159 | qWarning( "PublishDialog_base::updateItem(): Not implemented yet" ); |
160 | } | 160 | } |
161 | |||
162 | #include "publishdialog_base.moc" | ||
diff --git a/korganizer/savetemplatedialog.cpp b/korganizer/savetemplatedialog.cpp index 0da524f..3544081 100644 --- a/korganizer/savetemplatedialog.cpp +++ b/korganizer/savetemplatedialog.cpp | |||
@@ -1,64 +1,63 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of KOrganizer. | 2 | This file is part of KOrganizer. |
3 | Copyright (c) 2002 Cornelius Schumacher <schumacher@kde.org> | 3 | Copyright (c) 2002 Cornelius Schumacher <schumacher@kde.org> |
4 | 4 | ||
5 | This program is free software; you can redistribute it and/or modify | 5 | This program is free software; you can redistribute it and/or modify |
6 | it under the terms of the GNU General Public License as published by | 6 | it under the terms of the GNU General Public License as published by |
7 | the Free Software Foundation; either version 2 of the License, or | 7 | the Free Software Foundation; either version 2 of the License, or |
8 | (at your option) any later version. | 8 | (at your option) any later version. |
9 | 9 | ||
10 | This program is distributed in the hope that it will be useful, | 10 | This program is distributed in the hope that it will be useful, |
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
13 | GNU General Public License for more details. | 13 | GNU General Public License for more details. |
14 | 14 | ||
15 | You should have received a copy of the GNU General Public License | 15 | You should have received a copy of the GNU General Public License |
16 | along with this program; if not, write to the Free Software | 16 | along with this program; if not, write to the Free Software |
17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
18 | 18 | ||
19 | As a special exception, permission is given to link this program | 19 | As a special exception, permission is given to link this program |
20 | with any edition of Qt, and distribute the resulting executable, | 20 | with any edition of Qt, and distribute the resulting executable, |
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 <qlayout.h> | 24 | #include <qlayout.h> |
25 | 25 | ||
26 | #include <keditlistbox.h> | 26 | #include <keditlistbox.h> |
27 | #include <klocale.h> | 27 | #include <klocale.h> |
28 | 28 | ||
29 | #include "koprefs.h" | 29 | #include "koprefs.h" |
30 | 30 | ||
31 | #include "savetemplatedialog.h" | 31 | #include "savetemplatedialog.h" |
32 | #include "savetemplatedialog.moc" | ||
33 | 32 | ||
34 | SaveTemplateDialog::SaveTemplateDialog( IncidenceType type, QWidget *parent ) | 33 | SaveTemplateDialog::SaveTemplateDialog( IncidenceType type, QWidget *parent ) |
35 | : KDialogBase( Plain, i18n("Save Template"), Ok | Cancel, Ok, parent, 0, | 34 | : KDialogBase( Plain, i18n("Save Template"), Ok | Cancel, Ok, parent, 0, |
36 | true, false ), | 35 | true, false ), |
37 | mType( type ) | 36 | mType( type ) |
38 | { | 37 | { |
39 | QFrame *topFrame = plainPage(); | 38 | QFrame *topFrame = plainPage(); |
40 | QVBoxLayout *topLayout = new QVBoxLayout( topFrame, 0, spacingHint() ); | 39 | QVBoxLayout *topLayout = new QVBoxLayout( topFrame, 0, spacingHint() ); |
41 | 40 | ||
42 | mEditListBox = new KEditListBox( i18n("Select Template Name"), topFrame, | 41 | mEditListBox = new KEditListBox( i18n("Select Template Name"), topFrame, |
43 | 0, false, KEditListBox::Add | | 42 | 0, false, KEditListBox::Add | |
44 | KEditListBox::Remove ); | 43 | KEditListBox::Remove ); |
45 | topLayout->addWidget( mEditListBox ); | 44 | topLayout->addWidget( mEditListBox ); |
46 | connect( mEditListBox, SIGNAL( changed() ), SLOT( slotChanged() ) ); | 45 | connect( mEditListBox, SIGNAL( changed() ), SLOT( slotChanged() ) ); |
47 | 46 | ||
48 | QStringList templates; | 47 | QStringList templates; |
49 | 48 | ||
50 | if ( mType == EventType ) { | 49 | if ( mType == EventType ) { |
51 | templates = KOPrefs::instance()->mEventTemplates; | 50 | templates = KOPrefs::instance()->mEventTemplates; |
52 | } else if( mType == TodoType ) { | 51 | } else if( mType == TodoType ) { |
53 | templates = KOPrefs::instance()->mTodoTemplates; | 52 | templates = KOPrefs::instance()->mTodoTemplates; |
54 | } | 53 | } |
55 | 54 | ||
56 | mEditListBox->insertStringList( templates ); | 55 | mEditListBox->insertStringList( templates ); |
57 | } | 56 | } |
58 | 57 | ||
59 | SaveTemplateDialog::~SaveTemplateDialog() | 58 | SaveTemplateDialog::~SaveTemplateDialog() |
60 | { | 59 | { |
61 | } | 60 | } |
62 | 61 | ||
63 | void SaveTemplateDialog::slotOk() | 62 | void SaveTemplateDialog::slotOk() |
64 | { | 63 | { |
diff --git a/korganizer/searchdialog.cpp b/korganizer/searchdialog.cpp index 74d48b9..5bd7c6f 100644 --- a/korganizer/searchdialog.cpp +++ b/korganizer/searchdialog.cpp | |||
@@ -11,65 +11,64 @@ | |||
11 | This program is distributed in the hope that it will be useful, | 11 | This program is distributed in the hope that it will be useful, |
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
14 | GNU General Public License for more details. | 14 | GNU General Public License for more details. |
15 | 15 | ||
16 | You should have received a copy of the GNU General Public License | 16 | You should have received a copy of the GNU General Public License |
17 | along with this program; if not, write to the Free Software | 17 | along with this program; if not, write to the Free Software |
18 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 18 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
19 | 19 | ||
20 | As a special exception, permission is given to link this program | 20 | As a special exception, permission is given to link this program |
21 | with any edition of Qt, and distribute the resulting executable, | 21 | with any edition of Qt, and distribute the resulting executable, |
22 | without including the source code for Qt in the source distribution. | 22 | without including the source code for Qt in the source distribution. |
23 | */ | 23 | */ |
24 | 24 | ||
25 | #include <qlayout.h> | 25 | #include <qlayout.h> |
26 | #include <qcheckbox.h> | 26 | #include <qcheckbox.h> |
27 | #include <qgroupbox.h> | 27 | #include <qgroupbox.h> |
28 | #include <qlabel.h> | 28 | #include <qlabel.h> |
29 | #include <qlineedit.h> | 29 | #include <qlineedit.h> |
30 | #include <qpushbutton.h> | 30 | #include <qpushbutton.h> |
31 | 31 | ||
32 | #include <klocale.h> | 32 | #include <klocale.h> |
33 | #include <kmessagebox.h> | 33 | #include <kmessagebox.h> |
34 | 34 | ||
35 | #include <libkdepim/kdateedit.h> | 35 | #include <libkdepim/kdateedit.h> |
36 | 36 | ||
37 | #include "koglobals.h" | 37 | #include "koglobals.h" |
38 | #include "koprefs.h" | 38 | #include "koprefs.h" |
39 | 39 | ||
40 | #include "calendarview.h" | 40 | #include "calendarview.h" |
41 | #include "koviewmanager.h" | 41 | #include "koviewmanager.h" |
42 | #include "searchdialog.h" | 42 | #include "searchdialog.h" |
43 | #include "searchdialog.moc" | ||
44 | 43 | ||
45 | SearchDialog::SearchDialog(Calendar *calendar,CalendarView *parent) | 44 | SearchDialog::SearchDialog(Calendar *calendar,CalendarView *parent) |
46 | : KDialogBase(Plain,i18n("KO/Pi Find "),User1|Close,User1,parent,0,false,false, | 45 | : KDialogBase(Plain,i18n("KO/Pi Find "),User1|Close,User1,parent,0,false,false, |
47 | i18n("&Find")) | 46 | i18n("&Find")) |
48 | { | 47 | { |
49 | mCalendar = calendar; | 48 | mCalendar = calendar; |
50 | QFrame *topFrame = plainPage(); | 49 | QFrame *topFrame = plainPage(); |
51 | QVBoxLayout *layout = new QVBoxLayout(topFrame,0,spacingHint()); | 50 | QVBoxLayout *layout = new QVBoxLayout(topFrame,0,spacingHint()); |
52 | 51 | ||
53 | // Search expression | 52 | // Search expression |
54 | QHBoxLayout *subLayout = new QHBoxLayout(); | 53 | QHBoxLayout *subLayout = new QHBoxLayout(); |
55 | layout->addLayout(subLayout); | 54 | layout->addLayout(subLayout); |
56 | 55 | ||
57 | searchLabel = new QLabel(topFrame); | 56 | searchLabel = new QLabel(topFrame); |
58 | searchLabel->setText(i18n("Search for:")); | 57 | searchLabel->setText(i18n("Search for:")); |
59 | subLayout->addWidget(searchLabel); | 58 | subLayout->addWidget(searchLabel); |
60 | 59 | ||
61 | searchEdit = new QLineEdit(topFrame); | 60 | searchEdit = new QLineEdit(topFrame); |
62 | subLayout->addWidget(searchEdit); | 61 | subLayout->addWidget(searchEdit); |
63 | searchEdit->setText("*"); // Find all events by default | 62 | searchEdit->setText("*"); // Find all events by default |
64 | searchEdit->setFocus(); | 63 | searchEdit->setFocus(); |
65 | connect(searchEdit, SIGNAL(textChanged ( const QString & )),this,SLOT(searchTextChanged( const QString & ))); | 64 | connect(searchEdit, SIGNAL(textChanged ( const QString & )),this,SLOT(searchTextChanged( const QString & ))); |
66 | connect(searchEdit, SIGNAL( returnPressed () ),this,SLOT(doSearch())); | 65 | connect(searchEdit, SIGNAL( returnPressed () ),this,SLOT(doSearch())); |
67 | // Subjects to search | 66 | // Subjects to search |
68 | // QGroupBox *subjectGroup = new QGroupBox(1,Vertical,i18n("Search In"), | 67 | // QGroupBox *subjectGroup = new QGroupBox(1,Vertical,i18n("Search In"), |
69 | // topFrame); | 68 | // topFrame); |
70 | 69 | ||
71 | 70 | ||
72 | 71 | ||
73 | QHBox *incidenceGroup = new QHBox( topFrame ); | 72 | QHBox *incidenceGroup = new QHBox( topFrame ); |
74 | layout->addWidget(incidenceGroup); | 73 | layout->addWidget(incidenceGroup); |
75 | 74 | ||
diff --git a/korganizer/statusdialog.cpp b/korganizer/statusdialog.cpp index 78efeb0..7137c49 100644 --- a/korganizer/statusdialog.cpp +++ b/korganizer/statusdialog.cpp | |||
@@ -1,61 +1,60 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of KOrganizer. | 2 | This file is part of KOrganizer. |
3 | Copyright (c) 2001 Cornelius Schumacher <schumacher@kde.org> | 3 | Copyright (c) 2001 Cornelius Schumacher <schumacher@kde.org> |
4 | 4 | ||
5 | This program is free software; you can redistribute it and/or modify | 5 | This program is free software; you can redistribute it and/or modify |
6 | it under the terms of the GNU General Public License as published by | 6 | it under the terms of the GNU General Public License as published by |
7 | the Free Software Foundation; either version 2 of the License, or | 7 | the Free Software Foundation; either version 2 of the License, or |
8 | (at your option) any later version. | 8 | (at your option) any later version. |
9 | 9 | ||
10 | This program is distributed in the hope that it will be useful, | 10 | This program is distributed in the hope that it will be useful, |
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
13 | GNU General Public License for more details. | 13 | GNU General Public License for more details. |
14 | 14 | ||
15 | You should have received a copy of the GNU General Public License | 15 | You should have received a copy of the GNU General Public License |
16 | along with this program; if not, write to the Free Software | 16 | along with this program; if not, write to the Free Software |
17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | 17 | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. |
18 | */ | 18 | */ |
19 | 19 | ||
20 | #include <qlabel.h> | 20 | #include <qlabel.h> |
21 | #include <qpushbutton.h> | 21 | #include <qpushbutton.h> |
22 | #include <qstringlist.h> | 22 | #include <qstringlist.h> |
23 | #include <qlayout.h> | 23 | #include <qlayout.h> |
24 | 24 | ||
25 | #include <kdebug.h> | 25 | #include <kdebug.h> |
26 | #include <klocale.h> | 26 | #include <klocale.h> |
27 | 27 | ||
28 | #include "statusdialog.h" | 28 | #include "statusdialog.h" |
29 | #include "statusdialog.moc" | ||
30 | 29 | ||
31 | StatusDialog::StatusDialog(QWidget* parent, const char* name) : | 30 | StatusDialog::StatusDialog(QWidget* parent, const char* name) : |
32 | KDialog(parent,name,true) | 31 | KDialog(parent,name,true) |
33 | { | 32 | { |
34 | setCaption(i18n("Set Your Status")); | 33 | setCaption(i18n("Set Your Status")); |
35 | 34 | ||
36 | QBoxLayout *topLayout = new QVBoxLayout( this ); | 35 | QBoxLayout *topLayout = new QVBoxLayout( this ); |
37 | topLayout->setSpacing( spacingHint() ); | 36 | topLayout->setSpacing( spacingHint() ); |
38 | topLayout->setMargin( marginHint() ); | 37 | topLayout->setMargin( marginHint() ); |
39 | 38 | ||
40 | QBoxLayout *statusLayout = new QHBoxLayout( topLayout ); | 39 | QBoxLayout *statusLayout = new QHBoxLayout( topLayout ); |
41 | 40 | ||
42 | QLabel *text = new QLabel(i18n("Set your status"),this); | 41 | QLabel *text = new QLabel(i18n("Set your status"),this); |
43 | statusLayout->addWidget( text ); | 42 | statusLayout->addWidget( text ); |
44 | 43 | ||
45 | mStatus = new QComboBox(false,this); | 44 | mStatus = new QComboBox(false,this); |
46 | mStatus->insertStringList(Attendee::statusList()); | 45 | mStatus->insertStringList(Attendee::statusList()); |
47 | statusLayout->addWidget( mStatus ); | 46 | statusLayout->addWidget( mStatus ); |
48 | 47 | ||
49 | QBoxLayout *buttonLayout = new QHBoxLayout( topLayout ); | 48 | QBoxLayout *buttonLayout = new QHBoxLayout( topLayout ); |
50 | 49 | ||
51 | QPushButton *ok = new QPushButton(i18n("&OK"), this); | 50 | QPushButton *ok = new QPushButton(i18n("&OK"), this); |
52 | connect ( ok,SIGNAL(clicked()), this,SLOT(accept()) ); | 51 | connect ( ok,SIGNAL(clicked()), this,SLOT(accept()) ); |
53 | buttonLayout->addWidget( ok ); | 52 | buttonLayout->addWidget( ok ); |
54 | 53 | ||
55 | QPushButton *cancel = new QPushButton(i18n("&Cancel"), this); | 54 | QPushButton *cancel = new QPushButton(i18n("&Cancel"), this); |
56 | connect ( cancel,SIGNAL(clicked()), this,SLOT(reject()) ); | 55 | connect ( cancel,SIGNAL(clicked()), this,SLOT(reject()) ); |
57 | buttonLayout->addWidget( cancel ); | 56 | buttonLayout->addWidget( cancel ); |
58 | } | 57 | } |
59 | 58 | ||
60 | StatusDialog::~StatusDialog() | 59 | StatusDialog::~StatusDialog() |
61 | { | 60 | { |
diff --git a/korganizer/timeline.cpp b/korganizer/timeline.cpp index 6f9c8dd..11be432 100644 --- a/korganizer/timeline.cpp +++ b/korganizer/timeline.cpp | |||
@@ -1,38 +1,37 @@ | |||
1 | #include <qpainter.h> | 1 | #include <qpainter.h> |
2 | 2 | ||
3 | #include <kdebug.h> | 3 | #include <kdebug.h> |
4 | 4 | ||
5 | #include "timeline.h" | 5 | #include "timeline.h" |
6 | #include "timeline.moc" | ||
7 | 6 | ||
8 | TimeLine::TimeLine( QWidget *parent, const char *name ) : | 7 | TimeLine::TimeLine( QWidget *parent, const char *name ) : |
9 | QScrollView( parent, name ) | 8 | QScrollView( parent, name ) |
10 | { | 9 | { |
11 | mPixelWidth = 1000; | 10 | mPixelWidth = 1000; |
12 | 11 | ||
13 | resizeContents( mPixelWidth, 20 ); | 12 | resizeContents( mPixelWidth, 20 ); |
14 | 13 | ||
15 | viewport()->setBackgroundMode( PaletteBackground ); | 14 | viewport()->setBackgroundMode( PaletteBackground ); |
16 | 15 | ||
17 | setHScrollBarMode(AlwaysOff); | 16 | setHScrollBarMode(AlwaysOff); |
18 | setVScrollBarMode(AlwaysOff); | 17 | setVScrollBarMode(AlwaysOff); |
19 | } | 18 | } |
20 | 19 | ||
21 | TimeLine::~TimeLine() | 20 | TimeLine::~TimeLine() |
22 | { | 21 | { |
23 | } | 22 | } |
24 | 23 | ||
25 | void TimeLine::drawContents(QPainter* p, int cx, int cy, int cw, int ch) | 24 | void TimeLine::drawContents(QPainter* p, int cx, int cy, int cw, int ch) |
26 | { | 25 | { |
27 | int spacingX = mDaySpacing; | 26 | int spacingX = mDaySpacing; |
28 | int offsetX = mDayOffset; | 27 | int offsetX = mDayOffset; |
29 | 28 | ||
30 | // Draw vertical lines of grid | 29 | // Draw vertical lines of grid |
31 | // kdDebug() << "drawContents cx: " << cx << " cy: " << cy << " cw: " << cw << " ch: " << ch << endl; | 30 | // kdDebug() << "drawContents cx: " << cx << " cy: " << cy << " cw: " << cw << " ch: " << ch << endl; |
32 | int cell = int( (cx - ( spacingX - offsetX ) ) / spacingX ); | 31 | int cell = int( (cx - ( spacingX - offsetX ) ) / spacingX ); |
33 | int x = cell * spacingX + ( spacingX - offsetX ); | 32 | int x = cell * spacingX + ( spacingX - offsetX ); |
34 | // kdDebug() << " x: " << x << endl; | 33 | // kdDebug() << " x: " << x << endl; |
35 | while (x < cx + cw) { | 34 | while (x < cx + cw) { |
36 | // kdDebug() << " x: " << x << endl; | 35 | // kdDebug() << " x: " << x << endl; |
37 | p->drawLine(x,cy,x,cy+ch); | 36 | p->drawLine(x,cy,x,cy+ch); |
38 | p->drawText( x + 5, 15, QString::number( mStartDate.addDays( cell + 1 ).date().day() ) ); | 37 | p->drawText( x + 5, 15, QString::number( mStartDate.addDays( cell + 1 ).date().day() ) ); |
diff --git a/korganizer/timespanview.cpp b/korganizer/timespanview.cpp index f8314e7..67a3811 100644 --- a/korganizer/timespanview.cpp +++ b/korganizer/timespanview.cpp | |||
@@ -1,51 +1,50 @@ | |||
1 | 1 | ||
2 | #ifndef DESKTOP_VERSION | 2 | #ifndef DESKTOP_VERSION |
3 | #include <qksplitter.h> | 3 | #include <qksplitter.h> |
4 | #else | 4 | #else |
5 | #include <qsplitter.h> | 5 | #include <qsplitter.h> |
6 | #endif | 6 | #endif |
7 | #include <qlistview.h> | 7 | #include <qlistview.h> |
8 | #include <qlayout.h> | 8 | #include <qlayout.h> |
9 | #include <qheader.h> | 9 | #include <qheader.h> |
10 | #include <qpushbutton.h> | 10 | #include <qpushbutton.h> |
11 | 11 | ||
12 | #include <klocale.h> | 12 | #include <klocale.h> |
13 | #include <kdebug.h> | 13 | #include <kdebug.h> |
14 | 14 | ||
15 | #include "lineview.h" | 15 | #include "lineview.h" |
16 | #include "timeline.h" | 16 | #include "timeline.h" |
17 | 17 | ||
18 | #include "timespanview.h" | 18 | #include "timespanview.h" |
19 | #include "timespanview.moc" | ||
20 | 19 | ||
21 | 20 | ||
22 | TimeSpanView::TimeSpanView( QWidget *parent, const char *name ) : | 21 | TimeSpanView::TimeSpanView( QWidget *parent, const char *name ) : |
23 | QWidget( parent, name ) | 22 | QWidget( parent, name ) |
24 | { | 23 | { |
25 | QBoxLayout *topLayout = new QVBoxLayout( this ); | 24 | QBoxLayout *topLayout = new QVBoxLayout( this ); |
26 | #ifndef DESKTOP_VERSION | 25 | #ifndef DESKTOP_VERSION |
27 | mSplitter = new QKSplitter( this ); | 26 | mSplitter = new QKSplitter( this ); |
28 | #else | 27 | #else |
29 | mSplitter = new QSplitter( this ); | 28 | mSplitter = new QSplitter( this ); |
30 | #endif | 29 | #endif |
31 | topLayout->addWidget( mSplitter ); | 30 | topLayout->addWidget( mSplitter ); |
32 | 31 | ||
33 | mList = new QListView( mSplitter ); | 32 | mList = new QListView( mSplitter ); |
34 | mList->addColumn( i18n("Summary") ); | 33 | mList->addColumn( i18n("Summary") ); |
35 | 34 | ||
36 | QWidget *rightPane = new QWidget( mSplitter ); | 35 | QWidget *rightPane = new QWidget( mSplitter ); |
37 | QBoxLayout *rightPaneLayout = new QVBoxLayout( rightPane ); | 36 | QBoxLayout *rightPaneLayout = new QVBoxLayout( rightPane ); |
38 | 37 | ||
39 | mTimeLine = new TimeLine( rightPane ); | 38 | mTimeLine = new TimeLine( rightPane ); |
40 | mTimeLine->setFixedHeight( mList->header()->height() ); | 39 | mTimeLine->setFixedHeight( mList->header()->height() ); |
41 | rightPaneLayout->addWidget( mTimeLine ); | 40 | rightPaneLayout->addWidget( mTimeLine ); |
42 | 41 | ||
43 | mLineView = new LineView( rightPane ); | 42 | mLineView = new LineView( rightPane ); |
44 | rightPaneLayout->addWidget( mLineView ); | 43 | rightPaneLayout->addWidget( mLineView ); |
45 | 44 | ||
46 | QBoxLayout *buttonLayout = new QHBoxLayout( rightPaneLayout ); | 45 | QBoxLayout *buttonLayout = new QHBoxLayout( rightPaneLayout ); |
47 | 46 | ||
48 | QPushButton *zoomInButton = new QPushButton( i18n("Zoom In"), rightPane ); | 47 | QPushButton *zoomInButton = new QPushButton( i18n("Zoom In"), rightPane ); |
49 | connect( zoomInButton, SIGNAL( clicked() ), SLOT( zoomIn() ) ); | 48 | connect( zoomInButton, SIGNAL( clicked() ), SLOT( zoomIn() ) ); |
50 | buttonLayout->addWidget( zoomInButton ); | 49 | buttonLayout->addWidget( zoomInButton ); |
51 | 50 | ||