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

QMediaRecorder::RecorderState is not recognized by QML tools

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: P2: Important P2: Important
    • None
    • 6.5.10, 6.8.4, 6.10.0 Beta4
    • Multimedia
    • None
    • Windows 10 22H2, MSVC 2022 x64

      Code

      import QtQuick
      import QtMultimedia
      
      Window {
          width: 600
          height: 400
          visible: true
      
          MediaRecorder {
              onRecorderStateChanged: console.log(recorderState)
          }
      }
      

       

      qmlls/qmllint warning

      Warning: Main.qml:10:3: Type RecorderState of parameter state in signal called recorderStateChanged was not found, but is required to compile onRecorderStateChanged. Did you add all imports and dependencies? [signal-handler-parameters]
      		onRecorderStateChanged: console.log(recorderState)
      		^^^^^^^^^^^^^^^^^^^^^^
      

       

      Possible fix
      According to the test at QTBUG-140456, fully-qualifying the parameter at https://github.com/qt/qtmultimedia/blob/v6.10.0-rc1/src/multimedia/recording/qmediarecorder.h#L142 ("RecorderState" -> "QMediaRecorder::RecorderState") might fix it

       

      Notes
      Strangely, onErrorOccurred does not produce the same warning, even though the Error parameter is not fully-qualified either.

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

            qtmultimediateam Qt Multimedia Team
            skoh-qt Sze Howe Koh
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:

                There are no open Gerrit changes