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
tb2761
2020-04-11 14:05:54 +0200
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
4c967b141f55e4d926490d4ed4e38de92ed8fc2c
4c967b14
1 parent
87ba601c
fix detection if MaterialLocalizations is available
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
lib/src/bottom_sheets/cupertino_bottom_sheet.dart
lib/src/bottom_sheets/cupertino_bottom_sheet.dart
View file @
4c967b1
...
...
@@ -83,12 +83,12 @@ Future<T> showCupertinoModalBottomSheet<T>({
assert
(
useRootNavigator
!=
null
);
assert
(
enableDrag
!=
null
);
assert
(
debugCheckHasMediaQuery
(
context
));
final
isCupertinoApp
=
Theme
.
of
(
context
,
shadowThemeOnly:
true
)
==
null
;
String
barrierLabel
=
''
;
if
(!
isCupertinoApp
)
{
assert
(
debugCheckHasMaterialLocalizations
(
context
));
barrierLabel
=
MaterialLocalizations
.
of
(
context
).
modalBarrierDismissLabel
;
}
final
hasMaterialLocalizations
=
Localizations
.
of
<
MaterialLocalizations
>(
context
,
MaterialLocalizations
)
!=
null
;
final
barrierLabel
=
hasMaterialLocalizations
?
MaterialLocalizations
.
of
(
context
).
modalBarrierDismissLabel
:
''
;
final
result
=
await
Navigator
.
of
(
context
,
rootNavigator:
useRootNavigator
)
.
push
(
CupertinoModalBottomSheetRoute
<
T
>(
...
...
Please
register
or
login
to post a comment