Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Reply
Contributor
lauvot
Posts: 23
Registered: ‎01-01-2013
My Carrier: airtel

Unknown symbol warning in qml file for C++ objects

Hi,

 

I am having following code in C++ file to expose object to qml

 

QmlDocument *qml = QmlDocument::create("asset:///main.qml").parent(this);
qml->setContextProperty("_myClass", new MyClass(this));

 

when I am using the _myClass in qml file I see a i in editor with warning 'unknown symbol'

 

though the code works fine, but how to fix this warning in editor ?

 

Thanks for your support,

lauvot

 

Please use plain text.
Developer
mdodd
Posts: 186
Registered: ‎07-19-2012
My Carrier: Three

Re: Unknown symbol warning in qml file for C++ objects

No way of fixing it as far as I'm aware. The QML editor can't take external libraries into account at the moment. Your best bet is to just ignore it.



Did this post help you? If so, please make sure to "like" it!
Please use plain text.
Contributor
lauvot
Posts: 23
Registered: ‎01-01-2013
My Carrier: airtel

Re: Unknown symbol warning in qml file for C++ objects

Thanks a lot !!

Please use plain text.
Developer
RileyGB
Posts: 282
Registered: ‎08-06-2010

Re: Unknown symbol warning in qml file for C++ objects

In 10.1, I believe you can whitelist these symbols individually.



Follow me on twitter @RileyGB - https://twitter.com/RileyGB
View my BB10 OpenSource projects - https://github.com/RileyGB/BlackBerry10-Samples
Please use plain text.
Regular Contributor
galeb
Posts: 77
Registered: ‎11-03-2009
My Carrier: VIPnet

Re: Unknown symbol warning in qml file for C++ objects

You can whitelist, but QML Editor keeps crashing.  At least that is what I'm experiencing

Please use plain text.