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

ComboBox: without a validator bindings to acceptableInput don't work

    XMLWordPrintable

Details

    • All
    • f8db2b996f339ad7e0754cd232f1e71ebecf6367 (qt/qtquickcontrols2/dev) 875ddb2b25496fc114d443369c22ea9fd27568a6 (qt/qtquickcontrols2/6.2) ad86936d4e9c00ed5480c6fe4e0561d077ba48bc (qt/tqtc-qtquickcontrols2/5.15)

    Description

      Bindings to ComboBox acceptableInput property don't seem to work at all if ComboBox has not been given a validator. This seems to be fixed by creating a seemingly unrelated binding to the ComboBox contentItem.acceptableInput property.

      Steps to reproduce & fix the problem:

      1. Run the attached example
      2. => acceptableInput is logged as true BUT according to binding it's false
      3. close the app
      4. Uncomment line 45 in main.qml
      5. Run the attached example
      6. => acceptableInput is logged as true AND according to binding it's true

       

      Attachments

        1. qtbug94307.zip
          2 kB
          Miika Pernu

        Activity

          People

            hurlevent Oliver Eftevaag
            miikapernu Miika Pernu
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: