Make the Pen Tool confirm when leaving the tool
This commit is contained in:
parent
dd8cd4a2fa
commit
30418c51f8
|
|
@ -117,7 +117,7 @@ impl Fsm for PenToolFsmState {
|
|||
|
||||
Dragging
|
||||
}
|
||||
(Dragging, Confirm) => {
|
||||
(Dragging, Confirm) | (Dragging, Abort) => {
|
||||
if data.points.len() >= 2 {
|
||||
responses.push_back(DocumentMessage::DeselectAllLayers.into());
|
||||
responses.extend(make_operation(data, tool_data, false));
|
||||
|
|
@ -132,14 +132,6 @@ impl Fsm for PenToolFsmState {
|
|||
|
||||
Ready
|
||||
}
|
||||
(Dragging, Abort) => {
|
||||
responses.push_back(DocumentMessage::AbortTransaction.into());
|
||||
data.points.clear();
|
||||
data.path = None;
|
||||
data.snap_handler.cleanup();
|
||||
|
||||
Ready
|
||||
}
|
||||
_ => self,
|
||||
}
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Reference in New Issue