Update select_alignment_button.dart

pull/459/head
mark8044 4 years ago committed by GitHub
parent a809d07bba
commit a66aa5a61b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 8
      lib/src/widgets/toolbar/select_alignment_button.dart

@ -47,25 +47,25 @@ class _SelectAlignmentButtonState extends State<SelectAlignmentButton> {
Attribute.leftAlignment: Attribute.leftAlignment.value!, Attribute.leftAlignment: Attribute.leftAlignment.value!,
Attribute.centerAlignment: Attribute.centerAlignment.value!, Attribute.centerAlignment: Attribute.centerAlignment.value!,
Attribute.rightAlignment: Attribute.rightAlignment.value!, Attribute.rightAlignment: Attribute.rightAlignment.value!,
if (showJustifyAlignment) Attribute.justifyAlignment: Attribute.justifyAlignment.value!, if (widget.showJustifyAlignment) Attribute.justifyAlignment: Attribute.justifyAlignment.value!,
}; };
final _valueAttribute = <Attribute>[ final _valueAttribute = <Attribute>[
Attribute.leftAlignment, Attribute.leftAlignment,
Attribute.centerAlignment, Attribute.centerAlignment,
Attribute.rightAlignment, Attribute.rightAlignment,
if (showJustifyAlignment) Attribute.justifyAlignment if (widget.showJustifyAlignment) Attribute.justifyAlignment
]; ];
final _valueString = <String>[ final _valueString = <String>[
Attribute.leftAlignment.value!, Attribute.leftAlignment.value!,
Attribute.centerAlignment.value!, Attribute.centerAlignment.value!,
Attribute.rightAlignment.value!, Attribute.rightAlignment.value!,
if (showJustifyAlignment) Attribute.justifyAlignment.value!, if (widget.showJustifyAlignment) Attribute.justifyAlignment.value!,
]; ];
final theme = Theme.of(context); final theme = Theme.of(context);
final buttonCount = (showJustifyAlignment == true) ? 4 : 3; final buttonCount = (widget.showJustifyAlignment == true) ? 4 : 3;
return Row( return Row(
mainAxisSize: MainAxisSize.min, mainAxisSize: MainAxisSize.min,

Loading…
Cancel
Save