Skip to content

Commit

Permalink
* Check scrollable state if mounted on finding key of ScrollPosition. #…
Browse files Browse the repository at this point in the history
…78

* Igore inner position when inner delta is minimal value. #74
  • Loading branch information
zmtzawqlp committed Jul 15, 2021
1 parent 0b2e3f8 commit eb89f47
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 3 deletions.
6 changes: 5 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
## 3.0.1-non-null-safety

* Check scrollable state if mounted on finding key of ScrollPosition. #78
* Igore inner position when inner delta is minimal value. #74
## 3.0.0-non-null-safety

non-null-safety
* non-null-safety
## 2.0.1

* Fix issue that list sync issue is not fixed #40
Expand Down
14 changes: 13 additions & 1 deletion lib/src/old_extended_nested_scroll_view.dart
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import 'dart:async';
import 'dart:math' as math;
import 'package:extended_nested_scroll_view/src/nested_scroll_view_inner_scroll_position_key_widget.dart';
import 'package:flutter/foundation.dart';
import 'package:flutter/gestures.dart';
import 'package:flutter/painting.dart';
import 'package:flutter/physics.dart';
Expand Down Expand Up @@ -928,7 +929,18 @@ class _NestedScrollCoordinator
if (outerDelta != 0.0) {
final double innerDelta =
_outerPosition.applyClampedPointerSignalUpdate(outerDelta);
if (innerDelta != 0.0) {

// this is a bug that the out postion is not overscroll actually and it get minimal value
// do under code will scroll inner positions
// igore minimal value here(value like following data)
// I/flutter (14963): 5.684341886080802e-14
// I/flutter (14963): -5.684341886080802e-14
// I/flutter (14963): -5.684341886080802e-14
// I/flutter (14963): 5.684341886080802e-14
// I/flutter (14963): -5.684341886080802e-14
// I/flutter (14963): -5.684341886080802e-14
// I/flutter (14963): -5.684341886080802e-14
if (innerDelta.abs() > precisionErrorTolerance) {
for (final _NestedScrollPosition position in _currentInnerPositions)
position.applyClampedPointerSignalUpdate(innerDelta);
}
Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: extended_nested_scroll_view
description: extended nested scroll view to fix pinned header and inner scrollables sync issues.
version: 3.0.0-non-null-safety
version: 3.0.1-non-null-safety
homepage: https://github.com/fluttercandies/extended_nested_scroll_view

environment:
Expand Down

0 comments on commit eb89f47

Please sign in to comment.