Skip to content

Visual bug on the last two items of a ReorderableListView #88331

@Innominus

Description

@Innominus

Steps to Reproduce

File below includes the main dart file example:
main.zip

  1. Create any ReorderableListView with or without .builder(), and with any settings you want (this appears to be repeatable with any parameters or settings)
  2. add 2 or more items to the list
  3. go to the end of the list, hold and drag the second last item in the list
  4. pull the item over the last item in the list, and then bring the item you're holding back to its original position, second last
  5. Make sure you're not dragging and dropping the second last item into the last position, you're just hovering the second last item over the last item and then back again

Expected results:
I expected the item I'm dragging to go back into place where I originally held and dragged it from after I dropped it back in its original position

Actual results:
When you drop the item back where you originally dragged it from, the item decides to try and drop in the last position, and then snaps back to its original position

This is actually repeatable without running any code on your machine at all, you can do the same steps above with the example within the Flutter docs:
https://api.flutter.dev/flutter/material/ReorderableListView-class.html

Logs

flutter run --verbose

[  +40 ms] executing: uname -m
[  +19 ms] Exit code 0 from: uname -m
[        ] x86_64
[   +3 ms] executing: [/home/inno/snap/flutter/common/flutter/] git -c
log.showSignature=false log -n 1 --pretty=format:%H
[   +5 ms] Exit code 0 from: git -c log.showSignature=false log -n 1
--pretty=format:%H
[        ] 0f465e5b2a3ed2431321b490a614c3d15089854c
[        ] executing: [/home/inno/snap/flutter/common/flutter/] git tag
--points-at 0f465e5b2a3ed2431321b490a614c3d15089854c
[   +7 ms] Exit code 0 from: git tag --points-at
0f465e5b2a3ed2431321b490a614c3d15089854c
[        ] 2.5.0-5.0.pre
[   +6 ms] executing: [/home/inno/snap/flutter/common/flutter/] git rev-parse
--abbrev-ref --symbolic @{u}
[   +3 ms] Exit code 0 from: git rev-parse --abbrev-ref --symbolic @{u}
[        ] origin/dev
[        ] executing: [/home/inno/snap/flutter/common/flutter/] git ls-remote
--get-url origin
[   +2 ms] Exit code 0 from: git ls-remote --get-url origin
[        ] https://github.com/flutter/flutter.git
[  +50 ms] executing: [/home/inno/snap/flutter/common/flutter/] git rev-parse
--abbrev-ref HEAD
[   +4 ms] Exit code 0 from: git rev-parse --abbrev-ref HEAD
[        ] dev
[  +33 ms] Artifact Instance of 'AndroidGenSnapshotArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'AndroidInternalBuildArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'IOSEngineArtifacts' is not required, skipping
update.
[        ] Artifact Instance of 'FlutterWebSdk' is not required, skipping
update.
[   +1 ms] Artifact Instance of 'WindowsEngineArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'WindowsUwpEngineArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'MacOSEngineArtifacts' is not required, skipping
update.
[        ] Artifact Instance of 'LinuxEngineArtifacts' is not required, skipping
update.
[        ] Artifact Instance of 'LinuxFuchsiaSDKArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'MacOSFuchsiaSDKArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'FlutterRunnerSDKArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'FlutterRunnerDebugSymbols' is not required,
skipping update.
[  +38 ms] executing: /home/inno/Android/Sdk/platform-tools/adb devices -l
[  +22 ms] List of devices attached
[   +2 ms] Artifact Instance of 'AndroidGenSnapshotArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'AndroidInternalBuildArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'IOSEngineArtifacts' is not required, skipping
update.
[   +1 ms] Artifact Instance of 'WindowsEngineArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'WindowsUwpEngineArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'MacOSEngineArtifacts' is not required, skipping
update.
[        ] Artifact Instance of 'LinuxFuchsiaSDKArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'MacOSFuchsiaSDKArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'FlutterRunnerSDKArtifacts' is not required,
skipping update.
[        ] Artifact Instance of 'FlutterRunnerDebugSymbols' is not required,
skipping update.
[  +41 ms] Multiple devices found:
[  +75 ms] Linux (desktop) • linux  • linux-x64      • Ubuntu 20.04.2 LTS
5.11.0-25-generic
[   +1 ms] Chrome (web)    • chrome • web-javascript • Google Chrome
92.0.4515.131
[   +1 ms] [1]: Linux (linux)
[        ] [2]: Chrome (chrome)
[   +1 ms] Please choose one (To quit, press "q/Q")
[        ] : 

flutter analyze

Analyzing bug...                                                        
No issues found! (ran in 0.8s)

flutter doctor -v

[✓] Flutter (Channel dev, 2.5.0-5.0.pre, on Ubuntu 20.04.2 LTS
    5.11.0-25-generic, locale en_AU.UTF-8)
    • Flutter version 2.5.0-5.0.pre at /home/inno/snap/flutter/common/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 0f465e5b2a (12 days ago), 2021-08-04 18:59:50 -0400
    • Engine revision a0d89b1a54
    • Dart version 2.14.0 (build 2.14.0-377.0.dev)

[!] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
    • Android SDK at /home/inno/Android/Sdk
    ✗ cmdline-tools component is missing
      Run `path/to/sdkmanager --install "cmdline-tools;latest"`
      See https://developer.android.com/studio/command-line for more details.
    ✗ Android license status unknown.
      Run `flutter doctor --android-licenses` to accept the SDK licenses.
      See https://flutter.dev/docs/get-started/install/linux#android-setup for
      more details.

[✓] Chrome - develop for the web
    • Chrome at google-chrome

[✓] Linux toolchain - develop for Linux desktop
    • clang version 6.0.0-1ubuntu2 (tags/RELEASE_600/final)
    • cmake version 3.10.2
    • ninja version 1.8.2
    • pkg-config version 0.29.1

[!] Android Studio
    • Android Studio at /home/inno/Local_Code/android-studio
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    ✗ android-studio-dir = /home/inno/Local_Code/android-studio
    ✗ Android Studio not found at /home/inno/Local_Code/android-studio
    • Try updating or re-installing Android Studio.
    • Consider removing your android-studio-dir setting by running:
      flutter config --android-studio-dir=

[✓] VS Code
    • VS Code at /snap/code/current
    • Flutter extension version 3.25.0

[✓] Connected device (2 available)
    • Linux (desktop) • linux  • linux-x64      • Ubuntu 20.04.2 LTS
      5.11.0-25-generic
    • Chrome (web)    • chrome • web-javascript • Google Chrome 92.0.4515.131

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Important issues not at the top of the work listf: material designflutter/packages/flutter/material repository.found in release: 2.2Found to occur in 2.2found in release: 2.5Found to occur in 2.5frameworkflutter/packages/flutter repository. See also f: labels.has reproducible stepsThe issue has been confirmed reproducible and is ready to work onteam-designOwned by Design Languages teamtriaged-designTriaged by Design Languages team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions