• Daniel Libby's avatar
    Add explicit flag for compositor scrollbar injected gestures · d9a56afc
    Daniel Libby authored
    The original change to enable scrollbar latency for the composited
    scrollbars incorrectly used an existing member to try and determine
    whether a GestureScrollUpdate was the first one in an injected sequence
    or not. is_first_gesture_scroll_update_ was incorrect because it is only
    updated when input is actually dispatched to InputHandlerProxy, and the
    flag is cleared for all GSUs before the location where it was being
    read.
    
    This bug was missed because of incorrect tests. The
    VerifyRecordedSamplesForHistogram method doesn't actually assert or
    expect anything - the return value must be inspected.
    
    As part of fixing up the tests, I made a few other changes to get them
    passing consistently across all platforms:
    - turn on main thread scrollbar injection feature (in case it's ever
      turned off we don't want the tests to start failing)
    - enable mock scrollbars
    - disable smooth scrolling
    - don't run scrollbar tests on Android
    
    The composited scrollbar button test is disabled due to a bug in how
    the mock theme reports its button sizes, which throws off the region
    detection in ScrollbarLayerImplBase::IdentifyScrollbarPart (filed
    crbug.com/974063 for this issue).
    
    Change-Id: Ie1a762a5f6ecc264d22f0256db68f141fc76b950
    
    Bug: 954007
    Change-Id: Ib258e08e083e79da90ba2e4e4216e4879cf00cf7
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1652741
    Commit-Queue: Daniel Libby <dlibby@microsoft.com>
    Reviewed-by: default avatarDavid Bokan <bokan@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#669086}
    d9a56afc
input_handler_proxy.cc 47.3 KB