author | zautrix <zautrix> | 2005-08-05 21:04:00 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-08-05 21:04:00 (UTC) |
commit | 90585d5946407bdb8783bcb369ef7483c869995d (patch) (side-by-side diff) | |
tree | 10b1b1b2580e6f341d83522b13440925a55e108b | |
parent | 6bf157dca5ab703c7f1674c117cc62d9675f4bde (diff) | |
download | kdepimpi-90585d5946407bdb8783bcb369ef7483c869995d.zip kdepimpi-90585d5946407bdb8783bcb369ef7483c869995d.tar.gz kdepimpi-90585d5946407bdb8783bcb369ef7483c869995d.tar.bz2 |
fixxx
-rw-r--r-- | korganizer/kolistview.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/korganizer/kolistview.cpp b/korganizer/kolistview.cpp index e560ce4..b236c2d 100644 --- a/korganizer/kolistview.cpp +++ b/korganizer/kolistview.cpp @@ -1256,64 +1256,66 @@ void KOListViewListView::keyPressEvent ( QKeyEvent *e) cn = currentItem(); if ( cn ) { KOListViewItem* ci = (KOListViewItem*)( cn ); if ( ci ){ //emit showIncidence( ci->data()); cn = cn->nextSibling(); if ( cn ) { setCurrentItem ( cn ); ensureItemVisible ( cn ); } emit showIncidence( ci->data()); } } e->accept(); } break; case Qt::Key_Return: case Qt::Key_Enter: { QListViewItem* cn; cn = currentItem(); if ( cn ) { KOListViewItem* ci = (KOListViewItem*)( cn ); if ( ci ){ if ( e->state() == ShiftButton ) ci->setSelected( false ); else ci->setSelected( true ); cn = cn->nextSibling(); if ( cn ) { setCurrentItem ( cn ); ensureItemVisible ( cn ); + } else { + emit currentChanged( ci ); } } } e->accept(); } break; default: e->ignore(); } } KOListViewListView::KOListViewListView(KOListView * lv ) : KListView( lv, "kolistlistview", false ) { mYMousePos = 0; mPopupTimer = new QTimer(this); connect(mPopupTimer , SIGNAL(timeout()), this, SLOT(popupMenu())); #ifndef DESKTOP_VERSION //QPEApplication::setStylusOperation(viewport(), QPEApplication::RightOnHold ); #endif setSelectionMode( QListView::Multi ); setMultiSelection( true); } bool KOListViewListView::hasMultiSelection(QListViewItem* item) { QListViewItem *qitem = firstChild (); while ( qitem ) { if ( qitem->isSelected() && item != qitem ) return true; qitem = qitem->nextSibling(); } return false; } |