copyWith method
MouseMsg
copyWith({
- MouseAction? action,
- MouseButton? button,
- int? x,
- int? y,
- bool? ctrl,
- bool? alt,
- bool? shift,
Creates a copy of this message with some fields replaced.
Implementation
MouseMsg copyWith({
MouseAction? action,
MouseButton? button,
int? x,
int? y,
bool? ctrl,
bool? alt,
bool? shift,
}) {
return MouseMsg(
action: action ?? this.action,
button: button ?? this.button,
x: x ?? this.x,
y: y ?? this.y,
ctrl: ctrl ?? this.ctrl,
alt: alt ?? this.alt,
shift: shift ?? this.shift,
);
}