summaryrefslogtreecommitdiffabout
authorzautrix <zautrix>2004-08-06 15:59:14 (UTC)
committer zautrix <zautrix>2004-08-06 15:59:14 (UTC)
commitf3307379ea27ad1394c9107c0129ecd3efd6bca6 (patch) (unidiff)
treefdfebbebf84b2e86812165fac2bec09f95008ee2
parentfc862590cffbef8429bb8804dadfa61a21a52c7b (diff)
downloadkdepimpi-f3307379ea27ad1394c9107c0129ecd3efd6bca6.zip
kdepimpi-f3307379ea27ad1394c9107c0129ecd3efd6bca6.tar.gz
kdepimpi-f3307379ea27ad1394c9107c0129ecd3efd6bca6.tar.bz2
Added qick filter selection to kopi menu
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--korganizer/calendarview.cpp9
-rw-r--r--korganizer/calendarview.h3
-rw-r--r--korganizer/mainwindow.cpp47
-rw-r--r--korganizer/mainwindow.h3
4 files changed, 59 insertions, 3 deletions
diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp
index 53c079c..fab4540 100644
--- a/korganizer/calendarview.cpp
+++ b/korganizer/calendarview.cpp
@@ -3137,65 +3137,74 @@ void CalendarView::checkClipboard()
3137 } else { 3137 } else {
3138 emit pasteEnabled(false); 3138 emit pasteEnabled(false);
3139 } 3139 }
3140#endif 3140#endif
3141} 3141}
3142 3142
3143void CalendarView::showDates(const DateList &selectedDates) 3143void CalendarView::showDates(const DateList &selectedDates)
3144{ 3144{
3145 // kdDebug() << "CalendarView::selectDates()" << endl; 3145 // kdDebug() << "CalendarView::selectDates()" << endl;
3146 3146
3147 if ( mViewManager->currentView() ) { 3147 if ( mViewManager->currentView() ) {
3148 updateView( selectedDates.first(), selectedDates.last() ); 3148 updateView( selectedDates.first(), selectedDates.last() );
3149 } else { 3149 } else {
3150 mViewManager->showAgendaView(); 3150 mViewManager->showAgendaView();
3151 } 3151 }
3152 3152
3153 QString selDates; 3153 QString selDates;
3154 selDates = KGlobal::locale()->formatDate( selectedDates.first(), true); 3154 selDates = KGlobal::locale()->formatDate( selectedDates.first(), true);
3155 if (selectedDates.first() < selectedDates.last() ) 3155 if (selectedDates.first() < selectedDates.last() )
3156 selDates += " - " + KGlobal::locale()->formatDate( selectedDates.last(),true); 3156 selDates += " - " + KGlobal::locale()->formatDate( selectedDates.last(),true);
3157 topLevelWidget()->setCaption( i18n("Dates: ") + selDates ); 3157 topLevelWidget()->setCaption( i18n("Dates: ") + selDates );
3158 3158
3159} 3159}
3160 3160
3161QPtrList<CalFilter> CalendarView::filters()
3162{
3163 return mFilters;
3164
3165}
3161void CalendarView::editFilters() 3166void CalendarView::editFilters()
3162{ 3167{
3163 // kdDebug() << "CalendarView::editFilters()" << endl; 3168 // kdDebug() << "CalendarView::editFilters()" << endl;
3164 3169
3165 CalFilter *filter = mFilters.first(); 3170 CalFilter *filter = mFilters.first();
3166 while(filter) { 3171 while(filter) {
3167 kdDebug() << " Filter: " << filter->name() << endl; 3172 kdDebug() << " Filter: " << filter->name() << endl;
3168 filter = mFilters.next(); 3173 filter = mFilters.next();
3169 } 3174 }
3170 3175
3171 mDialogManager->showFilterEditDialog(&mFilters); 3176 mDialogManager->showFilterEditDialog(&mFilters);
3172} 3177}
3173void CalendarView::toggleFilter() 3178void CalendarView::toggleFilter()
3174{ 3179{
3175 showFilter(! mFilterView->isVisible()); 3180 showFilter(! mFilterView->isVisible());
3176} 3181}
3177 3182
3183KOFilterView *CalendarView::filterView()
3184{
3185 return mFilterView;
3186}
3178void CalendarView::selectFilter( int fil ) 3187void CalendarView::selectFilter( int fil )
3179{ 3188{
3180 mFilterView->setSelectedFilter( fil ); 3189 mFilterView->setSelectedFilter( fil );
3181} 3190}
3182void CalendarView::showFilter(bool visible) 3191void CalendarView::showFilter(bool visible)
3183{ 3192{
3184 if (visible) mFilterView->show(); 3193 if (visible) mFilterView->show();
3185 else mFilterView->hide(); 3194 else mFilterView->hide();
3186} 3195}
3187void CalendarView::toggleFilerEnabled( ) 3196void CalendarView::toggleFilerEnabled( )
3188{ 3197{
3189 mFilterView->setFiltersEnabled ( !mFilterView->filtersEnabled() ); 3198 mFilterView->setFiltersEnabled ( !mFilterView->filtersEnabled() );
3190 if ( !mFilterView->filtersEnabled() ) 3199 if ( !mFilterView->filtersEnabled() )
3191 topLevelWidget()->setCaption( i18n("Filter disabled ") ); 3200 topLevelWidget()->setCaption( i18n("Filter disabled ") );
3192 3201
3193} 3202}
3194void CalendarView::updateFilter() 3203void CalendarView::updateFilter()
3195{ 3204{
3196 CalFilter *filter = mFilterView->selectedFilter(); 3205 CalFilter *filter = mFilterView->selectedFilter();
3197 if (filter) { 3206 if (filter) {
3198 if (mFilterView->filtersEnabled()) { 3207 if (mFilterView->filtersEnabled()) {
3199 topLevelWidget()->setCaption( i18n("Filter selected: ")+filter->name() ); 3208 topLevelWidget()->setCaption( i18n("Filter selected: ")+filter->name() );
3200 filter->setEnabled(true); 3209 filter->setEnabled(true);
3201 } 3210 }
diff --git a/korganizer/calendarview.h b/korganizer/calendarview.h
index f7a1213..d564473 100644
--- a/korganizer/calendarview.h
+++ b/korganizer/calendarview.h
@@ -356,54 +356,55 @@ class CalendarView : public KOrg::CalendarViewBase, public KCal::Calendar::Obser
356 void setModified(bool modified=true); 356 void setModified(bool modified=true);
357 357
358 /** query if the calendar is read-only. */ 358 /** query if the calendar is read-only. */
359 bool isReadOnly(); 359 bool isReadOnly();
360 /** set state of calendar to read-only */ 360 /** set state of calendar to read-only */
361 void setReadOnly(bool readOnly=true); 361 void setReadOnly(bool readOnly=true);
362 362
363 void eventUpdated(Incidence *); 363 void eventUpdated(Incidence *);
364 364
365 /* iTIP scheduling actions */ 365 /* iTIP scheduling actions */
366 void schedule_publish(Incidence *incidence = 0); 366 void schedule_publish(Incidence *incidence = 0);
367 void schedule_request(Incidence *incidence = 0); 367 void schedule_request(Incidence *incidence = 0);
368 void schedule_refresh(Incidence *incidence = 0); 368 void schedule_refresh(Incidence *incidence = 0);
369 void schedule_cancel(Incidence *incidence = 0); 369 void schedule_cancel(Incidence *incidence = 0);
370 void schedule_add(Incidence *incidence = 0); 370 void schedule_add(Incidence *incidence = 0);
371 void schedule_reply(Incidence *incidence = 0); 371 void schedule_reply(Incidence *incidence = 0);
372 void schedule_counter(Incidence *incidence = 0); 372 void schedule_counter(Incidence *incidence = 0);
373 void schedule_declinecounter(Incidence *incidence = 0); 373 void schedule_declinecounter(Incidence *incidence = 0);
374 void schedule_publish_freebusy(int daysToPublish = 30); 374 void schedule_publish_freebusy(int daysToPublish = 30);
375 375
376 void openAddressbook(); 376 void openAddressbook();
377 377
378 void editFilters(); 378 void editFilters();
379 void toggleFilerEnabled(); 379 void toggleFilerEnabled();
380 380 QPtrList<CalFilter> filters();
381 void toggleFilter(); 381 void toggleFilter();
382 void showFilter(bool visible); 382 void showFilter(bool visible);
383 void updateFilter(); 383 void updateFilter();
384 void filterEdited(); 384 void filterEdited();
385 void selectFilter( int ); 385 void selectFilter( int );
386 KOFilterView *filterView();
386 387
387 void showIntro(); 388 void showIntro();
388 389
389 /** Move the curdatepient view date to today */ 390 /** Move the curdatepient view date to today */
390 void goToday(); 391 void goToday();
391 392
392 /** Move to the next date(s) in the current view */ 393 /** Move to the next date(s) in the current view */
393 void goNext(); 394 void goNext();
394 395
395 /** Move to the previous date(s) in the current view */ 396 /** Move to the previous date(s) in the current view */
396 void goPrevious(); 397 void goPrevious();
397 /** Move to the next date(s) in the current view */ 398 /** Move to the next date(s) in the current view */
398 void goNextMonth(); 399 void goNextMonth();
399 400
400 /** Move to the previous date(s) in the current view */ 401 /** Move to the previous date(s) in the current view */
401 void goPreviousMonth(); 402 void goPreviousMonth();
402 403
403 void toggleExpand(); 404 void toggleExpand();
404 void toggleDateNavigatorWidget(); 405 void toggleDateNavigatorWidget();
405 void toggleAllDaySize(); 406 void toggleAllDaySize();
406 void dialogClosing(Incidence *); 407 void dialogClosing(Incidence *);
407 408
408 /** Look for new messages in the inbox */ 409 /** Look for new messages in the inbox */
409 void lookForIncomingMessages(); 410 void lookForIncomingMessages();
diff --git a/korganizer/mainwindow.cpp b/korganizer/mainwindow.cpp
index 57b299f..a93d8e5 100644
--- a/korganizer/mainwindow.cpp
+++ b/korganizer/mainwindow.cpp
@@ -21,48 +21,49 @@
21#include <qpe/resource.h> 21#include <qpe/resource.h>
22#include <qpe/qpeapplication.h> 22#include <qpe/qpeapplication.h>
23#include <qtopia/alarmserver.h> 23#include <qtopia/alarmserver.h>
24#include <qtopia/qcopenvelope_qws.h> 24#include <qtopia/qcopenvelope_qws.h>
25#else 25#else
26#include <qmenubar.h> 26#include <qmenubar.h>
27#include <qtoolbar.h> 27#include <qtoolbar.h>
28#include <qapplication.h> 28#include <qapplication.h>
29//#include <resource.h> 29//#include <resource.h>
30 30
31#endif 31#endif
32#include <libkcal/calendarlocal.h> 32#include <libkcal/calendarlocal.h>
33#include <libkcal/todo.h> 33#include <libkcal/todo.h>
34#include <libkdepim/ksyncprofile.h> 34#include <libkdepim/ksyncprofile.h>
35#include <libkdepim/kincidenceformatter.h> 35#include <libkdepim/kincidenceformatter.h>
36 36
37#include "calendarview.h" 37#include "calendarview.h"
38#include "koviewmanager.h" 38#include "koviewmanager.h"
39#include "datenavigator.h" 39#include "datenavigator.h"
40#include "koagendaview.h" 40#include "koagendaview.h"
41#include "koagenda.h" 41#include "koagenda.h"
42#include "kodialogmanager.h" 42#include "kodialogmanager.h"
43#include "kdialogbase.h" 43#include "kdialogbase.h"
44#include "kapplication.h" 44#include "kapplication.h"
45#include "kofilterview.h"
45#include "kstandarddirs.h" 46#include "kstandarddirs.h"
46#include "koprefs.h" 47#include "koprefs.h"
47#include "kfiledialog.h" 48#include "kfiledialog.h"
48#include "koglobals.h" 49#include "koglobals.h"
49#include "kglobal.h" 50#include "kglobal.h"
50#include "klocale.h" 51#include "klocale.h"
51#include "kconfig.h" 52#include "kconfig.h"
52#include "simplealarmclient.h" 53#include "simplealarmclient.h"
53using namespace KCal; 54using namespace KCal;
54#ifndef _WIN32_ 55#ifndef _WIN32_
55#include <unistd.h> 56#include <unistd.h>
56#else 57#else
57#include "koimportoldialog.h" 58#include "koimportoldialog.h"
58#endif 59#endif
59#include "mainwindow.h" 60#include "mainwindow.h"
60 61
61int globalFlagBlockStartup; 62int globalFlagBlockStartup;
62MainWindow::MainWindow( QWidget *parent, const char *name, QString msg) : 63MainWindow::MainWindow( QWidget *parent, const char *name, QString msg) :
63 QMainWindow( parent, name ) 64 QMainWindow( parent, name )
64{ 65{
65 66
66#ifdef DESKTOP_VERSION 67#ifdef DESKTOP_VERSION
67 setFont( QFont("Arial"), 14 ); 68 setFont( QFont("Arial"), 14 );
68#endif 69#endif
@@ -328,79 +329,85 @@ void MainWindow::recieve( const QCString& cmsg, const QByteArray& data )
328 } 329 }
329 330
330 331
331 } 332 }
332 333
333 showMaximized(); 334 showMaximized();
334 raise(); 335 raise();
335} 336}
336 337
337QPixmap MainWindow::loadPixmap( QString name ) 338QPixmap MainWindow::loadPixmap( QString name )
338{ 339{
339 return SmallIcon( name ); 340 return SmallIcon( name );
340 341
341} 342}
342void MainWindow::initActions() 343void MainWindow::initActions()
343{ 344{
344 //KOPrefs::instance()->mShowFullMenu 345 //KOPrefs::instance()->mShowFullMenu
345 iconToolBar->clear(); 346 iconToolBar->clear();
346 KOPrefs *p = KOPrefs::instance(); 347 KOPrefs *p = KOPrefs::instance();
347 //QPEMenuBar *menuBar1;// = new QPEMenuBar( iconToolBar ); 348 //QPEMenuBar *menuBar1;// = new QPEMenuBar( iconToolBar );
348 349
349 QPopupMenu *viewMenu = new QPopupMenu( this ); 350 QPopupMenu *viewMenu = new QPopupMenu( this );
350 QPopupMenu *actionMenu = new QPopupMenu( this ); 351 QPopupMenu *actionMenu = new QPopupMenu( this );
351 QPopupMenu *importMenu = new QPopupMenu( this ); 352 QPopupMenu *importMenu = new QPopupMenu( this );
352 353 selectFilterMenu = new QPopupMenu( this );
354 selectFilterMenu->setCheckable( true );
353 syncMenu = new QPopupMenu( this ); 355 syncMenu = new QPopupMenu( this );
354 configureAgendaMenu = new QPopupMenu( this ); 356 configureAgendaMenu = new QPopupMenu( this );
355 configureToolBarMenu = new QPopupMenu( this ); 357 configureToolBarMenu = new QPopupMenu( this );
356 QPopupMenu *helpMenu = new QPopupMenu( this ); 358 QPopupMenu *helpMenu = new QPopupMenu( this );
357 if ( KOPrefs::instance()->mShowFullMenu ) { 359 if ( KOPrefs::instance()->mShowFullMenu ) {
358 QMenuBar *menuBar1; 360 QMenuBar *menuBar1;
359 menuBar1 = menuBar(); 361 menuBar1 = menuBar();
360 menuBar1->insertItem( i18n("File"), importMenu ); 362 menuBar1->insertItem( i18n("File"), importMenu );
361 menuBar1->insertItem( i18n("View"), viewMenu ); 363 menuBar1->insertItem( i18n("View"), viewMenu );
362 menuBar1->insertItem( i18n("Actions"), actionMenu ); 364 menuBar1->insertItem( i18n("Actions"), actionMenu );
363 menuBar1->insertItem( i18n("Synchronize"), syncMenu ); 365 menuBar1->insertItem( i18n("Synchronize"), syncMenu );
364 menuBar1->insertItem( i18n("AgendaSize"),configureAgendaMenu ); 366 menuBar1->insertItem( i18n("AgendaSize"),configureAgendaMenu );
365 //menuBar1->insertItem( i18n("Toolbar"),configureToolBarMenu ); 367 //menuBar1->insertItem( i18n("Toolbar"),configureToolBarMenu );
368 menuBar1->insertItem( i18n("Filter"),selectFilterMenu );
366 menuBar1->insertItem( i18n("Help"), helpMenu ); 369 menuBar1->insertItem( i18n("Help"), helpMenu );
367 } else { 370 } else {
368 QPEMenuBar *menuBar1; 371 QPEMenuBar *menuBar1;
369 menuBar1 = new QPEMenuBar( iconToolBar ); 372 menuBar1 = new QPEMenuBar( iconToolBar );
370 QPopupMenu *menuBar = new QPopupMenu( this ); 373 QPopupMenu *menuBar = new QPopupMenu( this );
371 menuBar1->insertItem( i18n("ME"), menuBar); 374 menuBar1->insertItem( i18n("ME"), menuBar);
372 menuBar->insertItem( i18n("File"), importMenu ); 375 menuBar->insertItem( i18n("File"), importMenu );
373 menuBar->insertItem( i18n("View"), viewMenu ); 376 menuBar->insertItem( i18n("View"), viewMenu );
374 menuBar->insertItem( i18n("Actions"), actionMenu ); 377 menuBar->insertItem( i18n("Actions"), actionMenu );
375 menuBar->insertItem( i18n("Synchronize"), syncMenu ); 378 menuBar->insertItem( i18n("Synchronize"), syncMenu );
376 menuBar->insertItem( i18n("AgendaSize"),configureAgendaMenu ); 379 menuBar->insertItem( i18n("AgendaSize"),configureAgendaMenu );
377 menuBar->insertItem( i18n("Toolbar"),configureToolBarMenu ); 380 menuBar->insertItem( i18n("Toolbar"),configureToolBarMenu );
381 menuBar->insertItem( i18n("Filter"),selectFilterMenu );
378 menuBar->insertItem( i18n("Help"), helpMenu ); 382 menuBar->insertItem( i18n("Help"), helpMenu );
379 //menuBar1->setMaximumWidth( menuBar1->sizeHint().width() ); 383 //menuBar1->setMaximumWidth( menuBar1->sizeHint().width() );
380 menuBar1->setMaximumSize( menuBar1->sizeHint( )); 384 menuBar1->setMaximumSize( menuBar1->sizeHint( ));
381 } 385 }
382 connect ( syncMenu, SIGNAL( activated ( int ) ), this, SLOT (slotSyncMenu( int ) ) ); 386 connect ( syncMenu, SIGNAL( activated ( int ) ), this, SLOT (slotSyncMenu( int ) ) );
387 connect ( selectFilterMenu, SIGNAL( activated ( int ) ), this, SLOT (selectFilter( int ) ) );
388 connect ( selectFilterMenu, SIGNAL( aboutToShow () ), this, SLOT (fillFilterMenu() ) );
389
383 // ****************** 390 // ******************
384 QAction *action; 391 QAction *action;
385 QIconSet icon; 392 QIconSet icon;
386 // QPopupMenu *configureMenu= new QPopupMenu( menuBar ); 393 // QPopupMenu *configureMenu= new QPopupMenu( menuBar );
387 configureToolBarMenu->setCheckable( true ); 394 configureToolBarMenu->setCheckable( true );
388 395
389 QString pathString = ""; 396 QString pathString = "";
390 if ( !p->mToolBarMiniIcons ) { 397 if ( !p->mToolBarMiniIcons ) {
391 if ( QApplication::desktop()->width() < 480 ) 398 if ( QApplication::desktop()->width() < 480 )
392 pathString += "icons16/"; 399 pathString += "icons16/";
393 } else 400 } else
394 pathString += "iconsmini/"; 401 pathString += "iconsmini/";
395 configureAgendaMenu->setCheckable( true ); 402 configureAgendaMenu->setCheckable( true );
396 configureAgendaMenu->insertItem(i18n("Toggle Allday"), 1 ); 403 configureAgendaMenu->insertItem(i18n("Toggle Allday"), 1 );
397 configureAgendaMenu->insertSeparator(); 404 configureAgendaMenu->insertSeparator();
398 configureAgendaMenu->insertItem(i18n("Tiny"), 4 ); 405 configureAgendaMenu->insertItem(i18n("Tiny"), 4 );
399 configureAgendaMenu->insertItem(i18n("Small"), 6 ); 406 configureAgendaMenu->insertItem(i18n("Small"), 6 );
400 configureAgendaMenu->insertItem(i18n("Medium"), 8 ); 407 configureAgendaMenu->insertItem(i18n("Medium"), 8 );
401 configureAgendaMenu->insertItem(i18n("Normal"), 10 ); 408 configureAgendaMenu->insertItem(i18n("Normal"), 10 );
402 configureAgendaMenu->insertItem(i18n("Large"), 12 ); 409 configureAgendaMenu->insertItem(i18n("Large"), 12 );
403 configureAgendaMenu->insertItem(i18n("Big"), 14 ); 410 configureAgendaMenu->insertItem(i18n("Big"), 14 );
404 configureAgendaMenu->insertItem(i18n("Bigger"), 16 ); 411 configureAgendaMenu->insertItem(i18n("Bigger"), 16 );
405 configureAgendaMenu->insertItem(i18n("Biggest"), 18 ); 412 configureAgendaMenu->insertItem(i18n("Biggest"), 18 );
406 //configureMenu->insertItem( "AgendaSize",configureAgendaMenu ); 413 //configureMenu->insertItem( "AgendaSize",configureAgendaMenu );
@@ -1494,48 +1501,84 @@ void MainWindow::keyPressEvent ( QKeyEvent * e )
1494 case Qt::Key_Plus: 1501 case Qt::Key_Plus:
1495 size = p->mHourSize +2; 1502 size = p->mHourSize +2;
1496 if ( size <= 18 ) 1503 if ( size <= 18 )
1497 configureAgenda( size ); 1504 configureAgenda( size );
1498 break; 1505 break;
1499 case Qt::Key_Minus: 1506 case Qt::Key_Minus:
1500 size = p->mHourSize - 2; 1507 size = p->mHourSize - 2;
1501 if ( size >= 4 ) 1508 if ( size >= 4 )
1502 configureAgenda( size ); 1509 configureAgenda( size );
1503 break; 1510 break;
1504 1511
1505 1512
1506 default: 1513 default:
1507 e->ignore(); 1514 e->ignore();
1508 } 1515 }
1509 if ( pro > 0 ) { 1516 if ( pro > 0 ) {
1510 mView->selectFilter( pro-1 ); 1517 mView->selectFilter( pro-1 );
1511 } 1518 }
1512 if ( showSelectedDates ) { 1519 if ( showSelectedDates ) {
1513 ;// setCaptionToDates(); 1520 ;// setCaptionToDates();
1514 } 1521 }
1515 1522
1516} 1523}
1517 1524
1525void MainWindow::fillFilterMenu()
1526{
1527 selectFilterMenu->clear();
1528 bool disable = false;
1529 if ( mView->filterView()->filtersEnabled() ) {
1530 selectFilterMenu->insertItem(i18n ( "Turn filter off" ), 0 );
1531 }
1532 else {
1533 selectFilterMenu->insertItem(i18n ( "Turn filter on" ), 0 );
1534 disable = true;
1535 }
1536 selectFilterMenu->insertSeparator();
1537 QPtrList<CalFilter> fili = mView->filters();
1538 CalFilter *curfilter = mView->filterView()->selectedFilter();
1539 CalFilter *filter = fili.first();
1540 int iii = 1;
1541 while(filter) {
1542 selectFilterMenu->insertItem( filter->name(), iii );
1543 if ( filter == curfilter)
1544 selectFilterMenu->setItemChecked( iii, true );
1545 if ( disable )
1546 selectFilterMenu->setItemEnabled( iii, false );
1547 filter = fili.next();
1548 ++iii;
1549 }
1550 qDebug("rettich ");
1551}
1552void MainWindow::selectFilter( int fil )
1553{
1554 qDebug("selectFilter %d ", fil);
1555 if ( fil == 0 ) {
1556 mView->toggleFilerEnabled( );
1557 } else {
1558 mView->selectFilter( fil-1 );
1559 }
1560}
1518void MainWindow::configureToolBar( int item ) 1561void MainWindow::configureToolBar( int item )
1519{ 1562{
1520 1563
1521 configureToolBarMenu->setItemChecked( item, !configureToolBarMenu-> isItemChecked ( item ) ); 1564 configureToolBarMenu->setItemChecked( item, !configureToolBarMenu-> isItemChecked ( item ) );
1522 KOPrefs *p = KOPrefs::instance(); 1565 KOPrefs *p = KOPrefs::instance();
1523 p-> mShowIconStretch= configureToolBarMenu->isItemChecked( 5 ); 1566 p-> mShowIconStretch= configureToolBarMenu->isItemChecked( 5 );
1524 p-> mShowIconNewEvent= configureToolBarMenu->isItemChecked( 10 ); 1567 p-> mShowIconNewEvent= configureToolBarMenu->isItemChecked( 10 );
1525 p->mShowIconNewTodo = configureToolBarMenu->isItemChecked( 20 ); 1568 p->mShowIconNewTodo = configureToolBarMenu->isItemChecked( 20 );
1526 p-> mShowIconSearch= configureToolBarMenu->isItemChecked( 120 ); 1569 p-> mShowIconSearch= configureToolBarMenu->isItemChecked( 120 );
1527 p-> mShowIconList= configureToolBarMenu->isItemChecked( 30 ); 1570 p-> mShowIconList= configureToolBarMenu->isItemChecked( 30 );
1528 p-> mShowIconDay1= configureToolBarMenu->isItemChecked( 40 ); 1571 p-> mShowIconDay1= configureToolBarMenu->isItemChecked( 40 );
1529 p-> mShowIconDay5= configureToolBarMenu->isItemChecked( 50 ); 1572 p-> mShowIconDay5= configureToolBarMenu->isItemChecked( 50 );
1530 p-> mShowIconDay7= configureToolBarMenu->isItemChecked( 60 ); 1573 p-> mShowIconDay7= configureToolBarMenu->isItemChecked( 60 );
1531 p-> mShowIconMonth= configureToolBarMenu->isItemChecked( 70 ); 1574 p-> mShowIconMonth= configureToolBarMenu->isItemChecked( 70 );
1532 p-> mShowIconTodoview= configureToolBarMenu->isItemChecked( 80 ); 1575 p-> mShowIconTodoview= configureToolBarMenu->isItemChecked( 80 );
1533 p-> mShowIconBackFast= configureToolBarMenu->isItemChecked( 200 ); 1576 p-> mShowIconBackFast= configureToolBarMenu->isItemChecked( 200 );
1534 p-> mShowIconBack = configureToolBarMenu->isItemChecked( 210 ); 1577 p-> mShowIconBack = configureToolBarMenu->isItemChecked( 210 );
1535 p-> mShowIconToday= configureToolBarMenu->isItemChecked( 130 ); 1578 p-> mShowIconToday= configureToolBarMenu->isItemChecked( 130 );
1536 p-> mShowIconForward= configureToolBarMenu->isItemChecked( 220 ); 1579 p-> mShowIconForward= configureToolBarMenu->isItemChecked( 220 );
1537 p-> mShowIconForwardFast= configureToolBarMenu->isItemChecked( 230 ); 1580 p-> mShowIconForwardFast= configureToolBarMenu->isItemChecked( 230 );
1538 p-> mShowIconNextDays= configureToolBarMenu->isItemChecked( 100 ); 1581 p-> mShowIconNextDays= configureToolBarMenu->isItemChecked( 100 );
1539 p-> mShowIconNext= configureToolBarMenu->isItemChecked( 110 ); 1582 p-> mShowIconNext= configureToolBarMenu->isItemChecked( 110 );
1540 p-> mShowIconJournal= configureToolBarMenu->isItemChecked( 90 ); 1583 p-> mShowIconJournal= configureToolBarMenu->isItemChecked( 90 );
1541 p-> mShowIconWhatsThis= configureToolBarMenu->isItemChecked( 300 ); 1584 p-> mShowIconWhatsThis= configureToolBarMenu->isItemChecked( 300 );
diff --git a/korganizer/mainwindow.h b/korganizer/mainwindow.h
index 8a3f7b3..fba8c52 100644
--- a/korganizer/mainwindow.h
+++ b/korganizer/mainwindow.h
@@ -47,71 +47,74 @@ class MainWindow : public QMainWindow
47 void synchowto(); 47 void synchowto();
48 void whatsNew(); 48 void whatsNew();
49 void keyBindings(); 49 void keyBindings();
50 void aboutAutoSaving();; 50 void aboutAutoSaving();;
51 void aboutKnownBugs(); 51 void aboutKnownBugs();
52 52
53 void processIncidenceSelection( Incidence * ); 53 void processIncidenceSelection( Incidence * );
54 54
55 void importQtopia(); 55 void importQtopia();
56 void importBday(); 56 void importBday();
57 void importOL(); 57 void importOL();
58 void importIcal(); 58 void importIcal();
59 void importFile( QString, bool ); 59 void importFile( QString, bool );
60 void quickImportIcal(); 60 void quickImportIcal();
61 61
62 void slotModifiedChanged( bool ); 62 void slotModifiedChanged( bool );
63 63
64 void save(); 64 void save();
65 void configureToolBar( int ); 65 void configureToolBar( int );
66 void printSel(); 66 void printSel();
67 void printCal(); 67 void printCal();
68 void saveCalendar(); 68 void saveCalendar();
69 void loadCalendar(); 69 void loadCalendar();
70 void exportVCalendar(); 70 void exportVCalendar();
71 void fillFilterMenu();
72 void selectFilter( int );
71 73
72 void slotSyncMenu( int ); 74 void slotSyncMenu( int );
73 void syncSSH(); 75 void syncSSH();
74 void confSync(); 76 void confSync();
75 void syncSharp(); 77 void syncSharp();
76 void syncLocalFile(); 78 void syncLocalFile();
77 bool syncWithFile( QString, bool ); 79 bool syncWithFile( QString, bool );
78 void quickSyncLocalFile(); 80 void quickSyncLocalFile();
79 81
80 82
81 protected: 83 protected:
82 void displayText( QString, QString); 84 void displayText( QString, QString);
83 void displayFile( QString, QString); 85 void displayFile( QString, QString);
84 86
85 void enableIncidenceActions( bool ); 87 void enableIncidenceActions( bool );
86 88
87 private: 89 private:
88 void saveOnClose(); 90 void saveOnClose();
89 int mCurrentSyncProfile; 91 int mCurrentSyncProfile;
90 void syncRemote( KSyncProfile* , bool ask = true); 92 void syncRemote( KSyncProfile* , bool ask = true);
91 void fillSyncMenu(); 93 void fillSyncMenu();
92 bool mFlagKeyPressed; 94 bool mFlagKeyPressed;
93 bool mBlockAtStartup; 95 bool mBlockAtStartup;
94 QPEToolBar *iconToolBar; 96 QPEToolBar *iconToolBar;
95 void initActions(); 97 void initActions();
96 void setDefaultPreferences(); 98 void setDefaultPreferences();
97 void keyPressEvent ( QKeyEvent * ) ; 99 void keyPressEvent ( QKeyEvent * ) ;
98 void keyReleaseEvent ( QKeyEvent * ) ; 100 void keyReleaseEvent ( QKeyEvent * ) ;
99 QPopupMenu *configureToolBarMenu; 101 QPopupMenu *configureToolBarMenu;
102 QPopupMenu *selectFilterMenu;
100 QPopupMenu *configureAgendaMenu, *syncMenu; 103 QPopupMenu *configureAgendaMenu, *syncMenu;
101 CalendarLocal *mCalendar; 104 CalendarLocal *mCalendar;
102 CalendarView *mView; 105 CalendarView *mView;
103 QString getPassword(); 106 QString getPassword();
104 QAction *mNewSubTodoAction; 107 QAction *mNewSubTodoAction;
105 108
106 QAction *mShowAction; 109 QAction *mShowAction;
107 QAction *mEditAction; 110 QAction *mEditAction;
108 QAction *mDeleteAction; 111 QAction *mDeleteAction;
109 void closeEvent( QCloseEvent* ce ); 112 void closeEvent( QCloseEvent* ce );
110 SimpleAlarmClient mAlarmClient; 113 SimpleAlarmClient mAlarmClient;
111 QTimer mSaveTimer; 114 QTimer mSaveTimer;
112 bool mBlockSaveFlag; 115 bool mBlockSaveFlag;
113 bool mCalendarModifiedFlag; 116 bool mCalendarModifiedFlag;
114 QPixmap loadPixmap( QString ); 117 QPixmap loadPixmap( QString );
115}; 118};
116 119
117#endif 120#endif