mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
Fixing example
This commit is contained in:
parent
196c19178a
commit
17899ebb5b
@ -23,7 +23,19 @@ import 'theme.dart';
|
||||
/// removing the item at oldIndex from the list will
|
||||
/// reduce the list's length by one.
|
||||
/// Implementations will need to account for this
|
||||
/// when inserting before newIndex.
|
||||
/// when inserting before newIndex. Typically the [onReorder]
|
||||
/// callback adjusts its index parameters like this:
|
||||
///
|
||||
/// ```
|
||||
/// onReorder: (int oldIndex, int newIndex) {
|
||||
/// if (oldIndex < newIndex) {
|
||||
/// // removing the item at oldIndex will shorten the list by 1.
|
||||
/// newIndex -= 1;
|
||||
/// }
|
||||
/// ....
|
||||
/// }
|
||||
/// ```
|
||||
///
|
||||
///
|
||||
/// {@tool dartpad}
|
||||
///
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user