Toggle navigation
Toggle navigation
This project
Loading...
Sign in
flutter_package
/
modal_bottom_sheet
Go to a project
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
minnu
2020-09-13 04:14:12 +0530
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Committed by
GitHub
2020-09-13 04:14:12 +0530
Commit
b8f2a7e394a64b37a5f0dbd030a64b8a5cfee4e1
b8f2a7e3
1 parent
54b926a3
VelocityTracker() has a fix with positional arguments
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
1 deletions
lib/src/bottom_sheet.dart
lib/src/bottom_sheet.dart
View file @
b8f2a7e
...
...
@@ -300,7 +300,17 @@ class _ModalBottomSheetState extends State<ModalBottomSheet>
// Otherwise the calculate the velocity with a VelocityTracker
if
(
_velocityTracker
==
null
)
{
_velocityTracker
=
VelocityTracker
();
// Checking the device type as per the OS installed in it
// SmartPhone Devices
if
(
Platform
.
isAndroid
||
Platform
.
isIOS
)
{
_velocityTracker
=
VelocityTracker
(
PointerDeviceKind
.
touch
);
}
// PCs or desktops or Laptops devices has mouse pointers
else
if
(
Platform
.
isLinux
||
Platform
.
isWindows
||
Platform
.
isMacOS
)
{
_velocityTracker
=
VelocityTracker
(
PointerDeviceKind
.
mouse
);
}
else
{
_velocityTracker
=
VelocityTracker
(
PointerDeviceKind
.
unknown
);
}
_startTime
=
DateTime
.
now
();
}
DragUpdateDetails
dragDetails
;
...
...
Please
register
or
login
to post a comment