mirror of
https://github.com/bggRGjQaUbCoE/PiliPlus.git
synced 2026-07-25 04:50:10 +08:00
@@ -43,6 +43,8 @@ $EditableTextPatch = "lib/scripts/editable_text.patch"
|
||||
|
||||
$TextFieldPatch = "lib/scripts/text_field.patch"
|
||||
|
||||
$ScrollPositionPatch = "lib/scripts/scroll_position.patch"
|
||||
|
||||
# TODO: remove
|
||||
# https://github.com/flutter/flutter/pull/183261
|
||||
$SelectableRegionPatch = "lib/scripts/null_safety_for_selectable_region.patch"
|
||||
@@ -75,7 +77,7 @@ $reverts = @()
|
||||
$patches = @($ModalBarrierPatch, $TextSelectionPatch, $MouseCursorPatch,
|
||||
$ImageAnimPatch, $LayoutBuilderPatch, $NavigationDrawerPatch,
|
||||
$PopupMenuPatch, $FABPatch, $SelectableRegionPatch, $SelectableRegionSelectionPatch,
|
||||
$EditableTextPatch, $TextFieldPatch)
|
||||
$EditableTextPatch, $TextFieldPatch, $ScrollPositionPatch)
|
||||
|
||||
switch ($platform.ToLower()) {
|
||||
"android" {
|
||||
|
||||
17
lib/scripts/scroll_position.patch
Normal file
17
lib/scripts/scroll_position.patch
Normal file
@@ -0,0 +1,17 @@
|
||||
diff --git a/packages/flutter/lib/src/widgets/scroll_position_with_single_context.dart b/packages/flutter/lib/src/widgets/scroll_position_with_single_context.dart
|
||||
index 96d77f67008..533fa0eecaf 100644
|
||||
--- a/packages/flutter/lib/src/widgets/scroll_position_with_single_context.dart
|
||||
+++ b/packages/flutter/lib/src/widgets/scroll_position_with_single_context.dart
|
||||
@@ -127,8 +127,10 @@ class ScrollPositionWithSingleContext extends ScrollPosition implements ScrollAc
|
||||
|
||||
@override
|
||||
void applyUserOffset(double delta) {
|
||||
- updateUserScrollDirection(delta > 0.0 ? ScrollDirection.forward : ScrollDirection.reverse);
|
||||
- setPixels(pixels - physics.applyPhysicsToUserOffset(this, delta));
|
||||
+ final newPixels = pixels - physics.applyPhysicsToUserOffset(this, delta);
|
||||
+ if (newPixels != setPixels(newPixels) || _userScrollDirection == ScrollDirection.idle) {
|
||||
+ updateUserScrollDirection(delta > 0.0 ? ScrollDirection.forward : ScrollDirection.reverse);
|
||||
+ }
|
||||
}
|
||||
|
||||
@override
|
||||
@@ -477,7 +477,7 @@ packages:
|
||||
description:
|
||||
path: "."
|
||||
ref: dev
|
||||
resolved-ref: "7cd9461210185bd9e67368b8081195384dc8b919"
|
||||
resolved-ref: de88c222852c33b3203b868794ac45734c8bcec2
|
||||
url: "https://github.com/bggRGjQaUbCoE/extended_nested_scroll_view.git"
|
||||
source: git
|
||||
version: "6.2.1"
|
||||
|
||||
Reference in New Issue
Block a user