forked from qt-creator/qt-creator
QmlJSEditor: Move semantic info updating to document
Change-Id: I804dbd887af1786e7554ec79f94fc8e59db1de5b Reviewed-by: Fawzi Mohamed <fawzi.mohamed@digia.com>
This commit is contained in:
@@ -49,9 +49,9 @@ using namespace QmlJS::AST;
|
||||
|
||||
Information about the imports of a Document can be accessed with imports().
|
||||
|
||||
When dealing with a QmlJSEditor::QmlJSTextEditorWidget it is unnecessary to
|
||||
When dealing with a QmlJSEditor::QmlJSEditorDocument it is unnecessary to
|
||||
construct a new Context manually. Instead use
|
||||
QmlJSTextEditorWidget::semanticInfo()::context.
|
||||
QmlJSEditorDocument::semanticInfo()::context.
|
||||
*/
|
||||
|
||||
ContextPtr Context::create(const QmlJS::Snapshot &snapshot, ValueOwner *valueOwner,
|
||||
|
||||
@@ -130,7 +130,7 @@ public:
|
||||
Initializes a context by resolving imports. This is an expensive operation.
|
||||
|
||||
Instead of making a fresh context, consider reusing the one maintained in the
|
||||
\l{QmlJSEditor::SemanticInfo} of a \l{QmlJSEditor::QmlJSTextEditorWidget}.
|
||||
\l{QmlJSEditor::SemanticInfo} of a \l{QmlJSEditor::QmlJSEditorDocument}.
|
||||
*/
|
||||
|
||||
Link::Link(const Snapshot &snapshot, const ViewerContext &vContext, const LibraryInfo &builtins)
|
||||
|
||||
@@ -50,9 +50,9 @@ using namespace QmlJS;
|
||||
It is an error to use the same ScopeChain from multiple threads; use a copy.
|
||||
Copying is cheap. Initial construction is currently expensive.
|
||||
|
||||
When a QmlJSEditor::QmlJSTextEditorWidget is available, there's no need to
|
||||
When a QmlJSEditor::QmlJSEditorDocument is available, there's no need to
|
||||
construct a new ScopeChain. Instead use
|
||||
QmlJSTextEditorWidget::semanticInfo()::scopeChain().
|
||||
QmlJSEditorDocument::semanticInfo()::scopeChain().
|
||||
*/
|
||||
|
||||
QmlComponentChain::QmlComponentChain(const Document::Ptr &document)
|
||||
|
||||
Reference in New Issue
Block a user