From 67891b48c3875d9f87592aeabf9d42180680750b Mon Sep 17 00:00:00 2001 From: Jean-Marc Lasgouttes Date: Wed, 20 Apr 2005 10:47:15 +0000 Subject: [PATCH] fix double/triple clicking to select (bug 1811) git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@9838 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/ChangeLog | 5 +++++ src/insets/ChangeLog | 5 +++++ src/insets/insetcollapsable.C | 5 ----- src/text3.C | 2 ++ 4 files changed, 12 insertions(+), 5 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 658114fbdb..6e2e613260 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2005-04-19 Jürgen Spitzmüller + + * text3.C (dispatch): set cursor on double/triple click events + (bug 1811) + 2005-04-14 Jean-Marc Lasgouttes * lyxfunc.C (actOnUpdatedPrefs): avoid warning diff --git a/src/insets/ChangeLog b/src/insets/ChangeLog index 2bcc2f35c6..c4faedf9d8 100644 --- a/src/insets/ChangeLog +++ b/src/insets/ChangeLog @@ -1,3 +1,8 @@ +2005-04-19 Jean-Marc Lasgouttes + + * insetcollapsable.C (doDispatch): pass through double/triple + click events (bug 1811). + 2005-04-14 Jean-Marc Lasgouttes * insetwrap.C (addToToc): copy the code from InsetFloat::addToToc. diff --git a/src/insets/insetcollapsable.C b/src/insets/insetcollapsable.C index 34e3d6b228..e22c1d63bc 100644 --- a/src/insets/insetcollapsable.C +++ b/src/insets/insetcollapsable.C @@ -340,11 +340,6 @@ void InsetCollapsable::doDispatch(LCursor & cur, FuncRequest & cmd) } break; - case LFUN_MOUSE_DOUBLE: - case LFUN_MOUSE_TRIPLE: - cur.undispatched(); - break; - case LFUN_INSET_TOGGLE: if (cmd.argument == "open") setStatus(Open); diff --git a/src/text3.C b/src/text3.C index aff6aeb9bf..a770c0fb50 100644 --- a/src/text3.C +++ b/src/text3.C @@ -981,6 +981,7 @@ void LyXText::dispatch(LCursor & cur, FuncRequest & cmd) cur.resetAnchor(); cursorEnd(cur); cur.setSelection(); + bv->cursor() = cur; bv->haveSelection(cur.selection()); } break; @@ -988,6 +989,7 @@ void LyXText::dispatch(LCursor & cur, FuncRequest & cmd) case LFUN_MOUSE_DOUBLE: if (cmd.button() == mouse_button::button1) { selectWord(cur, lyx::WHOLE_WORD_STRICT); + bv->cursor() = cur; bv->haveSelection(cur.selection()); } break;