added new empty split actions and fixed a few loopy bugs with double select files.

This commit is contained in:
mae
2009-01-20 17:06:46 +01:00
parent c0c5342386
commit ed5afa14dd
12 changed files with 77 additions and 65 deletions

View File

@@ -216,22 +216,7 @@ void ProjectWindow::updateTreeWidget()
m_treeWidget->addTopLevelItem(item);
if (m_projectExplorer->currentProject() == project) {
m_treeWidget->setCurrentItem(item, 0, QItemSelectionModel::SelectCurrent | QItemSelectionModel::Rows);
}
}
if (!m_treeWidget->currentItem()) {
if (m_treeWidget->topLevelItemCount() > 0)
m_treeWidget->setCurrentItem(m_treeWidget->topLevelItem(0), 0, QItemSelectionModel::SelectCurrent | QItemSelectionModel::Rows);
else
handleCurrentItemChanged(0);
}
// Hack around Qt bug
m_treeWidget->viewport()->update();
}
@@ -255,10 +240,6 @@ void ProjectWindow::handleCurrentItemChanged(QTreeWidgetItem *current)
return;
}
}
// we only get here if either current is zero or we didn't find a project for the path
m_projectExplorer->setCurrentFile(0, QString());
showProperties(0, QModelIndex());
}