Diffstat (limited to 'korganizer/datenavigatorcontainer.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | korganizer/datenavigatorcontainer.cpp | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/korganizer/datenavigatorcontainer.cpp b/korganizer/datenavigatorcontainer.cpp index 5cdaa83..5941337 100644 --- a/korganizer/datenavigatorcontainer.cpp +++ b/korganizer/datenavigatorcontainer.cpp | |||
@@ -193,35 +193,39 @@ void DateNavigatorContainer::resizeEvent( QResizeEvent * e ) | |||
193 | fontchange = true; | 193 | fontchange = true; |
194 | fo = KOPrefs::instance()->mDateNavigatorFont; | 194 | fo = KOPrefs::instance()->mDateNavigatorFont; |
195 | mNavigatorView->changeFont( fo ); | 195 | mNavigatorView->changeFont( fo ); |
196 | mNavigatorView->unsetFontChanged(); | 196 | mNavigatorView->unsetFontChanged(); |
197 | } | 197 | } |
198 | } | 198 | } |
199 | 199 | ||
200 | while ( count > ( mExtraViews.count() + 1 ) ) { | 200 | while ( count > ( mExtraViews.count() + 1 ) ) { |
201 | KDateNavigator *n = new KDateNavigator( this ); | 201 | KDateNavigator *n = new KDateNavigator( this ); |
202 | n->setMonthSignalOffset ( mExtraViews.count()+1 ); | 202 | n->setMonthSignalOffset ( mExtraViews.count()+1 ); |
203 | mExtraViews.append( n ); | 203 | mExtraViews.append( n ); |
204 | n->setCalendar( mCalendar ); | 204 | n->setCalendar( mCalendar ); |
205 | setBaseDates(); | 205 | setBaseDates(); |
206 | connectNavigatorView( n ); | 206 | connectNavigatorView( n ); |
207 | n->show(); | 207 | n->show(); |
208 | } | 208 | } |
209 | 209 | int iii = 0; | |
210 | while ( count < ( mExtraViews.count() + 1 ) ) { | 210 | while ( iii < ( mExtraViews.count() ) ) { |
211 | mExtraViews.removeLast(); | 211 | if ( iii < count-1 ) |
212 | mExtraViews.at( iii )->show(); | ||
213 | else | ||
214 | mExtraViews.at( iii )->hide(); | ||
215 | ++iii; | ||
212 | } | 216 | } |
213 | if ( fontchange ) { | 217 | if ( fontchange ) { |
214 | //mNavigatorView->changeFont( fo ); | 218 | //mNavigatorView->changeFont( fo ); |
215 | uint i; | 219 | uint i; |
216 | for( i = 0; i < mExtraViews.count(); ++i ) { | 220 | for( i = 0; i < mExtraViews.count(); ++i ) { |
217 | KDateNavigator *view = mExtraViews.at( i ); | 221 | KDateNavigator *view = mExtraViews.at( i ); |
218 | view->changeFont( fo ); | 222 | view->changeFont( fo ); |
219 | } | 223 | } |
220 | } | 224 | } |
221 | mHorizontalCount = horizontalCount; | 225 | mHorizontalCount = horizontalCount; |
222 | mVerticalCount = verticalCount; | 226 | mVerticalCount = verticalCount; |
223 | } | 227 | } |
224 | int height = size().height() / verticalCount; | 228 | int height = size().height() / verticalCount; |
225 | int width = size().width() / horizontalCount; | 229 | int width = size().width() / horizontalCount; |
226 | 230 | ||
227 | NavigatorBar *bar = mNavigatorView->navigatorBar(); | 231 | NavigatorBar *bar = mNavigatorView->navigatorBar(); |