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

QObjectPicker signals aren't always emitted

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P2: Important
    • None
    • 5.9.4, 5.11.0
    • Qt3D
    • 2e74095b645d3ecbbb8850e24dc823ed4378f650

    Description

      When QObjectPicker is attached to an entity and we click it with a mouse that is on move pressed(), clicked() and released() signals are not always emitted. Sometimes we get one or two of them, but on most erroneous cases we don't get any. We attached QMouseHandler to the scene for testing purposes and it gets all the events.

      The mouse movement seems to be substantial. With stationary mouse, we were not able to reproduce the problem. The movement and click should be quite fast and the easiest way to reproduce was to start movement outside the entity, click within the entity and move out (I guess this is humane limitation and has nothing to do with the software implementation).

      The attached example can be used to reproduce the problem. The cylinder in the middle is the entity with the object picker. The example prints the events to debug and the cylinder's color changes with pressed() signal. Move the mouse across the cylinder and click while on it. Try to be fast or precise. We expect to see both mouse and picker pressed()/released() debugs between pickerENTER and pickerEXIT debugs, but sometimes the picker signals are missing.

      Tested on Linux, macOS and Windows. It was easiest to reproduce on Linux (Ubuntu 16.04, Qt 5.11.0) where it was 40% reproducible.

      Attachments

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

        Activity

          People

            anmaatta Antti Määttä
            qtcomsupport Qt Support
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes