]> git.lyx.org Git - lyx.git/commit
Fix bug 5797: http://bugzilla.lyx.org/show_bug.cgi?id=5797.
authorVincent van Ravesteijn <vfr@lyx.org>
Mon, 23 Feb 2009 19:00:23 +0000 (19:00 +0000)
committerVincent van Ravesteijn <vfr@lyx.org>
Mon, 23 Feb 2009 19:00:23 +0000 (19:00 +0000)
commit8e2babb83385476f08a474891dd8df100626c025
tree3e8c9b2d4a451e265d999161d4b6fc0907b49f7b
parenta5c0cef5a0f908deea3241c3cec7f60b41339f84
Fix bug 5797: http://bugzilla.lyx.org/show_bug.cgi?id=5797.
GetStatus of an InsetCollapsable asserts for unhandled commands.

When you add a command to the context menu of an InsetCollapsable of which the getStatus method does not handle this command, an assertion will be raised. This happens when getStatus doesn't handle a command it is forwarded to text::getStatus which asserts because cur.text() is the text the inset is in, while this is the text of the inset. So, we only dispatch to text_ if the cursor is inside the text_. This is not the case for e.g. context menus.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@28588 a592a061-630c-0410-9148-cb99ea01b6c8
src/insets/InsetText.cpp