Changeset View
Changeset View
Standalone View
Standalone View
src/kitemviews/kitemlistcontroller.cpp
Show First 20 Lines • Show All 452 Lines • ▼ Show 20 Line(s) | 451 | if (!shiftOrControlPressed) { | |||
---|---|---|---|---|---|
453 | m_selectionManager->setSelected(index, 1); | 453 | m_selectionManager->setSelected(index, 1); | ||
454 | } | 454 | } | ||
455 | 455 | | |||
456 | if (!shiftPressed) { | 456 | if (!shiftPressed) { | ||
457 | m_selectionManager->beginAnchoredSelection(index); | 457 | m_selectionManager->beginAnchoredSelection(index); | ||
458 | } | 458 | } | ||
459 | break; | 459 | break; | ||
460 | } | 460 | } | ||
461 | } | ||||
461 | 462 | | |||
463 | if (index < m_view->firstVisibleIndex() || index > m_view->lastVisibleIndex()) { | ||||
462 | m_view->scrollToItem(index); | 464 | m_view->scrollToItem(index); | ||
463 | } | 465 | } | ||
466 | | ||||
464 | return true; | 467 | return true; | ||
465 | } | 468 | } | ||
466 | 469 | | |||
467 | void KItemListController::slotChangeCurrentItem(const QString& text, bool searchFromNextItem) | 470 | void KItemListController::slotChangeCurrentItem(const QString& text, bool searchFromNextItem) | ||
468 | { | 471 | { | ||
469 | if (!m_model || m_model->count() == 0) { | 472 | if (!m_model || m_model->count() == 0) { | ||
470 | return; | 473 | return; | ||
471 | } | 474 | } | ||
▲ Show 20 Lines • Show All 871 Lines • Show Last 20 Lines |