[gimp/gimp-2-10] app: fix CRITICAL when initializing the perspective-clone tool
- From: Ell <ell src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp/gimp-2-10] app: fix CRITICAL when initializing the perspective-clone tool
- Date: Thu, 31 Jan 2019 14:14:09 +0000 (UTC)
commit 297971e4478b0434ab20672c5f50f64c6e097cc6
Author: Ell <ell_se yahoo com>
Date: Thu Jan 31 09:06:22 2019 -0500
app: fix CRITICAL when initializing the perspective-clone tool
When initializaing the perspective-clone tool in paint mode, the
GimpDrawTool may already be active, causing the call to
gimp_draw_tool_start() to fail with a CRITICAL. Stop the draw tool
first, if active, to avoid that.
(cherry picked from commit 07d2d5af5a0fb11ba544fddedba0481e2a91651f)
app/tools/gimpperspectiveclonetool.c | 3 +++
1 file changed, 3 insertions(+)
---
diff --git a/app/tools/gimpperspectiveclonetool.c b/app/tools/gimpperspectiveclonetool.c
index f05f010ec2..308e2be643 100644
--- a/app/tools/gimpperspectiveclonetool.c
+++ b/app/tools/gimpperspectiveclonetool.c
@@ -260,6 +260,9 @@ gimp_perspective_clone_tool_initialize (GimpTool *tool,
clone_tool);
/* start drawing the bounding box and handles... */
+ if (gimp_draw_tool_is_active (GIMP_DRAW_TOOL (tool)))
+ gimp_draw_tool_stop (GIMP_DRAW_TOOL (tool));
+
gimp_draw_tool_start (GIMP_DRAW_TOOL (tool), display);
/* Save the current transformation info */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]