forked from qt-creator/qt-creator
QmlDesigner: Add invalid ids to QmlJSCheck
Also improving document message for exceptions. Change-Id: I7878987ce73f5d4891ced3c702c7804b25b07eb3 Reviewed-by: Miikka Heikkinen <miikka.heikkinen@qt.io>
This commit is contained in:
@@ -570,7 +570,8 @@ public:
|
|||||||
"x", "y", "opacity", "parent", "item", "flow",
|
"x", "y", "opacity", "parent", "item", "flow",
|
||||||
"color", "margin", "padding", "print", "border", "font",
|
"color", "margin", "padding", "print", "border", "font",
|
||||||
"text", "source", "state", "visible", "focus", "data",
|
"text", "source", "state", "visible", "focus", "data",
|
||||||
"clip", "layer", "scale", "enabled", "anchors"})
|
"clip", "layer", "scale", "enabled", "anchors",
|
||||||
|
"texture", "shaderInfo", "sprite", "spriteSequence", "baseState"})
|
||||||
{}
|
{}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@@ -42,7 +42,7 @@ DocumentMessage::DocumentMessage(Exception *exception):
|
|||||||
m_line(exception->line()),
|
m_line(exception->line()),
|
||||||
m_column(-1),
|
m_column(-1),
|
||||||
m_description(exception->description()),
|
m_description(exception->description()),
|
||||||
m_url(exception->file())
|
m_url(QUrl::fromLocalFile(exception->file()))
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -84,14 +84,14 @@ QString DocumentMessage::toString() const
|
|||||||
if (line() != -1) {
|
if (line() != -1) {
|
||||||
if (!str.isEmpty())
|
if (!str.isEmpty())
|
||||||
str += QLatin1Char(' ');
|
str += QLatin1Char(' ');
|
||||||
str += ::QmlDesigner::DocumentMessage::tr("line %1").arg(line());
|
str += ::QmlDesigner::DocumentMessage::tr("line %1\n").arg(line());
|
||||||
}
|
}
|
||||||
|
|
||||||
if (column() != -1) {
|
if (column() != -1) {
|
||||||
if (!str.isEmpty())
|
if (!str.isEmpty())
|
||||||
str += QLatin1Char(' ');
|
str += QLatin1Char(' ');
|
||||||
|
|
||||||
str += ::QmlDesigner::DocumentMessage::tr("column %1").arg(column());
|
str += ::QmlDesigner::DocumentMessage::tr("column %1\n").arg(column());
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!str.isEmpty())
|
if (!str.isEmpty())
|
||||||
|
Reference in New Issue
Block a user