Dropdown.multiSelection constructor
const
Dropdown.multiSelection({
- Key? key,
- required List<
DropdownItem> list, - required dynamic onMultipleItemListener(
- List<
DropdownItem> selectedItemList
- List<
- List<
String> ? selectedIds, - String title = "",
- String labelText = "",
- String hintText = "",
- bool enabled = true,
- double? width,
- double? height,
- TextAlign textAlign = TextAlign.start,
- String? fontFamily,
- InputBorder border = const OutlineInputBorder(),
- InputDecoration? decoration,
- bool searchBox = true,
- String prefixSeparator = _has,
- String suffixSeparator = _comma,
- String searchBoxHintText = _searchHere,
- IconData prefixSearchBoxIcon = _icSearch,
- Color? dialogBackgroundColor,
- Color itemBackgroundColor = Colors.transparent,
- Color selectedItemBackgroundColor = Colors.black12,
- String negativeButtonText = _cancel,
- String positiveButtonText = _ok,
- Color negativeButtonTextColor = Colors.red,
- Color positiveButtonTextColor = Colors.black,
- bool isAllSelection = false,
- Color checkBoxActiveColor = Colors.black,
- bool isAddItem = false,
- bool dismissWhenTapAddItem = true,
- dynamic onTapAddItem(
- String searchValue
- Widget? addItemWidget,
- Widget? noDataWidget,
constructor for single multi dropdown
Implementation
const Dropdown.multiSelection(
{super.key,
required this.list,
required this.onMultipleItemListener,
this.selectedIds,
this.title = "",
this.labelText = "",
this.hintText = "",
this.enabled = true,
this.width,
this.height,
this.textAlign = TextAlign.start,
this.fontFamily,
this.border = const OutlineInputBorder(),
this.decoration,
this.searchBox = true,
this.prefixSeparator = _has,
this.suffixSeparator = _comma,
this.searchBoxHintText = _searchHere,
this.prefixSearchBoxIcon = _icSearch,
this.dialogBackgroundColor,
this.itemBackgroundColor = Colors.transparent,
this.selectedItemBackgroundColor = Colors.black12,
this.negativeButtonText = _cancel,
this.positiveButtonText = _ok,
this.negativeButtonTextColor = Colors.red,
this.positiveButtonTextColor = Colors.black,
this.isAllSelection = false,
this.checkBoxActiveColor = Colors.black,
this.isAddItem = false,
this.dismissWhenTapAddItem = true,
this.onTapAddItem,
this.addItemWidget,
this.noDataWidget})
: selectedId = null,
onSingleItemListener = null,
_isMultiple = true;