MCPcopy Create free account
hub / github.com/KDE/kdevelop / selectPreviousItem

Method selectPreviousItem

plugins/grepview/grepoutputview.cpp:376–387  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

374}
375
376void GrepOutputView::selectPreviousItem()
377{
378 if (!model()) {
379 return;
380 }
381
382 QModelIndex prev_idx = model()->previousItemIndex(resultsTreeView->currentIndex());
383 if (prev_idx.isValid()) {
384 resultsTreeView->setCurrentIndex(prev_idx);
385 model()->activate(prev_idx);
386 }
387}
388
389void GrepOutputView::selectNextItem()
390{

Callers 1

selectPrevItemMethod · 0.45

Calls 6

modelFunction · 0.85
previousItemIndexMethod · 0.80
setCurrentIndexMethod · 0.80
currentIndexMethod · 0.45
isValidMethod · 0.45
activateMethod · 0.45

Tested by

no test coverage detected