flutter/dev
Jonah Williams 29898812d4
[framework] make hit slop based on device pointer kind for drag/pan/scale gestures (#64267)
Currently the framework uses fairly large "hit slop" values to disambiguate taps from drags/pans. This makes sense on touch devices where the interaction is not very precise, on mice however it can feel as if the UI is lagging. This is immediately noticeable on our infra dashboard, where it takes almost half of a grid square of drag before the actual drag kicks in.

One potential solution is to always use smaller constants depending on whether the interaction is mouse or touch based. The only reasonable choice is to use the pointer device kind and not target platform - same platform can have different input sources. This requires exposing the pointer device kind in a few new places in several of the gesture detectors, and using the enum to compute the correct hit slop from an expanded set of constants.

This almost works, however there are a few places (notably ListViews) which uses the touch hit slop as a default value in scroll physics. It does not seem like it will be easy to disambiguate a user provided scroll physics constant from the default and/or adjust it somehow - this might require significant changes to scroll physics which I have left out of this PR.

This PR does not adjust:

kTouchSlop used in scroll_physics.dart's minFlingDistance
kTouchSlop used in PrimaryPointerGestureRecognizer/LongPressGestureRecognizer
2020-09-08 15:53:36 -07:00
..
automated_tests Fix RangeMaintainingScrollPhysics (#65135) 2020-09-07 11:40:03 -07:00
benchmarks [framework] make hit slop based on device pointer kind for drag/pan/scale gestures (#64267) 2020-09-08 15:53:36 -07:00
bots [fuchsia] Test wait for device to be up after pave (#64819) 2020-08-31 09:48:05 -07:00
ci Move Android doctor SDK check to 29 and Cirrus images to 30 (#63517) 2020-08-20 11:06:32 -07:00
customer_testing [versions] update to the latest sdk versions (#62687) 2020-08-03 10:31:06 -07:00
devicelab re-enable the post_backdrop_filter test with CPU/GPU measurements (#65201) 2020-09-04 18:00:02 -07:00
docs Revert "Add padding around flutter api docs search input (#44980)" (#63113) 2020-08-06 16:15:09 -07:00
integration_tests Add FrameTiming delay to watchPerformance (#64780) 2020-09-02 11:15:08 -07:00
manual_tests move compile/target sdk versions to 29 (#62799) (#63008) 2020-08-11 14:51:02 -07:00
missing_dependency_tests [flutter_tools] remove globals from compilers (#59184) 2020-06-18 10:33:17 -07:00
snippets More restoration documentation (#63438) 2020-08-21 10:51:05 -07:00
tools Move gen_l10n into flutter_tools (#65025) 2020-09-03 09:26:58 -07:00
tracing_tests [flutter_tools] update dwds, roll to null-safe file and process (#64195) 2020-08-19 16:59:52 -07:00
prod_builders.json Fix LUCI builders config. (#64361) 2020-08-21 16:04:17 -07:00
README.md Add run_if property for existing LUCI try builders (#64180) 2020-08-20 17:28:12 -07:00
try_builders.json [Devicelab] Temporarily remove testonly_devicelab_tests builder. (#64837) 2020-08-28 20:13:03 -07:00

This directory contains tools and resources that the Flutter team uses during the development of the framework. The tools in this directory should not be necessary for developing Flutter applications, though of course, they may be interesting if you are curious.

The tests in this directory are run in the framework_tests_misc-* shards.

Luci builder file

try_builders.json and prod_builders.json contain the supported luci try/prod builders for flutter.

try_builders.json

It follows format:

{
    "builders":[
        {
            "name":"yyy",
            "repo":"flutter",
            "taskName":"zzz",
            "enabled":true,
            "run_if":["a/b/", "c/d/**"]
        }
    ]
}
  • enabled(optional): true is the default value if unspecified
  • run_if(optional): will always be triggered if unspecified

prod_builders.json

It follows format:

{
    "builders":[
        {
            "name":"yyy",
            "repo":"flutter",
            "taskName":"zzz",
            "flaky":false
        }
    ]
}

try_builders.json will be mainly used in flutter/cocoon to trigger/update pre-submit flutter luci tasks, whereas prod_builders.json will be mainly used in flutter/cocoon to refresh luci task statuses to dashboard.