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. Ensure property initialization order of QML item
Forum Updated to NodeBB v4.3 + New Features

Ensure property initialization order of QML item

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
1 Posts 1 Posters 149 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.
  • C Offline
    C Offline
    Creaperdown
    wrote on 11 Jul 2023, 20:40 last edited by
    #1

    Hey, I have a custom qml item that is initialized when a certain property is initialized, so I have

    Page
    {
        id: page
        document: somewhere.myDocument
    }
    

    And after that, the page is ready to use, since the c++ functions backing it (e.g. implicitWidth) are relying on document to exist. Is there any way to enforce document being initialized first, before any of the page functionality is called?

    1 Reply Last reply
    0

    1/1

    11 Jul 2023, 20:40

    • Login

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