QmlProject: Propose to open QDS for any .ui.qml file

This is only enabled if no QmlDesigner plugin is found.

When a .ui.qml file is opened we check for a QDS installation.
If QDS is installed we propose to open QDS instead, if not
we show information on QDS.

Search oder for .qmlproject file. QDS requires a project file.

* Check if current project is .qmlproject
* Check if the current folder contains a .qmlproject
* Check folder for .qmlproject that contains the .ui.qml file
* Check parent folder for .qmlproject ...

If not .qmlproject is found we show an error message.
Enabling external link support for InfoBar.

Task-number: QDS-5065
Task-number: QDS-5066
Change-Id: I2c70c400c4d11b83a4848f9e002e180fa119f6e2
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
This commit is contained in:
Thomas Hartmann
2021-09-21 12:31:19 +02:00
parent 64e48988ed
commit ddccb87a87
4 changed files with 186 additions and 35 deletions

View File

@@ -26,6 +26,7 @@
#pragma once
#include <extensionsystem/iplugin.h>
#include <utils/filepath.h>
namespace QmlProjectManager {
namespace Internal {
@@ -39,6 +40,10 @@ public:
QmlProjectPlugin() = default;
~QmlProjectPlugin() final;
static void openQDS(const Utils::FilePath &fileName);
static QString qdsInstallationEntry();
static bool qdsInstallationExists();
private:
bool initialize(const QStringList &arguments, QString *errorString) final;