• Alex Cooper's avatar
    Ensure that OpenVR only adds placeholder buttons when needed. · 79708b39
    Alex Cooper authored
    The current implementation of the OpenVRGamepadHelper always adds the
    optional grip and secondary axes buttons; however, if those buttons are
    missing and no additional buttons need to be supported, they should not
    be included. A prime example of this is the vive controller, which has
    a trigger, a grip, and a touchpad, but no secondary axis button.  This
    is essentially the controller that the new TestGamepadOptionalData test
    builds.
    
    Bug: 964026
    Change-Id: I1de93b5bd7bd0d9e75013cf33b8f333e5d70270f
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1627914Reviewed-by: default avatarBill Orr <billorr@chromium.org>
    Commit-Queue: Alexander Cooper <alcooper@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#662843}
    79708b39
openvr_gamepad_helper.cc 14.7 KB