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

Add additional enum value "AllButtons" to Qt::MouseButton (in qnamespace.h)

    XMLWordPrintable

Details

    Description

      From IRC: Alan Alpert and I both find it awkward to 'OR' a large number of Qt::MouseButton values, when setting 'acceptedButtons' for a MouseArea. To simplify QML coding (for both typing and readability), we should provide a shorthand value for "allButtons". It should not include reserved bits- so the highest-order bit to include is MaxMouseButton, value 0x04000000.

      AllButtons = 0x07ffffff.

      It is simple to do this in the namespace, more complicated to add and maintain a new keyword (e.g., "acceptAllButtons = true) in the code. Considerably less documentation, as well.

      Attachments

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

        Activity

          People

            martjone Martin Jones (closed Nokia identity) (Inactive)
            rickst29 Richard Stockton
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes