Skip to content
Snippets Groups Projects
Commit 6ea355ad authored by Thomas Hartmann's avatar Thomas Hartmann
Browse files

QmlDesigner.instanceView: do not skip Models anymore

We only skip Model if they are the root node.
I kept the isSkippedNode since it might become useful again.
parent 6c8a1612
No related branches found
No related tags found
No related merge requests found
...@@ -140,9 +140,9 @@ NodeInstanceView::~NodeInstanceView() ...@@ -140,9 +140,9 @@ NodeInstanceView::~NodeInstanceView()
\param model Model to which the view is attached \param model Model to which the view is attached
*/ */
bool isSkippedNode(const ModelNode &node) bool isSkippedRootNode(const ModelNode &node)
{ {
static QStringList skipList = QStringList() << "Qt.ListModel" << "QtQuick.ListModel"; static QStringList skipList = QStringList() << "Qt.ListModel" << "QtQuick.ListModel" << "Qt.ListModel" << "QtQuick.ListModel";
if (skipList.contains(node.type())) if (skipList.contains(node.type()))
return true; return true;
...@@ -150,6 +150,12 @@ bool isSkippedNode(const ModelNode &node) ...@@ -150,6 +150,12 @@ bool isSkippedNode(const ModelNode &node)
return false; return false;
} }
bool isSkippedNode(const ModelNode &)
{
return false;
}
void NodeInstanceView::modelAttached(Model *model) void NodeInstanceView::modelAttached(Model *model)
{ {
AbstractView::modelAttached(model); AbstractView::modelAttached(model);
...@@ -157,7 +163,7 @@ void NodeInstanceView::modelAttached(Model *model) ...@@ -157,7 +163,7 @@ void NodeInstanceView::modelAttached(Model *model)
m_lastCrashTime.start(); m_lastCrashTime.start();
connect(m_nodeInstanceServer.data(), SIGNAL(processCrashed()), this, SLOT(handleChrash())); connect(m_nodeInstanceServer.data(), SIGNAL(processCrashed()), this, SLOT(handleChrash()));
if (!isSkippedNode(rootModelNode())) if (!isSkippedRootNode(rootModelNode()))
nodeInstanceServer()->createScene(createCreateSceneCommand()); nodeInstanceServer()->createScene(createCreateSceneCommand());
} }
...@@ -195,7 +201,7 @@ void NodeInstanceView::restartProcess() ...@@ -195,7 +201,7 @@ void NodeInstanceView::restartProcess()
m_nodeInstanceServer = new NodeInstanceServerProxy(this, m_runModus); m_nodeInstanceServer = new NodeInstanceServerProxy(this, m_runModus);
connect(m_nodeInstanceServer.data(), SIGNAL(processCrashed()), this, SLOT(handleChrash())); connect(m_nodeInstanceServer.data(), SIGNAL(processCrashed()), this, SLOT(handleChrash()));
if (!isSkippedNode(rootModelNode())) if (!isSkippedRootNode(rootModelNode()))
nodeInstanceServer()->createScene(createCreateSceneCommand()); nodeInstanceServer()->createScene(createCreateSceneCommand());
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment