AutoLoader QML Type
A lazy loader that creates components on demand. More...
| Import Statement: | import FluentUI.Controls 1.0 |
Properties
- item : Item
- progress : real
- source : var
- sourceComponent : Component
- status : enumeration
Methods
Detailed Description
AutoLoader dynamically instantiates a QML component either from a URL (source) or from an inline sourceComponent. It exposes the loading progress and status, and offers convenience methods to switch sources or reload the current one.
Property Documentation
item : Item
The root item of the loaded component, or null if nothing has been loaded.
progress : real
The current loading progress, ranging from 0.0 to 1.0.
source : var
The URL of the QML document to load. Setting this property triggers asynchronous loading of the component.
sourceComponent : Component
An inline Component to instantiate. Mutually exclusive with source.
status : enumeration
The loading status of the loader. One of Loader.Null, Loader.Ready, or Loader.Loading.
Method Documentation
void reload()
Reloads the current source or source component from scratch.
void setSource(var source, object properties)
Loads the component from source with the given initial properties. This is equivalent to setting both source and initial property values in one call.