-rw-r--r-- | korganizer/calendarview.cpp | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp index d0de233..c0f3be7 100644 --- a/korganizer/calendarview.cpp +++ b/korganizer/calendarview.cpp | |||
@@ -113,12 +113,13 @@ | |||
113 | #include "kotodoview.h" | 113 | #include "kotodoview.h" |
114 | #include "datenavigator.h" | 114 | #include "datenavigator.h" |
115 | #include "resourceview.h" | 115 | #include "resourceview.h" |
116 | #include "navigatorbar.h" | 116 | #include "navigatorbar.h" |
117 | #include "searchdialog.h" | 117 | #include "searchdialog.h" |
118 | #include "mainwindow.h" | 118 | #include "mainwindow.h" |
119 | #include "categoryeditdialog.h" | ||
119 | 120 | ||
120 | #include "calendarview.h" | 121 | #include "calendarview.h" |
121 | #ifndef DESKTOP_VERSION | 122 | #ifndef DESKTOP_VERSION |
122 | #include <qtopia/alarmserver.h> | 123 | #include <qtopia/alarmserver.h> |
123 | #endif | 124 | #endif |
124 | #ifndef _WIN32_ | 125 | #ifndef _WIN32_ |
@@ -310,21 +311,21 @@ class KOCatPrefs : public QDialog | |||
310 | QDialog( parent, name, true ) | 311 | QDialog( parent, name, true ) |
311 | { | 312 | { |
312 | setCaption( i18n("Manage new Categories") ); | 313 | setCaption( i18n("Manage new Categories") ); |
313 | QVBoxLayout* lay = new QVBoxLayout( this ); | 314 | QVBoxLayout* lay = new QVBoxLayout( this ); |
314 | lay->setSpacing( 3 ); | 315 | lay->setSpacing( 3 ); |
315 | lay->setMargin( 3 ); | 316 | lay->setMargin( 3 ); |
316 | QLabel * lab = new QLabel( i18n("After importing/loading/syncing\nthere may be new categories in\nevents or todos\nwhich are not in the category list.\nPlease choose what to do:\n "), this ); | 317 | QLabel * lab = new QLabel( i18n("After importing/loading/syncing there may be new categories in events or todos which are not added automatically to the category list. Please choose what to do <b>now</b>:"), this ); |
317 | lay->addWidget( lab ); | 318 | lay->addWidget( lab ); |
318 | QButtonGroup* format = new QButtonGroup( 1, Horizontal, i18n("New categories not in list:"), this ); | 319 | QButtonGroup* format = new QButtonGroup( 1, Horizontal, i18n("New categories not in list:"), this ); |
319 | lay->addWidget( format ); | 320 | lay->addWidget( format ); |
320 | format->setExclusive ( true ) ; | 321 | format->setExclusive ( true ) ; |
321 | addCatBut = new QRadioButton(i18n("Add to category list"), format ); | 322 | addCatBut = new QRadioButton(i18n("Add to category list"), format ); |
322 | new QRadioButton(i18n("Remove from Events/Todos"), format ); | 323 | new QRadioButton(i18n("Remove from Events/Todos"), format ); |
323 | addCatBut->setChecked( true ); | 324 | addCatBut->setChecked( true ); |
324 | QPushButton * ok = new QPushButton( i18n("OK"), this ); | 325 | QPushButton * ok = new QPushButton( i18n("Change category list now!"), this ); |
325 | lay->addWidget( ok ); | 326 | lay->addWidget( ok ); |
326 | QPushButton * cancel = new QPushButton( i18n("Cancel"), this ); | 327 | QPushButton * cancel = new QPushButton( i18n("Cancel"), this ); |
327 | lay->addWidget( cancel ); | 328 | lay->addWidget( cancel ); |
328 | connect ( ok,SIGNAL(clicked() ),this , SLOT ( accept() ) ); | 329 | connect ( ok,SIGNAL(clicked() ),this , SLOT ( accept() ) ); |
329 | connect (cancel, SIGNAL(clicked() ), this, SLOT ( reject()) ); | 330 | connect (cancel, SIGNAL(clicked() ), this, SLOT ( reject()) ); |
330 | resize( 200, 200 ); | 331 | resize( 200, 200 ); |
@@ -2815,12 +2816,18 @@ int CalendarView::addCategories() | |||
2815 | } | 2816 | } |
2816 | catList.sort(); | 2817 | catList.sort(); |
2817 | KOPrefs::instance()->mCustomCategories = catList; | 2818 | KOPrefs::instance()->mCustomCategories = catList; |
2818 | return count; | 2819 | return count; |
2819 | } | 2820 | } |
2820 | 2821 | ||
2822 | void CalendarView::editCategories() | ||
2823 | { | ||
2824 | qDebug("CalendarView::editCategories() "); | ||
2825 | KPIM::CategoryEditDialog ced (KOPrefs::instance(),this ); | ||
2826 | ced.exec(); | ||
2827 | } | ||
2821 | void CalendarView::manageCategories() | 2828 | void CalendarView::manageCategories() |
2822 | { | 2829 | { |
2823 | KOCatPrefs* cp = new KOCatPrefs(); | 2830 | KOCatPrefs* cp = new KOCatPrefs(); |
2824 | cp->show(); | 2831 | cp->show(); |
2825 | int w =cp->sizeHint().width() ; | 2832 | int w =cp->sizeHint().width() ; |
2826 | int h = cp->sizeHint().height() ; | 2833 | int h = cp->sizeHint().height() ; |