The QML parser has callbacks for processing the Import list and for processing
individual imports. In qdoc, I used the one that gets the entire import list:
virtual bool visit(UiImportList *) { return true; }
virtual bool visit(UiImport *) { return true; }
I assumed it would bet called once, when the entire import list had been
parsed. My import list has three imports in it.
import QtQuick 2.1
import QtQuick.Controls 1.1
import QtQuick.Controls.Private 1.0
The import list visit() function is indeed called with a pointer to the first
entry in the list of three imports, and qdoc processes all three imports.
But then it is called again pointing at the second import in the list, and qdoc
processes the last two imports again. And then it is called a third time
pointing at the third entry in the list, and qdoc processes the last entry a
third time.
Is that behaviour correct, or should the parser only visit the list once when
it is complete?
martin
_______________________________________________
Development mailing list
[email protected]
http://lists.qt-project.org/mailman/listinfo/development