that's what I was thinking I will give it a try...
update: not able to get it working right....
the interval property seems to delay the busyIndacator image from appearing instead of the component...
Timer {
id: delay
interval: 5000
onTriggered:{
userEvent_busyInd.running = true
}
}
BusyIndicator {
id: userEvent_busyInd
anchors.centerIn: parent
anchors.verticalCenterOffset: 100
z: 100
running: true //usereventcomponent.status === usereventcomponent.Loading
}
Component.onCompleted: {
delay.stop();
userEvent_busyInd.running = false
}
Timer {
id: delay
interval: 5000
onTriggered:{
userEvent_busyInd.running = true
}
}
BusyIndicator {
id: userEvent_busyInd
anchors.centerIn: parent
anchors.verticalCenterOffset: 100
z: 100
running: true //usereventcomponent.status === usereventcomponent.Loading
}
Component.onCompleted: {
delay.stop();
userEvent_busyInd.running = false
}
To copy to clipboard, switch view to plain text mode
action that loads component
Action {
id: action_userEventLogBtn
enabled:!inSequence
onTriggered:{
//----Code to Load User Event Dialog-----//
UserEventLog.init();
weld_view.state = "USEREVENT"
xmui.insertLogMessage(rootItem.getUserName(), "User entered userEventDialog");
//onLoaded: console.log("User Event Log");
//---Busy Indicator---//
delay.start();
}
//Component.onCompleted: {
//userEvent_busyInd.running = false
//}
}
State {
name: "USEREVENT"
PropertyChanges {target: mask; visible:true; z: 1;}
PropertyChanges {target: usereventlog_loader; sourceComponent:usereventcomponent;}
}
Component {
id: usereventcomponent
UserEventDialog {
id: userEventLog
}
}
Loader{
id: usereventlog_loader
width: 1300
height: 600
anchors.horizontalCenter: parent.horizontalCenter
anchors.verticalCenter: parent.verticalCenter
sourceComponent: null
z: 3
}
Action {
id: action_userEventLogBtn
enabled:!inSequence
onTriggered:{
//----Code to Load User Event Dialog-----//
UserEventLog.init();
weld_view.state = "USEREVENT"
xmui.insertLogMessage(rootItem.getUserName(), "User entered userEventDialog");
//onLoaded: console.log("User Event Log");
//---Busy Indicator---//
delay.start();
}
//Component.onCompleted: {
//userEvent_busyInd.running = false
//}
}
State {
name: "USEREVENT"
PropertyChanges {target: mask; visible:true; z: 1;}
PropertyChanges {target: usereventlog_loader; sourceComponent:usereventcomponent;}
}
Component {
id: usereventcomponent
UserEventDialog {
id: userEventLog
}
}
Loader{
id: usereventlog_loader
width: 1300
height: 600
anchors.horizontalCenter: parent.horizontalCenter
anchors.verticalCenter: parent.verticalCenter
sourceComponent: null
z: 3
}
To copy to clipboard, switch view to plain text mode
Bookmarks