Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-85860

BusyIndicator in inconsistent state when running property changed too fast

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P2: Important
    • None
    • 5.12.7, 5.15.0
    • Quick: Controls 2
    • None
    • macos 10.15.6, Qt 5.12.7, clang64
    • macOS

    Description

      When running property of BusyIndicator is changed too fast, it stays in inconsistent state - running property is true, but BusyIndicator is hidden.

      //test code
      import QtQuick 2.12
      import QtQuick.Controls 2.12
      Item {    
          width: 200    
          height: 200    
          
          Column {        
              anchors.centerIn: parent 
             
              BusyIndicator {            
                  id: testIndicator            
                  width: 50            
                  height: 50            
                  onRunningChanged: console.log("onRunningChanged",running)        
              }        
      
              Button {            
                  text: "run test"            
                  onClicked: {                
                      console.log("lets stop it")                
                      testIndicator.running = false                
                      console.log("lets start it")                
                      testIndicator.running = true            
                  }        
               }    
           }
      }

       At the beginning, BusyIndicator is running. After you click on "run test" button, ButtonIndicator stays hidden, even though according to logs, its running property is correctly set to true.

      qml: lets stop it
      qml: onRunningChanged false
      qml: lets start it
      qml: onRunningChanged true
      

       

       

      My real issue is when BusyIndicator is used along with StateMachine framework:

      BusyIndicator { 
          width: 50 
          height: 50
          running: stateDownload.active || stateProgram.active
      }

      As state machine is switching from stateDownload into stateProgram, for a very short moment, both states are not active, so BusyIndicator stops. But as stateProgram became active, BusyIndicator wont start.

       

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            qt.team.quick.subscriptions Qt Quick and Widgets Team
            keresan Martin Mich
            Votes:
            2 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes