forked from qt-creator/qt-creator
qmljs: correctly handle required and readonly properties
* correct indentation after required property QTCREATORBUG-24144 * handle required <name> statement * allow default readoly required reordering * more permissive than the actual parser (which then will show errors for invalid sequences) * backport form QmlDom Fixes: QTCREATORBUG-24144 Change-Id: I19166ca65d108d533a1ed3748c09e35bcfdbc56d Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
This commit is contained in:
@@ -669,6 +669,14 @@ protected:
|
||||
return false;
|
||||
}
|
||||
|
||||
bool visit(UiRequired *ast) override
|
||||
{
|
||||
out(ast->requiredToken);
|
||||
out(" ");
|
||||
out(ast->name.toString());
|
||||
return true;
|
||||
}
|
||||
|
||||
bool visit(UiObjectBinding *ast) override
|
||||
{
|
||||
if (ast->hasOnToken) {
|
||||
|
||||
Reference in New Issue
Block a user