Fixed indentation of single line QML/JS comments.

This commit is contained in:
Roberto Raggi
2010-01-15 12:27:25 +01:00
parent 9ac98a402c
commit ed1414a406

View File

@@ -226,8 +226,10 @@ QString QScriptIndenter::trimmedCodeLine(const QString &t)
int e = token.length;
if (token.offset > 0 || startState == 0) {
trimmed.append(QLatin1String("/*"));
i += 2;
if (token.length >= 2 && t.midRef(token.offset, 2) == QLatin1String("/*")) {
trimmed.append(QLatin1String("/*"));
i += 2;
}
}
bool needEndOfComment = false;