Refs #120: Center selection dialog

This commit is contained in:
Salvatore Giordano
2020-10-28 18:42:10 +01:00
parent eb81bf7c64
commit 28715551ee

View File

@@ -245,22 +245,24 @@ class CountryCodePickerState extends State<CountryCodePicker> {
barrierColor: widget.barrierColor ?? Colors.grey.withOpacity(0.5), barrierColor: widget.barrierColor ?? Colors.grey.withOpacity(0.5),
backgroundColor: widget.backgroundColor ?? Colors.transparent, backgroundColor: widget.backgroundColor ?? Colors.transparent,
context: context, context: context,
builder: (context) => SelectionDialog( builder: (context) => Center(
elements, child: SelectionDialog(
favoriteElements, elements,
showCountryOnly: widget.showCountryOnly, favoriteElements,
emptySearchBuilder: widget.emptySearchBuilder, showCountryOnly: widget.showCountryOnly,
searchDecoration: widget.searchDecoration, emptySearchBuilder: widget.emptySearchBuilder,
searchStyle: widget.searchStyle, searchDecoration: widget.searchDecoration,
textStyle: widget.dialogTextStyle, searchStyle: widget.searchStyle,
boxDecoration: widget.boxDecoration, textStyle: widget.dialogTextStyle,
showFlag: widget.showFlagDialog != null boxDecoration: widget.boxDecoration,
? widget.showFlagDialog showFlag: widget.showFlagDialog != null
: widget.showFlag, ? widget.showFlagDialog
flagWidth: widget.flagWidth, : widget.showFlag,
size: widget.dialogSize, flagWidth: widget.flagWidth,
hideSearch: widget.hideSearch, size: widget.dialogSize,
closeIcon: widget.closeIcon, hideSearch: widget.hideSearch,
closeIcon: widget.closeIcon,
),
), ),
).then((e) { ).then((e) {
if (e != null) { if (e != null) {