From 124bc762a735d482e12d54022008e919dff76978 Mon Sep 17 00:00:00 2001 From: Enrico Forestieri Date: Mon, 30 Apr 2012 23:55:34 +0200 Subject: [PATCH] Fix bug #8140: Crash with math macros and input completion When clicking away in the same math inset after hitting '\', the cursor may be broken and all of its instances have to be fixed. (cherry picked from commit 982562179801340feff7eb108addd99ec4a05d08) --- src/BufferView.cpp | 4 ++-- status.20x | 3 +++ 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/BufferView.cpp b/src/BufferView.cpp index d8a67f2cdb..b0d3135b41 100644 --- a/src/BufferView.cpp +++ b/src/BufferView.cpp @@ -2171,8 +2171,8 @@ void BufferView::mouseEventDispatch(FuncRequest const & cmd0) // Notify left insets if (cur != old) { - old.fixIfBroken(); - bool badcursor = notifyCursorLeavesOrEnters(old, cur); + bool badcursor = old.fixIfBroken() | cur.fixIfBroken() + | notifyCursorLeavesOrEnters(old, cur); if (badcursor) cursor().fixIfBroken(); } diff --git a/status.20x b/status.20x index 72ed28d24f..46bba5f6bb 100644 --- a/status.20x +++ b/status.20x @@ -162,6 +162,9 @@ What's new - Fix the coloring of Quotation marks with change tracking (bug 7653). +- Fix crash when clicking away in the same math inset just after hitting '\' + (bug 8140). + * DOCUMENTATION AND LOCALIZATION -- 2.39.5