Uploaded image for project: 'Qt Design Studio'
  1. Qt Design Studio
  2. QDS-10737

Connections parametrized function is misidentified as Empty in the List

    XMLWordPrintable

Details

    Description

      Connections signal handler is written as parametrized function and is misidentified by the Connections List as "Empty", even though Connections Editor Form identifies it correctly as "Custom".

      Regular "custom" function is correctly identified by the list as "custom" function.


      Code snippet (add it to mouse area): 

      Connections {
          target: mouseArea    
          onPositionChanged: mouse => {
              if (mouseArea.pressed) {
                  const hDelta = mouse.x - mouseArea.oldX
                  const vDelta = mouse.y - mouseArea.oldY
              }
              mouseArea.oldX = mouse.x
              mouseArea.oldY = mouse.y
          }
      } 

       

      Enclosing parameneter in parenthesis helps to identify the Action as "Custom"

      onPositionChanged: (mouse) => {
          ...
      } 

      but saving file instantly reformats it and removes the parenthesis and marks action as "Empty".

      Attachments

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

        Activity

          People

            thohartm Thomas Hartmann
            algerman Aleksei German
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes