Fix to bug 2325: Mouse click to right of last nestinset in a cell will

position cursor to its left



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@13370 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Martin Vermeer 2006-03-14 14:47:24 +00:00
parent 9ba33772a8
commit b751c74fe1
2 changed files with 6 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2006-03-14 Martin Vermeer <martin.vermeer@hut.fi>
* math_data.C (x2pos): Fix to bug 2325: Mouse click to right of last
nestinset in a cell will position cursor to its left
2006-03-11 Martin Vermeer <martin.vermeer@hut.fi>
* math_scriptinset.C (notifyCursorLeaves): Fix to bug 2362: Deleting

View File

@ -393,7 +393,7 @@ MathArray::size_type MathArray::x2pos(int targetx, int glue) const
* the right one.
* See bug 1918 for details.
**/
if (it != begin()
if (it != begin() && currx >= targetx
&& ((*boost::prior(it))->asNestInset()
|| abs(lastx - targetx) < abs(currx - targetx))) {
--it;