forked from qt-creator/qt-creator
ProjectExplorer: Shorten NodeType enum
Use a class enum with a type quint16 for the NodeType. Frees 2 bytes per node that can be used for better things now. Change-Id: Ib84bf8629e9f4a5fb0793355eff0f0d6302167dd Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
This commit is contained in:
@@ -533,7 +533,7 @@ void ProjectTreeWidget::initView()
|
||||
void ProjectTreeWidget::openItem(const QModelIndex &mainIndex)
|
||||
{
|
||||
Node *node = m_model->nodeForIndex(mainIndex);
|
||||
if (node->nodeType() != FileNodeType)
|
||||
if (node->nodeType() != NodeType::File)
|
||||
return;
|
||||
IEditor *editor = EditorManager::openEditor(node->filePath().toString());
|
||||
if (editor && node->line() >= 0)
|
||||
|
||||
Reference in New Issue
Block a user