summaryrefslogtreecommitdiffabout
authorzautrix <zautrix>2005-07-10 12:06:17 (UTC)
committer zautrix <zautrix>2005-07-10 12:06:17 (UTC)
commita49b694c286167745886996d990f524f9141adbd (patch) (unidiff)
treefe446c465bfbba1d068024449b18642de53dc0f1
parent58b7818a74809dc9280a3249eeb7e0195a66f93d (diff)
downloadkdepimpi-a49b694c286167745886996d990f524f9141adbd.zip
kdepimpi-a49b694c286167745886996d990f524f9141adbd.tar.gz
kdepimpi-a49b694c286167745886996d990f524f9141adbd.tar.bz2
fixx
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--bin/kdepim/WhatsNew.txt2
-rw-r--r--korganizer/calendarview.cpp7
-rw-r--r--korganizer/calendarview.h1
-rw-r--r--korganizer/mainwindow.cpp27
-rw-r--r--korganizer/mainwindow.h5
5 files changed, 31 insertions, 11 deletions
diff --git a/bin/kdepim/WhatsNew.txt b/bin/kdepim/WhatsNew.txt
index 3da24c5..8127ef4 100644
--- a/bin/kdepim/WhatsNew.txt
+++ b/bin/kdepim/WhatsNew.txt
@@ -1,17 +1,17 @@
1Info about the changes in new versions of KDE-Pim/Pi 1Info about the changes in new versions of KDE-Pim/Pi
2 2
3********** VERSION 2.1.16 ************ 3********** VERSION 2.1.16 ************
4 4
5 5Fixed a problem with the menu bar in KO/Pi and using the "Menu" hardware key on the Zaurus.
6 6
7********** VERSION 2.1.15 ************ 7********** VERSION 2.1.15 ************
8 8
9Fixed two layout problems on the Z: 9Fixed two layout problems on the Z:
10Made the with of the newly added buttons on the Quick-Todo smaller. 10Made the with of the newly added buttons on the Quick-Todo smaller.
11Made listweek layout in 2 columns on the Z760 in portait screen and full menubar visible. 11Made listweek layout in 2 columns on the Z760 in portait screen and full menubar visible.
12 12
13 13
14********** VERSION 2.1.14 ************ 14********** VERSION 2.1.14 ************
15 15
16Added some buttons to the KO/Pi Quick-todo line to make it possible to quickly access some todo view layout settings like display all flat/open/close and hide/show running/done. 16Added some buttons to the KO/Pi Quick-todo line to make it possible to quickly access some todo view layout settings like display all flat/open/close and hide/show running/done.
17Added a button to add a subtodo quickly. 17Added a button to add a subtodo quickly.
diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp
index 17f1659..a9e402e 100644
--- a/korganizer/calendarview.cpp
+++ b/korganizer/calendarview.cpp
@@ -358,25 +358,25 @@ CalendarView::CalendarView( Calendar *calendar,
358 mCalendar( calendar ), 358 mCalendar( calendar ),
359 mResourceManager( 0 ) 359 mResourceManager( 0 )
360{ 360{
361 361
362 mEventEditor = 0; 362 mEventEditor = 0;
363 mTodoEditor = 0; 363 mTodoEditor = 0;
364 init(); 364 init();
365} 365}
366 366
367void CalendarView::init() 367void CalendarView::init()
368{ 368{
369 mNextAlarmDateTime = QDateTime::currentDateTime(); 369 mNextAlarmDateTime = QDateTime::currentDateTime();
370 //setFocusPolicy ( NoFocus ); 370 setFocusPolicy (NoFocus );
371 mViewerCallerIsSearchDialog = false; 371 mViewerCallerIsSearchDialog = false;
372 mBlockShowDates = false; 372 mBlockShowDates = false;
373 373
374 mDatePickerMode = 0; 374 mDatePickerMode = 0;
375 mCurrentSyncDevice = ""; 375 mCurrentSyncDevice = "";
376 mViewManager = new KOViewManager( this ); 376 mViewManager = new KOViewManager( this );
377 mDialogManager = new KODialogManager( this ); 377 mDialogManager = new KODialogManager( this );
378 mEventViewerDialog = 0; 378 mEventViewerDialog = 0;
379 mModified = false; 379 mModified = false;
380 mReadOnly = false; 380 mReadOnly = false;
381 mSelectedIncidence = 0; 381 mSelectedIncidence = 0;
382 mCalPrinter = 0; 382 mCalPrinter = 0;
@@ -647,29 +647,24 @@ void CalendarView::init()
647CalendarView::~CalendarView() 647CalendarView::~CalendarView()
648{ 648{
649 // kdDebug() << "~CalendarView()" << endl; 649 // kdDebug() << "~CalendarView()" << endl;
650 //qDebug("CalendarView::~CalendarView() "); 650 //qDebug("CalendarView::~CalendarView() ");
651 delete mDialogManager; 651 delete mDialogManager;
652 delete mViewManager; 652 delete mViewManager;
653 delete mStorage; 653 delete mStorage;
654 delete mDateFrame ; 654 delete mDateFrame ;
655 delete mEventViewerDialog; 655 delete mEventViewerDialog;
656 //kdDebug() << "~CalendarView() done" << endl; 656 //kdDebug() << "~CalendarView() done" << endl;
657} 657}
658 658
659void CalendarView::slotResetFocus()
660{
661 qDebug(" CalendarView::slotResetFocus() %x", qApp->focusWidget());
662
663}
664 659
665void CalendarView::nextConflict( bool all, bool allday ) 660void CalendarView::nextConflict( bool all, bool allday )
666{ 661{
667 662
668 QPtrList<Event> testlist = mCalendar->events(); 663 QPtrList<Event> testlist = mCalendar->events();
669 Event * test = testlist.first(); 664 Event * test = testlist.first();
670 while ( test ) { 665 while ( test ) {
671 test->setTagged( false ); 666 test->setTagged( false );
672 test = testlist.next(); 667 test = testlist.next();
673 } 668 }
674 QTime st ( 0,0,0); 669 QTime st ( 0,0,0);
675 if ( mViewManager->currentView() == mViewManager->agendaView() ) 670 if ( mViewManager->currentView() == mViewManager->agendaView() )
diff --git a/korganizer/calendarview.h b/korganizer/calendarview.h
index 456c2d7..1debef7 100644
--- a/korganizer/calendarview.h
+++ b/korganizer/calendarview.h
@@ -192,25 +192,24 @@ class CalendarView : public KOrg::CalendarViewBase, public KCal::Calendar::Obser
192 /** Emitted, when the number of outgoing messages has changed. */ 192 /** Emitted, when the number of outgoing messages has changed. */
193 void numOutgoingChanged(int); 193 void numOutgoingChanged(int);
194 194
195 /** Send status message, which can e.g. be displayed in the status bar. */ 195 /** Send status message, which can e.g. be displayed in the status bar. */
196 void statusMessage(const QString &); 196 void statusMessage(const QString &);
197 197
198 void calendarViewExpanded( bool ); 198 void calendarViewExpanded( bool );
199 void updateSearchDialog(); 199 void updateSearchDialog();
200 void filtersUpdated(); 200 void filtersUpdated();
201 201
202 202
203 public slots: 203 public slots:
204 void slotResetFocus();
205 void nextConflict( bool all, bool allday ); 204 void nextConflict( bool all, bool allday );
206 void conflictAll(); 205 void conflictAll();
207 void conflictAllday(); 206 void conflictAllday();
208 void conflictNotAll(); 207 void conflictNotAll();
209 void setCalReadOnly( int id, bool readO ); 208 void setCalReadOnly( int id, bool readO );
210 void checkAlarms(); 209 void checkAlarms();
211 void checkFiles(); 210 void checkFiles();
212 void slotprintSelInc(); 211 void slotprintSelInc();
213 void showNextAlarms(); 212 void showNextAlarms();
214 void showOpenError(); 213 void showOpenError();
215 void watchSavedFile(); 214 void watchSavedFile();
216 void recheckTimerAlarm(); 215 void recheckTimerAlarm();
diff --git a/korganizer/mainwindow.cpp b/korganizer/mainwindow.cpp
index 21d5a35..279955f 100644
--- a/korganizer/mainwindow.cpp
+++ b/korganizer/mainwindow.cpp
@@ -414,25 +414,42 @@ MainWindow::~MainWindow()
414{ 414{
415 //qDebug("MainWindow::~MainWindow() "); 415 //qDebug("MainWindow::~MainWindow() ");
416 //save toolbar location 416 //save toolbar location
417 delete mCalendar; 417 delete mCalendar;
418 delete mSyncManager; 418 delete mSyncManager;
419#ifndef DESKTOP_VERSION 419#ifndef DESKTOP_VERSION
420 if ( infrared ) 420 if ( infrared )
421 delete infrared; 421 delete infrared;
422#endif 422#endif
423 423
424 424
425} 425}
426 426void MainWindow::slotResetFocus()
427{
428 //qDebug(" CalendarView::slotResetFocus() %x %x %x %x", qApp->focusWidget(), menuBar1, mView,iconToolBar);
429 mFocusLoop = 3;
430 QTimer::singleShot( 0, this, SLOT(slotResetFocusLoop() ));
431}
432void MainWindow::slotResetFocusLoop()
433{
434 --mFocusLoop;
435 QWidget* fw = mView->viewManager()->currentView();
436 if ( fw ) {
437 //qDebug("loop ");
438 fw->setFocus();
439 if ( qApp->focusWidget() != fw && mFocusLoop > 0 )
440 QTimer::singleShot( 0, this, SLOT(slotResetFocusLoop() ));
441 }
442
443}
427void MainWindow::disableBR(bool b) 444void MainWindow::disableBR(bool b)
428{ 445{
429#ifndef DESKTOP_VERSION 446#ifndef DESKTOP_VERSION
430 if ( b ) { 447 if ( b ) {
431 if ( infrared ) { 448 if ( infrared ) {
432 toggleBeamReceive(); 449 toggleBeamReceive();
433 mBRdisabled = true; 450 mBRdisabled = true;
434 } 451 }
435 mBRdisabled = true; 452 mBRdisabled = true;
436 } else { 453 } else {
437 if ( mBRdisabled ) { 454 if ( mBRdisabled ) {
438 mBRdisabled = false; 455 mBRdisabled = false;
@@ -671,27 +688,29 @@ void MainWindow::initActions()
671 QIconSet icon; 688 QIconSet icon;
672 int pixWid = 22, pixHei = 22; 689 int pixWid = 22, pixHei = 22;
673 QString pathString = ""; 690 QString pathString = "";
674 if ( !p->mToolBarMiniIcons ) { 691 if ( !p->mToolBarMiniIcons ) {
675 if ( QApplication::desktop()->width() < 480 /*|| QApplication::desktop()->height() < 320*/) { 692 if ( QApplication::desktop()->width() < 480 /*|| QApplication::desktop()->height() < 320*/) {
676 pathString += "icons16/"; 693 pathString += "icons16/";
677 pixWid = 18; pixHei = 16; 694 pixWid = 18; pixHei = 16;
678 } 695 }
679 } else { 696 } else {
680 pathString += "iconsmini/"; 697 pathString += "iconsmini/";
681 pixWid = 18; pixHei = 16; 698 pixWid = 18; pixHei = 16;
682 } 699 }
683 KMenuBar *menuBar1; 700
684 if ( KOPrefs::instance()->mShowFullMenu ) { 701 if ( KOPrefs::instance()->mShowFullMenu ) {
685 menuBar1 = new KMenuBar( this );//menuBar(); 702 menuBar1 = new KMenuBar( this );//menuBar();
703 //setMenuBar( menuBar1 );
704 menuBar1->show();
686 menuBar1->insertItem( i18n("File"), importMenu ); 705 menuBar1->insertItem( i18n("File"), importMenu );
687 menuBar1->insertItem( i18n("View"), viewMenu ); 706 menuBar1->insertItem( i18n("View"), viewMenu );
688 menuBar1->insertItem( i18n("Edit"), mCurrentItemMenu ); 707 menuBar1->insertItem( i18n("Edit"), mCurrentItemMenu );
689 menuBar1->insertItem( i18n("Action"), actionMenu ); 708 menuBar1->insertItem( i18n("Action"), actionMenu );
690#ifdef DESKTOP_VERSION 709#ifdef DESKTOP_VERSION
691 menuBar1->insertItem( i18n("Synchronize"), syncMenu ); 710 menuBar1->insertItem( i18n("Synchronize"), syncMenu );
692 menuBar1->insertItem( i18n("AgendaSize"),configureAgendaMenu ); 711 menuBar1->insertItem( i18n("AgendaSize"),configureAgendaMenu );
693#else 712#else
694 menuBar1->insertItem( i18n("Sync"), syncMenu ); 713 menuBar1->insertItem( i18n("Sync"), syncMenu );
695 menuBar1->insertItem( i18n("Agenda"),configureAgendaMenu ); 714 menuBar1->insertItem( i18n("Agenda"),configureAgendaMenu );
696#endif 715#endif
697 //menuBar1->insertItem( i18n("Toolbar"),configureToolBarMenu ); 716 //menuBar1->insertItem( i18n("Toolbar"),configureToolBarMenu );
@@ -705,26 +724,28 @@ void MainWindow::initActions()
705 //menuBar1->insertItem( i18n("ME"), menuBar); 724 //menuBar1->insertItem( i18n("ME"), menuBar);
706 menuBar->insertItem( i18n("File"), importMenu ); 725 menuBar->insertItem( i18n("File"), importMenu );
707 menuBar->insertItem( i18n("View"), viewMenu ); 726 menuBar->insertItem( i18n("View"), viewMenu );
708 menuBar->insertItem( i18n("Edit"), mCurrentItemMenu ); 727 menuBar->insertItem( i18n("Edit"), mCurrentItemMenu );
709 menuBar->insertItem( i18n("Action"), actionMenu ); 728 menuBar->insertItem( i18n("Action"), actionMenu );
710 menuBar->insertItem( i18n("Synchronize"), syncMenu ); 729 menuBar->insertItem( i18n("Synchronize"), syncMenu );
711 menuBar->insertItem( i18n("AgendaSize"),configureAgendaMenu ); 730 menuBar->insertItem( i18n("AgendaSize"),configureAgendaMenu );
712 menuBar->insertItem( i18n("Toolbar"),configureToolBarMenu ); 731 menuBar->insertItem( i18n("Toolbar"),configureToolBarMenu );
713 menuBar->insertItem( i18n("Filter"),selectFilterMenu ); 732 menuBar->insertItem( i18n("Filter"),selectFilterMenu );
714 menuBar->insertItem( i18n("Help"), helpMenu ); 733 menuBar->insertItem( i18n("Help"), helpMenu );
715 //menuBar1->setMaximumWidth( menuBar1->sizeHint().width() ); 734 //menuBar1->setMaximumWidth( menuBar1->sizeHint().width() );
716 menuBar1->setMaximumSize( menuBar1->sizeHint( )); 735 menuBar1->setMaximumSize( menuBar1->sizeHint( ));
736 connect ( menuBar, SIGNAL( aboutToHide () ), this, SLOT ( slotResetFocus() ) );
717 } 737 }
718 connect ( menuBar1, SIGNAL( lostFocus () ), mView, SLOT ( slotResetFocus() ) ); 738 connect ( menuBar1, SIGNAL( lostFocus () ), this, SLOT ( slotResetFocus() ) );
739 //connect ( menuBar1, SIGNAL( lostFocus () ), this, SLOT ( slotResetFocus() ) );
719 connect ( selectFilterMenu, SIGNAL( activated ( int ) ), this, SLOT (selectFilter( int ) ) ); 740 connect ( selectFilterMenu, SIGNAL( activated ( int ) ), this, SLOT (selectFilter( int ) ) );
720 connect ( selectFilterMenu, SIGNAL( aboutToShow() ), this, SLOT (fillFilterMenu() ) ); 741 connect ( selectFilterMenu, SIGNAL( aboutToShow() ), this, SLOT (fillFilterMenu() ) );
721 742
722 743
723 mWeekBgColor = iconToolBar->backgroundColor(); 744 mWeekBgColor = iconToolBar->backgroundColor();
724 mWeekPixmap.resize( pixWid , pixHei ); 745 mWeekPixmap.resize( pixWid , pixHei );
725 mWeekPixmap.fill( mWeekBgColor ); 746 mWeekPixmap.fill( mWeekBgColor );
726 icon = mWeekPixmap; 747 icon = mWeekPixmap;
727 mWeekAction = new QAction( i18n("Select week number"),icon, i18n("Select week number"), 0, this ); 748 mWeekAction = new QAction( i18n("Select week number"),icon, i18n("Select week number"), 0, this );
728 if ( p-> mShowIconWeekNum ) 749 if ( p-> mShowIconWeekNum )
729 mWeekAction->addTo( iconToolBar ); 750 mWeekAction->addTo( iconToolBar );
730 mWeekFont = font(); 751 mWeekFont = font();
diff --git a/korganizer/mainwindow.h b/korganizer/mainwindow.h
index e2de3ba..7d3d492 100644
--- a/korganizer/mainwindow.h
+++ b/korganizer/mainwindow.h
@@ -93,45 +93,50 @@ class MainWindow : public QMainWindow
93 void exportVCalendar(); 93 void exportVCalendar();
94 void fillFilterMenu(); 94 void fillFilterMenu();
95 void fillFilterMenuTB(); 95 void fillFilterMenuTB();
96 void selectFilter( int ); 96 void selectFilter( int );
97 void fillFilterMenuPopup(); 97 void fillFilterMenuPopup();
98 void selectFilterPopup( int ); 98 void selectFilterPopup( int );
99 void exportToPhone( int ); 99 void exportToPhone( int );
100 void toggleBeamReceive(); 100 void toggleBeamReceive();
101 void disableBR(bool); 101 void disableBR(bool);
102 signals: 102 signals:
103 void selectWeek ( int ); 103 void selectWeek ( int );
104 private slots: 104 private slots:
105 void slotResetFocus();
106 void slotResetFocusLoop();
105 void showConfigureAgenda(); 107 void showConfigureAgenda();
106 void getFile( bool ); 108 void getFile( bool );
107 void syncFileRequest(); 109 void syncFileRequest();
108 110
109 protected: 111 protected:
112 int mFocusLoop;
110 void hideEvent ( QHideEvent * ); 113 void hideEvent ( QHideEvent * );
111 QString sentSyncFile(); 114 QString sentSyncFile();
112 void displayText( QString, QString); 115 void displayText( QString, QString);
113 void enableIncidenceActions( bool ); 116 void enableIncidenceActions( bool );
114 117
115 private: 118 private:
119 //void setMenuBar( QMenuBar * );
116 bool mBRdisabled; 120 bool mBRdisabled;
117#ifndef DESKTOP_VERSION 121#ifndef DESKTOP_VERSION
118 QCopChannel* infrared; 122 QCopChannel* infrared;
119#endif 123#endif
120 QAction* brAction; 124 QAction* brAction;
121 KSyncManager* mSyncManager; 125 KSyncManager* mSyncManager;
122 bool mClosed; 126 bool mClosed;
123 void saveOnClose(); 127 void saveOnClose();
124 bool mFlagKeyPressed; 128 bool mFlagKeyPressed;
125 bool mBlockAtStartup; 129 bool mBlockAtStartup;
130 KMenuBar *menuBar1;
126 QPEToolBar *iconToolBar; 131 QPEToolBar *iconToolBar;
127 QPEToolBar *viewToolBar; 132 QPEToolBar *viewToolBar;
128 QPEToolBar *navigatorToolBar; 133 QPEToolBar *navigatorToolBar;
129 QPEToolBar *filterToolBar; 134 QPEToolBar *filterToolBar;
130 KMenuBar *filterMenubar; 135 KMenuBar *filterMenubar;
131 QPopupMenu * filterPopupMenu; 136 QPopupMenu * filterPopupMenu;
132 QPopupMenu * mCurrentItemMenu; 137 QPopupMenu * mCurrentItemMenu;
133 void initActions(); 138 void initActions();
134 void setDefaultPreferences(); 139 void setDefaultPreferences();
135 void resizeEvent( QResizeEvent* e); 140 void resizeEvent( QResizeEvent* e);
136 void keyPressEvent ( QKeyEvent * ) ; 141 void keyPressEvent ( QKeyEvent * ) ;
137 void keyReleaseEvent ( QKeyEvent * ) ; 142 void keyReleaseEvent ( QKeyEvent * ) ;