XMLWordPrintable

Details

    • Sub-task
    • Resolution: Invalid
    • Not Evaluated
    • None
    • Core: Object Model
    • None

    Description

      As of today, the current definition occurs within src/corelib/qnamespace.h starting at line 149:

      enum MouseButton

      { NoButton = 0x00000000, LeftButton = 0x00000001, RightButton = 0x00000002, MidButton = 0x00000004, // ### Qt 5: remove me MiddleButton = MidButton, XButton1 = 0x00000008, XButton2 = 0x00000010, MouseButtonMask = 0x000000ff }

      ;

      I propose the following replacement:

      enum MouseButton

      { NoButton = 0x00000000, LeftButton = 0x00000001, RightButton = 0x00000002, MidButton = 0x00000004, // ### Qt 5: remove me MiddleButton = MidButton, XButton1 = 0x00000008, RawButton8 = XButton1, XButton2 = 0x00000010, RawButton9 = XButton2, RawButton10 = 0x00000020, RawButton11 = 0x00000040, RawButton12 = 0x00000080, RawButton13 = 0x00000100, RawButton14 = 0x00000200, RawButton15 = 0x00000400, RawButton16 = 0x00000800, RawButton17 = 0x00001000, RawButton17 = 0x00002000, RawButton17 = 0x00004000, RawButton17 = 0x00008000, MouseButtonMask = 0x0000ffff }

      ;

      I understand why the names "XButton1" and "XButton2" were used (instead of "Back and Forward"). But over and over, at KDE, people show confusion about the equivalency between "XButton1", "XButton2", the left and right wheels, and how they all correspond to xev output. My "RawButtonxx" proposed naming convention is more clear, and easier to remember. (We keep the old names for BC, of course.)

      Attachments

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

        Activity

          People

            goffart Olivier Goffart (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