Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. QML Plugin methods into C++ code

QML Plugin methods into C++ code

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
2 Posts 2 Posters 662 Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • shavS Offline
    shavS Offline
    shav
    wrote on last edited by
    #1

    Hi everyone!

    I have a project which uses QML plugin. This plugin has a C++ methods which I want use in my backend logic in C++. How I can call C++ methods from QML plugin in C++ code without QML? Is it possible?

    I need this for convert Objective-C NSDictionary type to QVariantMap. My plugin has this methods and I want to use it. I don't want copy part of code to another project.

    Also I have another question: Is it possible to send Objective-C object to QML? I can't find any way for this.

    Mac OS and iOS Developer

    raven-worxR 1 Reply Last reply
    0
    • shavS shav

      Hi everyone!

      I have a project which uses QML plugin. This plugin has a C++ methods which I want use in my backend logic in C++. How I can call C++ methods from QML plugin in C++ code without QML? Is it possible?

      I need this for convert Objective-C NSDictionary type to QVariantMap. My plugin has this methods and I want to use it. I don't want copy part of code to another project.

      Also I have another question: Is it possible to send Objective-C object to QML? I can't find any way for this.

      raven-worxR Offline
      raven-worxR Offline
      raven-worx
      Moderators
      wrote on last edited by
      #2

      @shav
      you need to load the plugin yourself, using QLibrary and resolve the methods you want to use.
      If the plugin is already loaded it wont get loaded a second time.

      --- SUPPORT REQUESTS VIA CHAT WILL BE IGNORED ---
      If you have a question please use the forum so others can benefit from the solution in the future

      1 Reply Last reply
      1

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved