aboutsummaryrefslogtreecommitdiffstats
path: root/qt-qml
Commit message (Collapse)AuthorAgeFilesLines
* README: Add `doc-snapshots.qt.io` as pre-release version documentationOrkun Tokdemir2024-12-161-0/+3
| | | | | | | Pick-to: 1.1.0 Change-Id: I7b818025dd1684620f855dbd14b21d4c50481e23 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* Refactor communication between core and extensionsOrkun Tokdemir2024-12-123-10/+61
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In the previous implementation, the extensions were using only one way to communicate with each other, which was getting a notification when a config value was set or changed. This was problematic on startup because there was no order in which the extensions were activated and when messages were handled. b5bf26ac084823758be18453bb61579fefceb57c partially fixed this issue by adding a way to wait for `qt-cpp` to be ready, but it was still not enough. The extension should read config values when they are ready, not when messages are sent from other extensions. Remove the `lazy` initialization parameter in `Project` classes. Instead of using that parameter, we remove the firing event from `addProject()` and only fire when the project is added after startup. This way, we don't need the `lazy` parameter anymore. Since `processMessage()` is not used during startup, this commit also fixes QTBUG-131702 on the extension side. qt-lib: This commit changes `QtWorkspaceConfigMessage` and removes values in it. `QtWorkspaceConfigMessage` is now used only to notify that a value or values were set. The value `CoreApi` can be accessed by `getValue` and `setValue`. * Update the `CoreApi` interface * Add `setValue` * Rename `update` to `notify` * Remove `get<T>()` from `QtWorkspaceConfigMessage` qt-core: * Remove the internal checking mechanism to understand if a value was set or changed. Instead, just store values. qt-cpp: * Update `processMessage()` for the new usage. * Initialize config values explicitly during startup. qt-qml: * Update `processMessage()` for the new usage. * Separate starting `qmlls` from the constructor. It should be started when the conditions are met. * Get config values and update parameters inside `onProjectAdded()` Task-number: QTBUG-131702 Change-Id: If9831ea1257d123f777e6ae2afb92f33942dd3da Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* Bump version to 1.3.0Orkun Tokdemir2024-12-092-4/+4
| | | | | Change-Id: Iab1c9f545d8b10ad13127a3a77545a3f4f475597 Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* qt-qml: qt-ui: Wait until qt-cpp is activatedOrkun Tokdemir2024-12-091-2/+8
| | | | | | | | | During the startup,`qt-qml` and `qt-ui` should wait until `qt-cpp`` sets the initial configuration values. Otherwise, qt-qml qt-ui may not be able to access the correct configuration values. Change-Id: I974a0e5e7e9cb541ea4a382ac85c303b6b59646f Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* qt-qml: Order qmlls assets by creation date before comparingOrkun Tokdemir2024-12-061-8/+12
| | | | | | | | When multiple assets exist for the same platform on https://qtccache.qt.io/QMLLS/LatestRelease, use the newest. Change-Id: I0e129b40bd8466fcc1d654fc5f02dd73205eab5d Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* qt-qml: Update CHANGELOG.mdOrkun Tokdemir2024-12-051-0/+18
| | | | | | Change-Id: I8683a3990b889936dcad36127b3381403521d203 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* qt-qml: Add files to test syntax highlightingBen Cho2024-12-0312-0/+519
| | | | | | | | Added a qmldir file and .qml files to test regex-based syntax highlighting. Change-Id: I1a124fc10801576f04b23f6644bb351418c91b6a Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* qt-qml: Add reset commandOrkun Tokdemir2024-11-292-1/+18
| | | | | | Fixes: VSCODEEXT-98 Change-Id: I46bdef0ef83632be50206e1d1c8812cbbe22d9a8 Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* Dispose event handlers and language client when the project is closedOrkun Tokdemir2024-11-282-2/+11
| | | | | | | | | | | Since event handlers are not disposed properly, they are still active when the project is closed. This can cause those handlers to be called after the project is closed, which can lead to errors. * Dispose project managers inside `Deactivate()` Change-Id: Idd7b8548f7c16c41c0e4fd7052fa7ae988678bc4 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* qt-qml: Add `doNotAskForQmllsDownload`Orkun Tokdemir2024-11-284-3/+39
| | | | | | | | | | | When either users don't want to use the QML Language Server or they have `qt-qml.qmlls.customExePath` set, showing the download prompt could be annoying. This commit adds a new setting `doNotAskForQmllsDownload` to disable the download prompt. Change-Id: I5fb0712c94e97ad91f3f0a52e6176a12dffc7712 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* qt-qml: Fix syntax highlighting for QML filesBen Cho2024-11-271-3/+16
| | | | | | | | | When an object is used as a property value, it is highlighted incorrectly. This patch fixes that issue. Task-number: VSCODEEXT-105 Change-Id: I8cc4f206ed181be945674b5512b78260d321ad30 Reviewed-by: Orkun Tokdemir <orkun.tokdemir@qt.io>
* qt-cpp: qt-qml: Add build directoryOrkun Tokdemir2024-11-253-0/+27
| | | | | | | | * Pass the build directory to qmlls with `-b` * Detect the build directory change from the CMake extension Change-Id: I8279b444036e174762f9d469fd8b4abdaba66e83 Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* Fix wrong value evaluation for `processMessage()`Orkun Tokdemir2024-11-221-9/+17
| | | | | | | | | | When only the value is checked whether it is undefined or not, it doesn't give us the correct result because the value either can be set to undefined or not set at all. We get undefined in both cases. We should check the key is set in the message first instead. Change-Id: Ic4c17e96c3975adcbc49eb82e7b1999d3dcec851 Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* Speed up compilation by using the `--incremental` flagOrkun Tokdemir2024-11-212-0/+2
| | | | | | | https: //www.typescriptlang.org/tsconfig/#incremental Change-Id: I750398a09178e02c3b3c73bf8e8fc7654dab03d4 Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* qt-qml: Add `-I` and `-E` options to qmllsOrkun Tokdemir2024-11-214-2/+138
| | | | | | | | | | | | | * Add message handling to `qt-qml` extension * Pass qml import obtained from either `qtpaths` or Qt installation * Add `additionalImportPaths` to get additional import paths from the user. * Add `useQmlImportPathEnvVar` to pass `-E` option to qmlls. Fixes: VSCODEEXT-104 Change-Id: Ic84bf7a6834d2d84b738e759a69c27ba47bf1fc5 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* vscodeignore: Add `.eslintcache`Orkun Tokdemir2024-11-211-0/+1
| | | | | | | | | | `.eslintcache` is added to .vsix files, so it should be added to the `.vscodeignore` files to discard them. Amends: 8570300bf7eb20e13f397319dd506ae1a5600a82 Change-Id: I36102382ec29d9e9d1f0060f32c23df6364761ed Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* Package: Fix high severity vulnerabilitiesOrkun Tokdemir2024-11-201-3/+4
| | | | | | | * Run `npm audit fix` to fix them. Change-Id: Iab3b1fd524e70bae930c03025ae10683fac07046 Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* qt-core: qt-qml: Use optional chaining to reduce indentationOrkun Tokdemir2024-11-192-10/+6
| | | | | Change-Id: I396aaf055f35c7c67ec7c760c61a16b12c8c322b Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* qt-qml: Abort downloading qmlls when users cancelOrkun Tokdemir2024-11-191-3/+7
| | | | | | | | | | | In the previous implementation, the download process continued even after the user canceled the download. This commit fixes the issue by aborting the download when the user cancels it. * Use optional chaining to reduce indentation Change-Id: I6603d0cb76078e89e33b592cea39f717fb8ba2a2 Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* qt-qml: Add progress bar to fetching qmlls infoOrkun Tokdemir2024-11-142-24/+55
| | | | | | | | | * Move `fetchWithAbort()` to `qt-lib` * Add progress bar option to `fetchAssetAndDecide()` * Use `fetchWithAbort()` instead of `fetch()` in `fetchAssetAndDecide()` Change-Id: Ifd054d96427a89c9e24ac130a7362afe014ee8de Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* qt-qml: Add workspaceFolder scope to `qmlls`Orkun Tokdemir2024-11-131-1/+7
| | | | | | | Amends f6b80894533915ac70656058c9155960fc99a0c9 Change-Id: I543865c9f54396fc1c1816e0186787b46646fe47 Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* qt-qml: Adapt qmlls usage with multiple projectsOrkun Tokdemir2024-11-126-46/+76
| | | | | | | | | | | | | | * Remove the global qmlls usage * Start qmlls instance for each project * Use configuration per project instead of global configuration * Use `workspaceFolder` scope for qmlls configuration * Implement `QMLProjectManager` - When a new version of the QML language server is available, restart all qmlls instances. * Prepare codebase for `qmlls` cli parameters per project Change-Id: If4bbd7f99da5ebd054a550419afa985bd65b2f3f Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* Add telemetryOrkun Tokdemir2024-11-085-2/+348
| | | | | | | | | | * Send events when commands are executed * Add https://www.npmjs.com/package/@vscode/extension-telemetry * Update ThirdPartyNotices.txt Task-number: VSCODEEXT-62 Change-Id: I7c88b0db55fa14da6d66025e7fa4458726f5ce6b Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* Package: Update dependencies & third party licensesOrkun Tokdemir2024-11-063-415/+1224
| | | | | Change-Id: I14aaf1beb358e3efc5b81c362e8fbae4126c39d3 Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* ci-scripts: Remove qt-lib license from ThirdPartyNotices.txtOrkun Tokdemir2024-11-061-185/+0
| | | | | | | | | We already put the dependencies of qt-lib in the ThirdPartyNotices.txt. So we don't need to put the license of qt-lib in the ThirdPartyNotices.txt. Change-Id: I1cb24acd46ed3f0852be6d15667f2d01361fb179 Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* Bump version to 1.1.0Orkun Tokdemir2024-11-052-4/+4
| | | | | Change-Id: I5b32ad2e96a63f43ed54c8cb6e30fd800159cc01 Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* qt-qml: Add commands for QML language server installationBen Cho2024-10-287-28/+151
| | | | | | | | | | | | | | | | Add two commands to enhance user control over installation status. * `checkQmllsUpdate` checks for recent updates on the server and provides a window to ask the user whether to install it. * `downloadQmlls` downloads and install qmlls regardless of the current installation status. This could be useful when the user wants to reinstall from scratch. Task-number: VSCODEEXT-68 Change-Id: I293b17fdfdd478b16753b6f6b1346a11716f1b2f Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io> Reviewed-by: Orkun Tokdemir <orkun.tokdemir@qt.io>
* qt-qml: Fix invalid file stream creation on directory entryBen Cho2024-10-281-0/+4
| | | | | Change-Id: I27282a7e316f847e62e8751cb9eb52ea38a4aff2 Reviewed-by: Orkun Tokdemir <orkun.tokdemir@qt.io>
* Package: Add `--cache` option for PrettierOrkun Tokdemir2024-10-251-1/+1
| | | | | Change-Id: I3672e4fb4e2f4c034b20783333ccb19473b614bc Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* ci-scripts: Improve local license file validationOrkun Tokdemir2024-10-251-37/+13
| | | | | | | | * If a local license name includes `license` somehow, consider it as a license file. Change-Id: Ib5f999c81905d7618155fdd2ebb5a562a7a0d739 Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* Linter: Improve checksOrkun Tokdemir2024-10-231-0/+1
| | | | | | | | * Fix linting errors Change-Id: I933d8070b470a56db33451db7638d0d74744015e Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io> Reviewed-by: Ben Cho <ben.cho@qt.io>
* qt-qml: Add facility to download the latest qmlls binaryBen Cho2024-10-227-10/+499
| | | | | | | | | | | | | Add feature to download the qmlls from central server. The extension checks for a new qmlls release at startup using server-provided JSON, which includes version and binary locations. If an update is available, the binary is installed in `UserLocalDir`. Task-number: VSCODEEXT-68 Change-Id: Iff179def26d233e6089faf2d6a1864e87b11ef9a Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io> Reviewed-by: Orkun Tokdemir <orkun.tokdemir@qt.io>
* ci-scripts: Add caching for eslintOrkun Tokdemir2024-10-221-1/+1
| | | | | | | | * Add caching for eslint * Gather commands together in package.json Change-Id: I3169cff2974a29a2ddd7daa97d3e8560420b1e06 Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* qt-qml: Add missing license headerBen Cho2024-10-211-0/+3
| | | | | Change-Id: I6622d0decd8c788bcd6573838a20de261fc1e896 Reviewed-by: Orkun Tokdemir <orkun.tokdemir@qt.io>
* Improve consistency, remove duplication on project and project managerBen Cho2024-10-152-5/+5
| | | | | | | | | | The `ProjectManager` classes in qt-core, qt-cpp are now derived from the `ProjectManager` template class in qt-lib. Rename `ProjectBase` to `Project` for simplcity and consistency. Change-Id: I66492028f43eb8822e2be5cde87de8a97c214381 Reviewed-by: Orkun Tokdemir <orkun.tokdemir@qt.io> Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* Remove indirectly used dependenciesOrkun Tokdemir2024-10-143-323/+13
| | | | | | | | | * Since `winston` and `winston-transport-vscode` are used in `qt-lib`, we don't need to specify them in `qt-cpp` and `qt-qml` as dependencies * Update `ThirdPartyNotices.txt` for `qt-cpp` and `qt-qml` Change-Id: I892dba5fef97ff0c10b6968c92cc981138fbb75f Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* Add tilde support for configuration pathsOrkun Tokdemir2024-10-144-2/+34
| | | | | | | | | | | * Add tilde support for `qt-cpp.installationRoot`, `qt-cpp.qtadditionalQtPaths`, `qt-qml.qmlls.customExePath` and `qt-ui.customWidgetsDesignerExePath`. * Update the `package.json` files * Update ThirdPartyNotices.txt Change-Id: Ieefda914b46e78882cc18dd98eef86d26399f1b8 Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* Style: Shorten the exe suffix variableOrkun Tokdemir2024-10-071-2/+2
| | | | | Change-Id: Id7b61cc70c97b3e859a0004bb206e970ca51f17e Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* qt-qml: Remove one of duplicated functionsBen Cho2024-10-071-8/+1
| | | | | | Change-Id: I138089a389e6c9c6ab78f3f7238a38232e7203d0 Reviewed-by: Orkun Tokdemir <orkun.tokdemir@qt.io> Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* Linter: Improve checksOrkun Tokdemir2024-09-231-0/+2
| | | | | | | | ESlint doesn't fail when a private method is not used in the class. We can detect it via `tsconfig.json`. Change-Id: I9de96572a01841535ddbcde62223535a8b794950 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Package: Remove additional commands from `npm run package`Orkun Tokdemir2024-09-191-1/+1
| | | | | | | | Since we build extension via ci-scripts, we don't need additional commands in `npm run package` script. Change-Id: If6d7a4dfc8e4423534a12bab48114823281566fa Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* Package: Run `npm audit fix` to resolve vulnerabilitiesOrkun Tokdemir2024-09-171-3/+4
| | | | | Change-Id: I3230828fed10d2d4ae5b2ce9428deb99b66d8c6a Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* Package: Add commit hash file to packageOrkun Tokdemir2024-09-161-1/+1
| | | | | | | | | | | | * Add `package.ts` to handle the packaging of extensions * Add `publish_ext_pack.ts` to hande the publishing of extension packs inside `.ts` scripts * Add generation of commit hash file to every extension and extension pack * Remove commit hash file after publishing and packaging Change-Id: Ic6ecd59ab3d045a7022e9322a75a07833a3885de Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
* Reuse: Remove root dep5 file and add dep5 files to extensionsOrkun Tokdemir2024-09-161-0/+8
| | | | | | | | | | | * Remove root dep5 file * Add dep5 files to both qt-qml and qt-core extensions * Change the wrong copyright owner for `qss.tmLanguage.json` Amends 9153f975f97a9b35c1c6ad58e9ffa6f486ea1635 Change-Id: Iddbf77e53042d1804efbaed53b18e65338dbdaa0 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Package: Update package-lock.json versionsOrkun Tokdemir2024-09-101-2/+2
| | | | | Change-Id: I589b400f22ba6a87bc931e3c5c7f0ce4d2dea622 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Package: Remove `preview`Orkun Tokdemir2024-09-101-1/+0
| | | | | Change-Id: I7b1a6b474a77fb7ca68f0951a1f8b6a44e6fbf33 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* qt-qml: Update version to 1.0.0qt-qml/1.0.0Orkun Tokdemir2024-09-102-1/+7
| | | | | | | | * Update `CHANGELOG.md` and `package.json` Change-Id: I1c0d0264b162bafa056302efdf40946a0dc2776c Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* Doc: Update `README.md` filesOrkun Tokdemir2024-09-093-37/+21
| | | | | | | | | | | | * Remove `README-marketplace.md` files * Move content from `README-marketplace.md` to `README.md` * Update `README.md` files * Add missing sections to `README.md` files * Remove `--readme-path doc/README-marketplace.md` parameter Change-Id: I0a7d635d37e6d75551b29bb646c94ef084b02e64 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* Doc: Edit the MD docsLeena Miettinen2024-09-092-160/+16
| | | | | | | | | | | | - Remove general instructions and point to the snapshot at doc.qt.io - Remove lists of extensions as they are listed automatically in VS Code Extensions - Make the instructions about getting started with the extension packs and the contents of the extensions Change-Id: I77eb488d53dc83c90569048d809e40b52fc2488e Reviewed-by: Orkun Tokdemir <orkun.tokdemir@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* qt-qml: Enable qmlls by defaultOrkun Tokdemir2024-09-062-5/+6
| | | | | | | | | | * Update package.json to enable qmlls by default. * Use an information message instead of an error message when the qmlls extension is not found. Change-Id: I50fc67635b303be147ed71fc05a1c7797413a6b4 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>