-rw-r--r-- | korganizer/calendarview.cpp | 22 |
1 files changed, 15 insertions, 7 deletions
diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp index 12af655..f9af769 100644 --- a/korganizer/calendarview.cpp +++ b/korganizer/calendarview.cpp | |||
@@ -233,6 +233,7 @@ CalendarView::CalendarView( Calendar *calendar, | |||
233 | 233 | ||
234 | void CalendarView::init() | 234 | void CalendarView::init() |
235 | { | 235 | { |
236 | mBlockShowDates = false; | ||
236 | beamDialog = new KOBeamPrefs(); | 237 | beamDialog = new KOBeamPrefs(); |
237 | mDatePickerMode = 0; | 238 | mDatePickerMode = 0; |
238 | mCurrentSyncDevice = ""; | 239 | mCurrentSyncDevice = ""; |
@@ -346,9 +347,9 @@ void CalendarView::init() | |||
346 | 347 | ||
347 | connect( mNavigator, SIGNAL( datesSelected( const KCal::DateList & ) ), | 348 | connect( mNavigator, SIGNAL( datesSelected( const KCal::DateList & ) ), |
348 | SLOT( showDates( const KCal::DateList & ) ) ); | 349 | SLOT( showDates( const KCal::DateList & ) ) ); |
350 | |||
349 | connect( mNavigator, SIGNAL( datesSelected( const KCal::DateList & ) ), | 351 | connect( mNavigator, SIGNAL( datesSelected( const KCal::DateList & ) ), |
350 | mDateNavigator, SLOT( selectDates( const KCal::DateList & ) ) ); | 352 | mDateNavigator, SLOT( selectDates( const KCal::DateList & ) ) ); |
351 | |||
352 | connect( mNavigatorBar, SIGNAL( goPrevYear() ), | 353 | connect( mNavigatorBar, SIGNAL( goPrevYear() ), |
353 | mNavigator, SLOT( selectPreviousYear() ) ); | 354 | mNavigator, SLOT( selectPreviousYear() ) ); |
354 | connect( mNavigatorBar, SIGNAL( goNextYear() ), | 355 | connect( mNavigatorBar, SIGNAL( goNextYear() ), |
@@ -357,10 +358,10 @@ void CalendarView::init() | |||
357 | mNavigator, SLOT( selectPreviousMonth() ) ); | 358 | mNavigator, SLOT( selectPreviousMonth() ) ); |
358 | connect( mNavigatorBar, SIGNAL( goNextMonth() ), | 359 | connect( mNavigatorBar, SIGNAL( goNextMonth() ), |
359 | mNavigator, SLOT( selectNextMonth() ) ); | 360 | mNavigator, SLOT( selectNextMonth() ) ); |
360 | 361 | ||
361 | connect( mNavigator, SIGNAL( datesSelected( const KCal::DateList & ) ), | 362 | connect( mNavigator, SIGNAL( datesSelected( const KCal::DateList & ) ), |
362 | mNavigatorBar, SLOT( selectDates( const KCal::DateList & ) ) ); | 363 | mNavigatorBar, SLOT( selectDates( const KCal::DateList & ) ) ); |
363 | 364 | ||
364 | connect( mDateNavigator, SIGNAL( weekClicked( const QDate & ) ), | 365 | connect( mDateNavigator, SIGNAL( weekClicked( const QDate & ) ), |
365 | mNavigator, SLOT( selectWeek( const QDate & ) ) ); | 366 | mNavigator, SLOT( selectWeek( const QDate & ) ) ); |
366 | 367 | ||
@@ -497,7 +498,9 @@ CalendarView::~CalendarView() | |||
497 | 498 | ||
498 | void CalendarView::showDay( QDate d ) | 499 | void CalendarView::showDay( QDate d ) |
499 | { | 500 | { |
501 | dateNavigator()->blockSignals( true ); | ||
500 | dateNavigator()->selectDate( d ); | 502 | dateNavigator()->selectDate( d ); |
503 | dateNavigator()->blockSignals( false ); | ||
501 | mViewManager->showWeekView(); | 504 | mViewManager->showWeekView(); |
502 | dateNavigator()->selectDate( d ); | 505 | dateNavigator()->selectDate( d ); |
503 | } | 506 | } |
@@ -672,7 +675,9 @@ void CalendarView::removeAlarm(const QDateTime &qdt, const QString ¬i ) | |||
672 | } | 675 | } |
673 | void CalendarView::selectWeekNum ( int num ) | 676 | void CalendarView::selectWeekNum ( int num ) |
674 | { | 677 | { |
678 | dateNavigator()->blockSignals( true ); | ||
675 | dateNavigator()->selectWeek( num ); | 679 | dateNavigator()->selectWeek( num ); |
680 | dateNavigator()->blockSignals( false ); | ||
676 | mViewManager->showWeekView(); | 681 | mViewManager->showWeekView(); |
677 | } | 682 | } |
678 | KOViewManager *CalendarView::viewManager() | 683 | KOViewManager *CalendarView::viewManager() |
@@ -3465,10 +3470,13 @@ void CalendarView::showDates(const DateList &selectedDates) | |||
3465 | { | 3470 | { |
3466 | // kdDebug() << "CalendarView::selectDates()" << endl; | 3471 | // kdDebug() << "CalendarView::selectDates()" << endl; |
3467 | 3472 | ||
3468 | if ( mViewManager->currentView() ) { | 3473 | |
3469 | updateView( selectedDates.first(), selectedDates.last() ); | 3474 | if ( !mBlockShowDates ) { |
3470 | } else { | 3475 | if ( mViewManager->currentView() ) { |
3471 | mViewManager->showAgendaView(); | 3476 | updateView( selectedDates.first(), selectedDates.last() ); |
3477 | } else { | ||
3478 | mViewManager->showAgendaView(); | ||
3479 | } | ||
3472 | } | 3480 | } |
3473 | 3481 | ||
3474 | QString selDates; | 3482 | QString selDates; |