From 86d9abeea7f9a0c0c7b63540ea20c41264cde991 Mon Sep 17 00:00:00 2001 From: Guillaume Munch Date: Sat, 18 Feb 2017 23:03:53 +0100 Subject: [PATCH] Move cursor in front of InsetMathSpace before opening the dialog (#7749) --- src/mathed/InsetMathSpace.cpp | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/src/mathed/InsetMathSpace.cpp b/src/mathed/InsetMathSpace.cpp index 39f3147bf1..0adce6ff28 100644 --- a/src/mathed/InsetMathSpace.cpp +++ b/src/mathed/InsetMathSpace.cpp @@ -305,8 +305,6 @@ bool InsetMathSpace::getStatus(Cursor & cur, FuncRequest const & cmd, case LFUN_INSET_MODIFY: case LFUN_INSET_DIALOG_UPDATE: case LFUN_MOUSE_RELEASE: - case LFUN_MOUSE_PRESS: - case LFUN_MOUSE_MOTION: status.setEnabled(true); return true; default: @@ -332,18 +330,13 @@ void InsetMathSpace::doDispatch(Cursor & cur, FuncRequest & cmd) break; case LFUN_MOUSE_RELEASE: - if (cmd.button() == mouse_button::button1) { + if (cmd.button() == mouse_button::button1 && !cur.selection()) { showInsetDialog(&cur.bv()); break; } cur.undispatched(); break; - case LFUN_MOUSE_PRESS: - case LFUN_MOUSE_MOTION: - // eat other mouse commands - break; - default: InsetMath::doDispatch(cur, cmd); break; -- 2.39.5