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. Unqualified access warning on singleton object with QML_NAMED_ELEMENT
Forum Updated to NodeBB v4.3 + New Features

Unqualified access warning on singleton object with QML_NAMED_ELEMENT

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
1 Posts 1 Posters 152 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.
  • H Offline
    H Offline
    haowenl
    wrote on last edited by haowenl
    #1

    I have a singleton QObject declared with QML_NAMED_ELEMENT(MySingleton) and in QML file I just use MySingleton to access it. When I run qmllint on the file, I get an Unqualified access warning. Is this a false positive?

    How would I:

    • Tell qmllint that this is a named singleton so the access is not unqualified, OR
    • Qualify the access to the named singleton?

    I use CMake and qt_add_qml_module with QT_QML_GENERATE_QMLLS_INI turned on, if it affects how I achieve the first item above.

    1 Reply Last reply
    2

    • Login

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