Uploaded image for project: 'Qt for MCUs'
  1. Qt for MCUs
  2. QTMCU-66

Behavior.enabled alias cast error

XMLWordPrintable

    • QUL Sprint 4.6/2021, QUL Sprint 1.1/2022, QUL Sprint 1.2/2021, QUL Sprint 1.3/2022

      demo code:

      property alias animationEnabled: rotationBehavior.enabled
      Behavior on animatedValue {
          id: rotationBehavior
          NumberAnimation {
              id: rotationAnimation
              easing.type: Easing.InQuad
          }
      }
      

      gives error:
      error C2039: 'enabled': is not a member of 'Needle::rotationBehavior_Behavior'

      Temp solution:

          property bool animationEnabled: rotationBehavior.enabled
          Behavior on animatedValue {
              id: rotationBehavior
              enabled: animationEnabled
              NumberAnimation {
                  id: rotationAnimation
                  easing.type: Easing.InQuad
              }
          }
      

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

            piotr.mucko Piotr Mucko
            jiu shanheng jiu
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes