m_fileToPath was not always updated correctly which lead
projectInfoForPath to return a wrong/invalid project info,
messing up the paths used by the code model.
Change-Id: If5e144f1ef2c7353b9077deb1b9c9aa9d1708651
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@theqtcompany.com>
builtins were always using qtimportPath, which is now being removed,
so prefer qtQmlPath.
Change-Id: I99d9214c2188507859f27b729c027aaf77eb579e
Reviewed-by: Tim Jenssen <tim.jenssen@theqtcompany.com>
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@theqtcompany.com>
qmltypes files were stored in the snapshot during scan, this is wrong
and bloats the memory usage.
Task-number: QTCREATORBUG-13369
Change-Id: Ie8c3970ad7a8d732230f3dc73a9ba65ab62ea4e9
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@theqtcompany.com>
If the qmljsmodel has no background task, then isIdle returns true
Change-Id: I31420343c560c5ed118f371f7be347eadb6622f4
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
setting QT_NO_CODE_INDEXER = 1 disables the qmljs code model,
as consequence the qml designer will not work with this setting.
Change-Id: I71a2989b14e55e4d130463edd4a6459dee3cbd3d
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
Qt 5.3 is the minimum requirement these days. Remove all fallback code
from sources and project files.
Change-Id: If6188a471197acadda4d6baee71804ba1a8026c6
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
We rely on string comparison for detection of QML import paths. Therefore
make sure that all paths are canonical.
Change-Id: I416bc31915644a888c416d726049668b0e71f29a
Task-number: QTCREATORBUG-12902
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@digia.com>
Language::Enum -> QmlDialect
* class instead of enum
* moved Language specific operations to it (from Document)
* nicer handling
QStringList -> PathsAndLanguages
* store language along with path, to perform a correct scan and improve
path handling
Change-Id: If69d35c63cfeb48aa670b51870916cd0c40f1916
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
ensure that the QSet copy operation of the scannedPaths in importScan
is atomic.
Change-Id: Ifb3566a86d1d6ac6abf29f1b4cbe19868947d0cc
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
This removes qmakeprojectmanager and qmlprojectmanager dependency on
qmljstools.
Qmlprojectmanager still imports qmltoolsconstants.h for a constant
but that gives no runtime dependency.
Change-Id: Ifd2e76500a3b27a21937603925f03a70049900e1
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
Reviewed-by: hjk <hjk121@nokiamail.com>
defaultVContext did call defaultProjectInfo which could
be called only from the ui thread (as it did check the current
project)
Now update the defaultProjectInfo via signals, and lock on access
making defaultProjectInfo threadsafe.
Task-number: QTCREATORBUG-12556
Change-Id: Ibffeb59bbcef7120f08766160bb1e2ddc9af2922
Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@digia.com>
This was an intentional, time-limited workaround that has
served its purpose now that we require C++11.
Change-Id: I96ece9c21bd405d281fd381bd9b87edc00c5ee84
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@digia.com>
The new function does properly update the latest snapshot.
Change-Id: If3148701e2f98c39a0822d1395b43f4fa7ee1949
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@digia.com>
Uniform handling of the different qml dialects.
Now paths for a given document prefer the project of that document.
For Qt the following sequence is used:
- Qt of the project of the document
- Qt of the active target
- Qt used to run creator
Currently all paths of the open projects are still merged, but that
can be changed.
Change-Id: Id302c13c893b66fbfe24e301602fe69de152eed4
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
moving original patch to master
This reverts commit c5b6e6ae1c60cb5692deef0db4c3dfbcf0859a1d
Change-Id: I84153a3aaf3ab5ca670ed62aa62babce5bbd51e9
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
Uniform handling of the different qml dialects.
Now paths for a given document prefer the project of that document.
For Qt the following sequence is used:
- Qt of the project of the document
- Qt of the active target
- Qt used to run creator
Currently all paths of the open projects are still merged, but that
can be changed.
Change-Id: Iacf28d63184c05e2bcdfe0210ec472d2bf140d66
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
allows to more easily scan the various qml dialects
Change-Id: I9f8c44459e05e4658d3814c624e0f07762c83279
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
Currently ModelManager contains lot logic, but as it sits in QmlJSTools
it is not possible to use it in standalone tests.
Moving most of the logic to ModelManagerInterface (and cleanup)
to allow better testing, and refactoring.
This introduces a dependency of the qmljs lib on the cplusplus lib
Also a (small) part of the CppTool::ModelManagerInterface has been
moved to CPlusPlus::CppModelManagerBase to remove the dependency on
CppTools to gather the Qml types exposed from C++.
Change-Id: Icad7fe96dfd0f1a2b1058d82bd98c77c40aa5e9d
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@digia.com>
* better support qbs and similar non QtQuick qml languages
* begin to clean and migrate things from ModelManager to
ModelManagerInterface
Change-Id: Ifa39dc1e4c568e9e21307f4913dcb5989e80420f
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@digia.com>
QDoc does some magic with the \class and \namespaces
and \brief commands, so the following wording must be used:
"The xxx class yyy ..."
Change-Id: Id231f30e8464898b776888d5423523de404aae34
Reviewed-by: Eike Ziller <eike.ziller@digia.com>