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

Method moveDependencyDown

kdevplatform/project/widgets/dependencieswidget.cpp:78–90  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

76}
77
78void DependenciesWidget::moveDependencyDown()
79{
80 QList<QListWidgetItem*> list = m_ui->dependencies->selectedItems();
81 if( !list.isEmpty() )
82 {
83 Q_ASSERT( list.count() == 1 );
84 QListWidgetItem* item = list.at( 0 );
85 int row = m_ui->dependencies->row( item );
86 m_ui->dependencies->takeItem( row );
87 m_ui->dependencies->insertItem( row+1, item );
88 m_ui->dependencies->selectionModel()->select( m_ui->dependencies->model()->index( row+1, 0, QModelIndex() ), QItemSelectionModel::ClearAndSelect | QItemSelectionModel::SelectCurrent );
89 }
90}
91
92void DependenciesWidget::moveDependencyUp()
93{

Callers

nothing calls this directly

Calls 9

selectedItemsMethod · 0.80
selectMethod · 0.80
QModelIndexClass · 0.50
isEmptyMethod · 0.45
countMethod · 0.45
atMethod · 0.45
rowMethod · 0.45
indexMethod · 0.45
modelMethod · 0.45

Tested by

no test coverage detected