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. How to enumerate/reference extensions imported into the QQmlApplicationEngine?

How to enumerate/reference extensions imported into the QQmlApplicationEngine?

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
qqmlapplicationplugins
2 Posts 1 Posters 978 Views
  • 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.
  • V Offline
    V Offline
    VRHans
    wrote on last edited by
    #1

    I have successfully created a multi-platform host application that can dynamically load plugins derived from QQmlPluginExtension via QQmlApplicationEngine::importPlugin() on Windows, Android, Linux, OSX (iOS will require static linking.)

    I don't know what extensions will be installed until runtime, as this is an extension mechanism for customers to add their own plugins without rebuilding the host application. This means I need to load all plugins found in a series of folders/sub-folders.

    My goal is provide a base window for these plugins to render themselves into, so I need to enumerate the imported extensions in order, presumably, to dynamically create their associated QML types.

    Any idea how to do this? There seems to be no obvious way to query the QQmlEngine for this information.

    For example, if my application loads a single discovered plugin, which happens to be be a custom QML extension containing a Web View QML component, - how do I find/create this previously unknown QML extension object after the QQmlEngine has imported it?

    Is this the wrong approach? Should I be loading it as a regular extension, enumerating it in some fashion via that plugin loader instance and then registering it as a Qml type on my own?

    Thanks!

    1 Reply Last reply
    0
    • V Offline
      V Offline
      VRHans
      wrote on last edited by
      #2

      ...crickets?

      1 Reply Last reply
      0

      • Login

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