getDropBoxWidget method

Widget getDropBoxWidget()

Implementation

Widget getDropBoxWidget(){
  // print("fastor - SpinnerView - getDropBoxWidget() dropdownValue: ${dropdownValue}");
  if( ToolsValidation.isEmpty( dropdownValue) ) {
    dropdownValue = SpinnerView.key_position_hint;
  }
  return DropdownButton<String>(
    value: dropdownValue,
    // icon: widget.iconDropdown,
    // iconSize: 24, //widget.iconSize,
    iconSize: 0, //hide icon

    elevation: 16,
    dropdownColor: widget.colorDropdownMenu,
    focusColor: widget.colorDropdownMenu,
    style: widget.textStyleItemDropdown??TextStyle(
      backgroundColor: widget.colorDropdownTextBackground, // Set the background color here
    ),
    underline: Container(
      height: 2,
      color: widget.underlineColor!,
    ),

    //change
    onChanged: (String? newValue) {
      // Log.i( "getDropBoxWidget() - change: " + newValue.toString() );
      updateSelected(newValue??"0");
    },

    items: listDrop, // mapListWidgetToListMenuItem(),

  );
}