-rw-r--r-- | korganizer/datenavigatorcontainer.cpp | 6 | ||||
-rw-r--r-- | korganizer/koagendaitem.cpp | 8 | ||||
-rw-r--r-- | korganizer/koagendaview.cpp | 1 | ||||
-rw-r--r-- | korganizer/komonthview.cpp | 26 | ||||
-rw-r--r-- | korganizer/komonthview.h | 3 | ||||
-rw-r--r-- | korganizer/koviewmanager.cpp | 1 |
6 files changed, 36 insertions, 9 deletions
diff --git a/korganizer/datenavigatorcontainer.cpp b/korganizer/datenavigatorcontainer.cpp index 548c364..d1caff3 100644 --- a/korganizer/datenavigatorcontainer.cpp +++ b/korganizer/datenavigatorcontainer.cpp | |||
@@ -51,4 +51,6 @@ DateNavigatorContainer::DateNavigatorContainer( QWidget *parent, | |||
51 | mUpdateTimer = new QTimer( this ); | 51 | mUpdateTimer = new QTimer( this ); |
52 | connect (mUpdateTimer ,SIGNAL(timeout()), this, SLOT ( checkUpdateDayMatrixDates() )); | 52 | connect (mUpdateTimer ,SIGNAL(timeout()), this, SLOT ( checkUpdateDayMatrixDates() )); |
53 | mFirstSelectedDate = QDate::currentDate(); | ||
54 | mSelectedDateCount = 1; | ||
53 | } | 55 | } |
54 | 56 | ||
@@ -141,5 +143,5 @@ void DateNavigatorContainer::setCalendar( Calendar *cal ) | |||
141 | void DateNavigatorContainer::checkUpdateDayMatrixDates() | 143 | void DateNavigatorContainer::checkUpdateDayMatrixDates() |
142 | { | 144 | { |
143 | qDebug("wid %d hei %d ", width(), height()); | 145 | //qDebug("KODNC: wid %d hei %d ", width(), height()); |
144 | mUpdateTimer->stop(); | 146 | mUpdateTimer->stop(); |
145 | //return; | 147 | //return; |
@@ -149,5 +151,5 @@ void DateNavigatorContainer::checkUpdateDayMatrixDates() | |||
149 | static int lastHei = 0; | 151 | static int lastHei = 0; |
150 | if ( lastWid == width() && height() == lastHei ) { | 152 | if ( lastWid == width() && height() == lastHei ) { |
151 | qDebug("no layout computing needed. "); | 153 | qDebug("KODNC: No layout computing needed. "); |
152 | } else { | 154 | } else { |
153 | lastWid = width(); | 155 | lastWid = width(); |
diff --git a/korganizer/koagendaitem.cpp b/korganizer/koagendaitem.cpp index 7e6fa48..82d1eab 100644 --- a/korganizer/koagendaitem.cpp +++ b/korganizer/koagendaitem.cpp | |||
@@ -505,6 +505,6 @@ void KOAgendaItem::paintEvent ( QPaintEvent *e ) | |||
505 | rx -= xx; | 505 | rx -= xx; |
506 | xx = 0; | 506 | xx = 0; |
507 | if ( rw < 0 ) { | 507 | if ( rw <= 1 ) { |
508 | qDebug("KOAgendaItem::Width1 < 0. Returning "); | 508 | qDebug("KOAgendaItem::Width1 <= 1 (%d). Returning. %s",rw,mDisplayedText.latin1()); |
509 | return; | 509 | return; |
510 | } | 510 | } |
@@ -512,6 +512,6 @@ void KOAgendaItem::paintEvent ( QPaintEvent *e ) | |||
512 | if ( paintFrom->width() < xx+rw ) { | 512 | if ( paintFrom->width() < xx+rw ) { |
513 | rw = paintFrom->width() - xx; | 513 | rw = paintFrom->width() - xx; |
514 | if ( rw < 0 ) { | 514 | if ( rw <= 1 ) { |
515 | qDebug("KOAgendaItem::Width2 < 0. Returning "); | 515 | qDebug("KOAgendaItem::Width2 <= 1 (%d). Returning.%s ",rw,mDisplayedText.latin1() ); |
516 | return; | 516 | return; |
517 | } | 517 | } |
diff --git a/korganizer/koagendaview.cpp b/korganizer/koagendaview.cpp index eb3a6cd..5508210 100644 --- a/korganizer/koagendaview.cpp +++ b/korganizer/koagendaview.cpp | |||
@@ -268,4 +268,5 @@ EventIndicator::EventIndicator(Location loc,QWidget *parent,const char *name) | |||
268 | else mPixmap = SmallIcon("1downarrow"); | 268 | else mPixmap = SmallIcon("1downarrow"); |
269 | mEnabled.resize(mColumns); | 269 | mEnabled.resize(mColumns); |
270 | mEnabled.fill( false ); | ||
270 | setMinimumHeight(mPixmap.height()); | 271 | setMinimumHeight(mPixmap.height()); |
271 | } | 272 | } |
diff --git a/korganizer/komonthview.cpp b/korganizer/komonthview.cpp index 9fd1f68..8ee5bc3 100644 --- a/korganizer/komonthview.cpp +++ b/korganizer/komonthview.cpp | |||
@@ -995,4 +995,9 @@ KOMonthView::KOMonthView(Calendar *calendar, QWidget *parent, const char *name) | |||
995 | 995 | ||
996 | emit incidenceSelected( 0 ); | 996 | emit incidenceSelected( 0 ); |
997 | |||
998 | mComputeLayoutTimer = new QTimer( this ); | ||
999 | connect (mComputeLayoutTimer ,SIGNAL(timeout()), this, SLOT ( slotComputeLayout())); | ||
1000 | |||
1001 | |||
997 | #ifndef DESKTOP_VERSION | 1002 | #ifndef DESKTOP_VERSION |
998 | resize( QApplication::desktop()->size() ); | 1003 | resize( QApplication::desktop()->size() ); |
@@ -1352,5 +1357,16 @@ void KOMonthView::updateView() | |||
1352 | void KOMonthView::resizeEvent(QResizeEvent * e) | 1357 | void KOMonthView::resizeEvent(QResizeEvent * e) |
1353 | { | 1358 | { |
1354 | //qDebug("KOMonthView::resizeEvent %d %d -- %d %d ", e->size().width(), e->size().height(), e->oldSize().width(), e->oldSize().height()); | 1359 | qDebug("KOMonthView::resizeEvent %d %d -- %d %d ", e->size().width(), e->size().height(), e->oldSize().width(), e->oldSize().height()); |
1360 | if ( isVisible() ) { | ||
1361 | qDebug("KOMonthView::isVisible "); | ||
1362 | slotComputeLayout(); | ||
1363 | } else | ||
1364 | mComputeLayoutTimer->start( 100 ); | ||
1365 | } | ||
1366 | |||
1367 | void KOMonthView::slotComputeLayout() | ||
1368 | { | ||
1369 | mComputeLayoutTimer->stop(); | ||
1370 | qDebug("KOMonthView::Post - resizeEvent %d %d ", width(), height() ); | ||
1355 | computeLayout(); | 1371 | computeLayout(); |
1356 | clPending = true; | 1372 | clPending = true; |
@@ -1359,4 +1375,5 @@ void KOMonthView::resizeEvent(QResizeEvent * e) | |||
1359 | else | 1375 | else |
1360 | mCells[0]->setFocus(); | 1376 | mCells[0]->setFocus(); |
1377 | |||
1361 | } | 1378 | } |
1362 | void KOMonthView::computeLayoutWeek() | 1379 | void KOMonthView::computeLayoutWeek() |
@@ -1379,6 +1396,8 @@ void KOMonthView::computeLayoutWeek() | |||
1379 | return; | 1396 | return; |
1380 | 1397 | ||
1381 | if ( lastWid == width() && lastHei == height() ) | 1398 | if ( lastWid == width() && lastHei == height() ) { |
1399 | qDebug("KOListWeekView::No compute layout needed "); | ||
1382 | return; | 1400 | return; |
1401 | } | ||
1383 | lastWid = width(); | 1402 | lastWid = width(); |
1384 | lastHei = height(); | 1403 | lastHei = height(); |
@@ -1506,4 +1525,5 @@ void KOMonthView::computeLayout() | |||
1506 | } | 1525 | } |
1507 | if ( lastWid == width() && lastHei == height() ){ | 1526 | if ( lastWid == width() && lastHei == height() ){ |
1527 | qDebug("KOMonthview::No compute layout needed "); | ||
1508 | return; | 1528 | return; |
1509 | } | 1529 | } |
@@ -1511,5 +1531,5 @@ void KOMonthView::computeLayout() | |||
1511 | lastWid = width(); | 1531 | lastWid = width(); |
1512 | lastHei = height(); | 1532 | lastHei = height(); |
1513 | //qDebug("KOMonthView::computeLayout() MMM ------------------------------------ "); | 1533 | qDebug("KOMonthView::computeLayout() MMM ------------------- "); |
1514 | QFontMetrics fm ( mWeekLabels[0]->font() ); | 1534 | QFontMetrics fm ( mWeekLabels[0]->font() ); |
1515 | int weeklabelwid = fm.width( "888" ); | 1535 | int weeklabelwid = fm.width( "888" ); |
diff --git a/korganizer/komonthview.h b/korganizer/komonthview.h index a92421b..89912e0 100644 --- a/korganizer/komonthview.h +++ b/korganizer/komonthview.h | |||
@@ -28,4 +28,5 @@ | |||
28 | #include <qwidgetstack.h> | 28 | #include <qwidgetstack.h> |
29 | #include <qlayout.h> | 29 | #include <qlayout.h> |
30 | #include <qtimer.h> | ||
30 | #include <qintdict.h> | 31 | #include <qintdict.h> |
31 | #include <qpushbutton.h> | 32 | #include <qpushbutton.h> |
@@ -252,4 +253,5 @@ class KOMonthView: public KOEventView | |||
252 | 253 | ||
253 | protected slots: | 254 | protected slots: |
255 | void slotComputeLayout(); | ||
254 | void selectInternalWeekNum ( int ); | 256 | void selectInternalWeekNum ( int ); |
255 | void processSelectionChange(); | 257 | void processSelectionChange(); |
@@ -266,4 +268,5 @@ class KOMonthView: public KOEventView | |||
266 | 268 | ||
267 | private: | 269 | private: |
270 | QTimer* mComputeLayoutTimer; | ||
268 | NavigatorBar* mNavigatorBar; | 271 | NavigatorBar* mNavigatorBar; |
269 | int currentWeek(); | 272 | int currentWeek(); |
diff --git a/korganizer/koviewmanager.cpp b/korganizer/koviewmanager.cpp index cc0ce9b..94d74f1 100644 --- a/korganizer/koviewmanager.cpp +++ b/korganizer/koviewmanager.cpp | |||
@@ -242,4 +242,5 @@ void KOViewManager::raiseCurrentView( bool fullScreen, bool callUpdateView ) | |||
242 | mMainView->leftFrame()->show(); | 242 | mMainView->leftFrame()->show(); |
243 | } | 243 | } |
244 | //if ( mCurrentView == mMonthView ) qApp->processEvents(); | ||
244 | emit signalFullScreen( !fullScreen ); | 245 | emit signalFullScreen( !fullScreen ); |
245 | if ( callUpdateView ) | 246 | if ( callUpdateView ) |