diff options
author | hjk <hjk@theqtcompany.com> | 2016-06-10 10:37:49 +0200 |
---|---|---|
committer | hjk <hjk@theqtcompany.com> | 2016-06-15 08:55:16 +0000 |
commit | b281d6dad7aa43410387dbf06df07ac5f3716d42 (patch) | |
tree | 6d10a147a9278594ee3d764d098e4ad717b4ee46 /src/plugins/projectexplorer/toolchainoptionspage.cpp | |
parent | 0c1cdc3a4aea1ebc3e8ce093576c9fc8b4ba281c (diff) |
TreeModel: Introduce a StaticTreeItem
This splits out the case of static string displays from the
TreeItem base class, making the base more lightweight.
Change-Id: If1f442011ec60094399a41b65d9b5015f432f82e
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Diffstat (limited to 'src/plugins/projectexplorer/toolchainoptionspage.cpp')
-rw-r--r-- | src/plugins/projectexplorer/toolchainoptionspage.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins/projectexplorer/toolchainoptionspage.cpp b/src/plugins/projectexplorer/toolchainoptionspage.cpp index 9f1ece689a..aee4ac0f10 100644 --- a/src/plugins/projectexplorer/toolchainoptionspage.cpp +++ b/src/plugins/projectexplorer/toolchainoptionspage.cpp @@ -114,8 +114,8 @@ public: [](ToolChainFactory *factory) { return factory->canCreate();}); m_model.setHeader(QStringList() << ToolChainOptionsPage::tr("Name") << ToolChainOptionsPage::tr("Type")); - m_autoRoot = new TreeItem(QStringList() << ToolChainOptionsPage::tr("Auto-detected") << QString()); - m_manualRoot = new TreeItem(QStringList() << ToolChainOptionsPage::tr("Manual") << QString()); + m_autoRoot = new StaticTreeItem({ ToolChainOptionsPage::tr("Auto-detected") }); + m_manualRoot = new StaticTreeItem({ ToolChainOptionsPage::tr("Manual") }); m_model.rootItem()->appendChild(m_autoRoot); m_model.rootItem()->appendChild(m_manualRoot); foreach (ToolChain *tc, ToolChainManager::toolChains()) { |