<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Jan 5, 2016 at 1:39 PM, Willem Ferguson <span dir="ltr"><<a href="mailto:willemferguson@zoology.up.ac.za" target="_blank">willemferguson@zoology.up.ac.za</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000">
Dear Dirk, Sebastian,<br>
<br>
If it were possible to have feedback from you based on not more than
15 minutes of your time, I would greatly appreciate it. I am trying
to get the QML to signal to the C++ and, due to newby inexperience,
I am totally stuck. I address a number of issues here, but the first
one is the substantive one, the others are small. I take the liberty
of attaching the code in three files.<br>
<br>
1) Signalling from the Continue button in the QML to the appropriate
C++ slot. I use an approach as close as possible to that of
QmlManager in Subsurface-mobile. I create a message object with a
slot, and connect this to the QML signal. Using QtCreator I get a
compile-time error: <br>
<tt>/home/willem/qml/vendor/main.cpp:48: error: undefined reference
to `GUIMessageClass::~GUIMessageClass()'</tt></div></blockquote><div><br></div><div>This means that the GUIMessageClass ditdn't implemented a method, nothing related to QML.<br><br></div><div>GuiMessageClass::~GuiMessageClass {<br></div><div> qDebug() << "Destructor Method \o/";<br></div><div>} <br><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div bgcolor="#FFFFFF" text="#000000"><br>
There is a possibility this is a systemic problem related to the way
of presenting code to QTCreator, but I am too naïve to be able to
determine this. Any comment at all will be invaluable.<br>
<br>
2) In the object in the header file, what does ~MessageClass mean?
It eliminates a compilation error for this code.<br>
<br>
3) With respect to the two models used in the QML, I get warnings
from the QML debugger in QtCreator:<br>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px"><span style="font-family:'Monospace';font-size:9pt;color:#aa0000">qrc:main.qml:24: ReferenceError: vendorModel is not defined</span></p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px"><span style="font-family:'Monospace';font-size:9pt;color:#aa0000">qrc:main.qml:35: ReferenceError: productModel is not defined</span></p>
<p style="margin-top:0px;margin-bottom:0px;margin-left:0px;margin-right:0px;text-indent:0px"><span style="font-family:'Monospace';font-size:9pt;color:#aa0000">qrc:main.qml:35: ReferenceError: productModel is not defined</span></p>
These warnings do not cause faulty execution, though. But I
would love to know how they arise.<br></div></blockquote><div><br></div><div>This means that the vendor and product model are not exported to QML, I see that you are exporting them - but you are exporting them after defining the QML file, maybe changing to before setting the main.qml would work?<br><br><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div bgcolor="#FFFFFF" text="#000000">
<br>
4) When running the code within QtCreator, the combo boxes do not
work well. They need to be clicked several times before the options
are shown. However, if I provide models inside of QML (i.e. not
using a C++ external source) and I run the code using qmlscene, then
the combo boxes work as expected. So, FOR THE MOMENT I assume it is
a problem in the way QtCreator does the QML interpretation and that
the QML is likely to run as expected on a mobile device.<br></div></blockquote><div><br></div><div>Qt Creator QML management is buggy.<br> <br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div bgcolor="#FFFFFF" text="#000000">
Kind regards,<br>
willem<br>
<br>
</div>
<br>_______________________________________________<br>
subsurface mailing list<br>
<a href="mailto:subsurface@subsurface-divelog.org">subsurface@subsurface-divelog.org</a><br>
<a href="http://lists.subsurface-divelog.org/cgi-bin/mailman/listinfo/subsurface" rel="noreferrer" target="_blank">http://lists.subsurface-divelog.org/cgi-bin/mailman/listinfo/subsurface</a><br>
<br></blockquote></div><br></div></div>