-rw-r--r-- | korganizer/calendarview.cpp | 3 | ||||
-rw-r--r-- | korganizer/kotodoview.cpp | 31 |
2 files changed, 21 insertions, 13 deletions
diff --git a/korganizer/calendarview.cpp b/korganizer/calendarview.cpp index ab69158..5a2482e 100644 --- a/korganizer/calendarview.cpp +++ b/korganizer/calendarview.cpp @@ -2801,25 +2801,26 @@ void CalendarView::checkConflictForEvent() qApp->processEvents(); int km = KMessageBox::warningContinueCancel(this,mess, i18n("KO/Pi Conflict delected"),i18n("Show date"),i18n("No problem!")); if ( km != KMessageBox::Continue ) return; if ( mViewManager->currentView() != mViewManager->agendaView() || mNavigator->selectedDates().count() > 1 ) mViewManager->showDayView(); mNavigator->slotDaySelect( conflict.date() ); int hour = conflict.time().hour(); mViewManager->agendaView()->setStartHour( hour ); topLevelWidget()->setCaption( i18n("Conflict %1 <-> %2"). arg( mConflictingEvent->summary().left( 20 ) ).arg( cE->summary().left( 20 ) ) ); - } + } else + topLevelWidget()->setCaption( i18n("No conflict found") ); mConflictingEvent = 0; return; } void CalendarView::updateTodoViews() { mTodoList->updateView(); mViewManager->currentView()->updateView(); } diff --git a/korganizer/kotodoview.cpp b/korganizer/kotodoview.cpp index 94f35e6..3ae977d 100644 --- a/korganizer/kotodoview.cpp +++ b/korganizer/kotodoview.cpp @@ -514,49 +514,56 @@ KOTodoView::KOTodoView(Calendar *calendar,QWidget* parent,const char* name) : topLayout->addWidget(mQuickBar); mQuickAdd = new KOQuickTodo(mQuickBar); QBoxLayout *quickLayout = new QHBoxLayout(mQuickBar); quickLayout->addWidget( mQuickAdd ); mNewSubBut = new QPushButton( "sub",mQuickBar ); QPushButton * s_done = new QPushButton( "D",mQuickBar ); QPushButton * s_run = new QPushButton( "R",mQuickBar ); QPushButton * allopen = new QPushButton( "O",mQuickBar ); QPushButton * allclose = new QPushButton( "C",mQuickBar ); QPushButton * flat = new QPushButton( "F",mQuickBar ); - int fixwid = flat->sizeHint().height(); - if ( QApplication::desktop()->width() >= 800 ) + int fixwid = mQuickAdd->sizeHint().height(); + if ( QApplication::desktop()->width() > 800 ) fixwid *= 2; - flat->setFixedWidth( fixwid ); connect ( flat, SIGNAL ( clicked()), SLOT ( setAllFlat())); - allopen->setFixedWidth( fixwid ); connect ( allopen, SIGNAL ( clicked()), SLOT ( setAllOpen())); - allclose->setFixedWidth( fixwid ); connect ( allclose, SIGNAL ( clicked()), SLOT ( setAllClose())); s_done->setPixmap( SmallIcon("greenhook16")); - s_done->setFixedWidth( fixwid ); s_done->setFixedHeight( flat->sizeHint().height() ); connect ( s_done, SIGNAL ( clicked()), SLOT ( toggleCompleted())); s_run->setPixmap( SmallIcon("ko16old")); - s_run->setFixedWidth( fixwid ); - s_run->setFixedHeight( flat->sizeHint().height() ); connect ( s_run, SIGNAL ( clicked()), SLOT ( toggleRunning())); - mNewSubBut->setFixedWidth( fixwid*3/2 ); connect ( mNewSubBut, SIGNAL ( clicked()), SLOT ( newSubTodo())); + + mNewSubBut->setFixedWidth(mNewSubBut->sizeHint().width() ); mNewSubBut->setEnabled( false ); + flat->setFixedWidth( fixwid ); + s_done->setFixedWidth( fixwid ); + allopen->setFixedWidth( fixwid ); + allclose->setFixedWidth( fixwid ); + s_run->setFixedWidth( fixwid ); + if ( QApplication::desktop()->width() < 800 ) { + flat->setFixedHeight( fixwid ); + s_done->setFixedHeight( fixwid ); + allopen->setFixedHeight( fixwid ); + allclose->setFixedHeight( fixwid ); + s_run->setFixedHeight( fixwid ); + mNewSubBut->setFixedHeight( fixwid ); + } quickLayout->addWidget( mNewSubBut ); quickLayout->addWidget( s_done ); quickLayout->addWidget( s_run ); - quickLayout->addWidget( allopen ); quickLayout->addWidget( allclose ); quickLayout->addWidget( flat ); if ( !KOPrefs::instance()->mEnableQuickTodo ) mQuickBar->hide(); mTodoListView = new KOTodoListView(calendar,this, name ); topLayout->addWidget(mTodoListView); //mTodoListView->header()->setMaximumHeight(30); mTodoListView->setRootIsDecorated(true); mTodoListView->setAllColumnsShowFocus(true); @@ -1105,27 +1112,27 @@ void KOTodoView::popupMenu(QListViewItem *item,const QPoint &p,int column) { pendingSubtodo = 0; mActiveItem = (KOTodoViewItem *)item; if (item) { switch (column){ case 1: mPriorityPopupMenu->popup(QCursor::pos ()); break; case 2: mPercentageCompletedPopupMenu->popup(QCursor::pos ()); break; case 3: moveTodo(); break; - case 8: + case 7: mCategoryPopupMenu->popup(QCursor::pos ()); break; - case 9: + case 8: mCalPopupMenu->popup(QCursor::pos ()); break; default: mItemPopupMenu->popup(QCursor::pos()); } } else mPopupMenu->popup(QCursor::pos()); } void KOTodoView::newTodo() { emit newTodoSignal(); } void KOTodoView::newSubTodo() |