]> git.lyx.org Git - features.git/commit
Fix bug #7209: Crash when clicking on unfinished command in math.
authorVincent van Ravesteijn <vfr@lyx.org>
Mon, 14 Feb 2011 21:30:12 +0000 (21:30 +0000)
committerVincent van Ravesteijn <vfr@lyx.org>
Mon, 14 Feb 2011 21:30:12 +0000 (21:30 +0000)
commitfbaba7782a05784e6667478edd71c8362bf11528
tree3fae923dc9b4d9b3ca54a7af58689fa885b9c014
parentd6d4a80fc6770d38376333adb383c866282c35b3
Fix bug #7209: Crash when clicking on unfinished command in math.

This was a similar problem as for bug #5796 in r30807. There I made sure that the position that is used for the context menu is set at mousepress. That was because also the cursor was set at mousepress and we want to get the context menu at the place where the mousebutton was pressed, and not where the mousebutton was released.

However, in this case, the position of the context menu is stored on mousepress, but we don't take into account that the cursor might move afterwards due to the DEPM.

So, the solution is not to save the position of the mouseclick, but to save the name of the context menu we requested.

PS. Perhaps we could save the cursor position, but this seems to work too.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37669 a592a061-630c-0410-9148-cb99ea01b6c8
src/frontends/qt4/GuiWorkArea.cpp
src/frontends/qt4/GuiWorkArea.h