Switch( Key key = null, bool?value = null, ValueChanged <bool?> onChanged = null, Color activeColor = null, Color activeTrackColor = null, Color inactiveThumbColor = null, Color inactiveTrackColor = null, ImageProvider activeThumbImage = null, ImageProvider inactiveThumbImage = null, MaterialTapTargetSize?materialTapTargetSize = null, _SwitchType switchType = _SwitchType.material, DragStartBehavior dragStartBehavior = DragStartBehavior.start ) : base(key : key) { D.assert(value != null); this.value = value.Value; D.assert(onChanged != null); this.onChanged = onChanged; this.activeColor = activeColor; this.activeTrackColor = activeTrackColor; this.inactiveThumbColor = inactiveThumbColor; this.inactiveTrackColor = inactiveTrackColor; this.activeThumbImage = activeThumbImage; this.inactiveThumbImage = inactiveThumbImage; this.materialTapTargetSize = materialTapTargetSize; this._switchType = switchType; this.dragStartBehavior = dragStartBehavior; }
Switch( Key key = null, bool?value = null, ValueChanged <bool?> onChanged = null, Color activeColor = null, Color activeTrackColor = null, Color inactiveThumbColor = null, Color inactiveTrackColor = null, ImageProvider activeThumbImage = null, ImageErrorListener onActiveThumbImageError = null, ImageProvider inactiveThumbImage = null, ImageErrorListener onInactiveThumbImageError = null, MaterialTapTargetSize?materialTapTargetSize = null, _SwitchType switchType = _SwitchType.material, DragStartBehavior dragStartBehavior = DragStartBehavior.start, Color focusColor = null, Color hoverColor = null, FocusNode focusNode = null, bool autofocus = false ) : base(key : key) { D.assert(value != null); this.value = value.Value; D.assert(activeThumbImage != null || onActiveThumbImageError == null); D.assert(inactiveThumbImage != null || onInactiveThumbImageError == null); this.onChanged = onChanged; this.activeColor = activeColor; this.activeTrackColor = activeTrackColor; this.inactiveThumbColor = inactiveThumbColor; this.inactiveTrackColor = inactiveTrackColor; this.activeThumbImage = activeThumbImage; this.onActiveThumbImageError = onActiveThumbImageError; this.inactiveThumbImage = inactiveThumbImage; this.onInactiveThumbImageError = onInactiveThumbImageError; this.materialTapTargetSize = materialTapTargetSize; _switchType = switchType; this.dragStartBehavior = dragStartBehavior; this.focusColor = focusColor; this.hoverColor = hoverColor; this.focusNode = focusNode; this.autofocus = autofocus; }