Greetings Qt centers,

I’m trying to load a QML module from the qrc file.

Here is how my qrc file looks:

Qt Code:
  1. <RCC>
  2. <qresource prefix="/">
  3. <file>content/Main.qml</file>
  4. <file>content/SkyComponents/PushButton.qml</file>
  5. <file>content/SkyComponents/qmldir</file>
  6. </qresource>
  7. </RCC>
To copy to clipboard, switch view to plain text mode 
Here is how my Main.qml looks:

Qt Code:
  1. import SkyComponents 1.0
  2.  
  3. ...
To copy to clipboard, switch view to plain text mode 
I also added this in my cpp files:

Qt Code:
  1. wControllerDeclarative->engine()->addImportPath("qrc:/");
To copy to clipboard, switch view to plain text mode 
I get the following error:

Qt Code:
  1. Couldn’t create Main QML Object: qrc:/content/Main.qml:3 module “SkyComponents” is not installed
To copy to clipboard, switch view to plain text mode 
Is it possible to load qmldir(s) from the qrc file ?

Thanks.