XInput2: Listen to master devices only

A comment removed by this commit gives two reasons for listening to
slave devices, both of which no longer apply:

- "Only slaves emit raw motion events": perhaps this was true when the
comment was written, but now master devices provide raw motion events
along with the other raw events.

- "Selecting slave keyboards avoids dealing with key focus": we get raw
key events regardless of the focus.

Listening to both master and slave devices results in duplicate raw
events.  For button and key events, that's a tiny waste of time setting
the update flag a second time, but for raw mouse events the raw motion
will be processed twice.  That makes this commit a user-facing change.
This commit is contained in:
Jeffrey Bosboom
2023-04-15 02:13:03 -07:00
parent b2a98c41ee
commit 620955d397
2 changed files with 4 additions and 37 deletions

View File

@ -108,7 +108,6 @@ private:
};
private:
void SelectEventsForDevice(XIEventMask* mask, int deviceid);
void UpdateCursor(bool should_center_mouse);
public: