Ubuntu Pastebin

Paste from jgdx at Thu, 22 Sep 2016 12:44:08 +0000

Download as text
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
>      m_loader.setFileName(name);
>      if (Q_UNLIKELY(!m_loader.load())) {
>          qWarning() << m_loader.errorString() << name;
> @@ -143,13 +161,14 @@
>      QUrl componentUrl = m_data.value(key).toString();
>      if (!componentUrl.isEmpty()) {
>          if (componentUrl.isRelative()) {
> -            QDir dir(pluginQmlDir);
> -            if (dir.cd(m_baseName)) {
> +            if (!m_dataPath.isEmpty()) {
> +                QDir dir(m_dataPath);
>                  componentUrl =

I don't think that this is 100% correct. We should treat relative urls as relative to the plugin base path, that is relative to the directory where the plugin's manifest file was found.

>                      QUrl::fromLocalFile(dir.filePath(componentUrl.path()));
Download as text