Results 1 to 6 of 6

Thread: interacting C++ QML

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Mar 2016
    Posts
    9
    Qt products
    Qt5
    Platforms
    MacOS X

    Default interacting C++ QML

    hello,
    i would like understand qt, so i post here.

    rmq: QT : 5.7


    if i setProperty class in my qml.
    in this class, i have method Q_INVOKABLE what we return a pointeur in class.

    like this with no var in my qml:

    if (toto.test()!=NULL)
    toto.test().x() //method Q_INVOKABLE x()

    work but , the qml want manage the cobject returned by test()

    if i quit the qml page.
    qt would like delete the object returned by test() why??

    i would like juste interacting C++ and QML.

    what is the best method for use this? (no manage memory who i return in my q_INVOKABLE function)


    thank's for your reply
    Last edited by kickoune; 22nd September 2016 at 15:24.

Similar Threads

  1. Replies: 5
    Last Post: 23rd January 2012, 22:05
  2. QT implement for interacting Web Widget
    By ravikumar in forum Qt Programming
    Replies: 0
    Last Post: 22nd January 2012, 09:43
  3. interacting with qGraphicsItem
    By dubstar_04 in forum Newbie
    Replies: 1
    Last Post: 27th April 2011, 08:22
  4. Interacting QGraphicsItems together
    By sean.reynolds in forum Qt Programming
    Replies: 2
    Last Post: 16th April 2011, 09:35
  5. Interacting with an API
    By srohit24 in forum Qt Programming
    Replies: 1
    Last Post: 5th April 2009, 14:17

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.