forked from qt-creator/qt-creator
QmlInspector: Added reparenting of items in the Qml Live Preview. Reviewed by: Lasse Holmstedt
This commit is contained in:
@@ -313,6 +313,20 @@ void QmlJSDesignDebugClient::destroyQmlObject(int debugId)
|
||||
sendMessage(message);
|
||||
}
|
||||
|
||||
void QmlJSDesignDebugClient::reparentQmlObject(int debugId, int newParent)
|
||||
{
|
||||
if (!m_connection || !m_connection->isConnected())
|
||||
return;
|
||||
QByteArray message;
|
||||
QDataStream ds(&message, QIODevice::WriteOnly);
|
||||
|
||||
ds << QByteArray("MOVE_OBJECT")
|
||||
<< debugId
|
||||
<< newParent;
|
||||
|
||||
sendMessage(message);
|
||||
}
|
||||
|
||||
|
||||
void QmlJSDesignDebugClient::applyChangesToQmlFile()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user