xBuilder_XMenu method
Implementation
Widget xBuilder_XMenu(XMenuGroup xclMenu) {
return Column(
children: [
XContainerWithLabel(
xclMenu.label,
color: xclMenu.color_BTN,
textStyle: XStyles.xStyTextForLabel(xclMenu.label_Color ?? XColors.foregroundLight),
),
Wrap(
spacing: 5,
runSpacing: 5,
runAlignment: WrapAlignment.center,
alignment: WrapAlignment.center,
children: xclMenu.items.map((xclMenuItem) {
return XBtnbase(
//margin: EdgeInsets.symmetric(vertical: 5),
label: xclMenuItem.label,
label_Color: xclMenuItem.label_Color,
backGroundColor: xclMenuItem.color_BTN,
icon: xclMenuItem.icon_BTN,
icon_Widget: xclMenuItem.image_Icon_BTN != null ? Image.memory(xclMenuItem.image_Icon_BTN!) : null,
label_Style: XStyles.xStyTextForLargeTitle(xclMenuItem.label_Color),
width: width_menuItems ?? menuItem_WidthDefault,
height: height_menuItems ?? 40,
onPressed: () {
//xclMenuItem.onPressed
if (xclMenuItem.onPressed != null) {
xclMenuItem.onPressed!(xclMenuItem);
}
//onPressed_MenuItem
else if (onPressed_MenuItem != null) {
onPressed_MenuItem!(xclMenuItem);
}
tabLink();
},
);
}).toList(),
)
],
);
}