From: cilix42 Date: Wed, 6 Aug 2008 13:22:19 +0000 (+0000) Subject: Esc and Ctrl+Z in pencil tool should also cancel when we're drawing straight line... X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=aebbf53233f5a23dad2ebdd69154897f8562c26f;p=inkscape.git Esc and Ctrl+Z in pencil tool should also cancel when we're drawing straight line (in which case pc->is_drawing will be false) --- diff --git a/src/pencil-context.cpp b/src/pencil-context.cpp index 894b5cd71..f52094ed1 100644 --- a/src/pencil-context.cpp +++ b/src/pencil-context.cpp @@ -503,21 +503,16 @@ pencil_handle_key_press(SPPencilContext *const pc, guint const keyval, guint con break; case GDK_Escape: if (pc->npoints != 0) { - // if drawing, cancel, otherwise pass it up for deselecting - if (pc->is_drawing) { - pencil_cancel (pc); - ret = TRUE; - } + pencil_cancel (pc); + ret = TRUE; } break; case GDK_z: case GDK_Z: if (mod_ctrl_only(state) && pc->npoints != 0) { // if drawing, cancel, otherwise pass it up for undo - if (pc->is_drawing) { - pencil_cancel (pc); - ret = TRUE; - } + pencil_cancel (pc); + ret = TRUE; } break; case GDK_g: