MCPcopy Create free account
hub / github.com/aldelaro5/dolphin-memory-engine / simplifySelection

Method simplifySelection

Source/GUI/MemWatcher/MemWatchWidget.cpp:687–702  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

685}
686
687QModelIndexList MemWatchWidget::simplifySelection() const
688{
689 QModelIndexList simplifiedSelection;
690 QModelIndexList selection = m_watchView->selectionModel()->selectedRows();
691
692 // Discard all indexes whose parent is selected already
693 for (int i = 0; i < selection.count(); ++i)
694 {
695 const QModelIndex index = selection.at(i);
696 if (!isAnyAncestorSelected(index))
697 {
698 simplifiedSelection.append(index);
699 }
700 }
701 return simplifiedSelection;
702}
703
704bool MemWatchWidget::isAnyAncestorSelected(const QModelIndex& index) const
705{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected