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

Changing parallel states causes properties to be reset

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P2: Important
    • 5.0.0
    • 4.7.2
    • Core: State Machine
    • None
    • 035c933eaa54c789d533a16e3c755914f68cc749

    Description

      I have got a state machine with 5 states: Root, which has two children groupA and groupB. Root uses QState::ParallelStates, so groupA and groupB are parallel.
      Both group have two child states, "on" and "off", so there is aOn, aOff, bOn and bOff.
      Each of these states assigns a property of a global object:
      aOn assigns the property "a" to "true"
      aOff assigns the property "a" to "false"
      bOn assigns the property "b" to "true"
      bOff assigns the property "b" to "false"

      Now, when changing from bOff to bOn, that causes the global "a" property to be reset, even though
      none of the a states were touched!
      The configuration of the state machine shows that groupA is still in the same state. So triggering a transition
      in groupB somehow causes a property assigned from groupA to be reset again.

      Expected outcome: Triggering a transition in one child of the parallel root state should not change any properties in the other child of the root state.

      The attached example is a minimal testcase in one file.

      Attachments

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

        Activity

          People

            kenthans Kent Hansen (Inactive)
            tmcguire Thomas McGuire
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes