Hi everyone!
I have a QML plugin 2.0 with name Msl. The most part of plugin’s logic is a C++ code but my plugin must have also a QML GUI object. I tryed to find some information in doc and found article about qmldir file. I trying to create a correct qmldir file and all works fine if my plugin doesn’t use QML files. I added to qmldir file a line with my qml file but client app cann’t find it as a part of my plugin. My qmldir file looks like this:
module com.shav.msl
MslQmlControllerItem 1.0 MslQmlControllerItem.qml //This file saved in folder with qmldir file.
plugin Msl
typeinfo msl.qmltypes //Saved only C++ classes
In client app I use this model like:
//others QML moduls
import com.shav.msl 1.0
ApplicationWindow
{
id: appRoot
title: "Mobile Script Language Editor"
width: 1024
height: 700
//This works fine because this class save in C++ code
MslManager {
id: manager
}
//This id can't be find in module
MslQmlControllerItem {
id: item
width: 30
height: 50
}
Could you tell me what I do wrong? Thanks for the any help!
↧