* Only enter inset which return true on isActive(). This is the behavior in the cursor code.

Only newly created inset were entered everytime.
* Derived classes of CommandInset do not draw all cells, so return false.
  (fixes http://bugzilla.lyx.org/show_bug.cgi?id=3715)


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18742 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Stefan Schimanski 2007-06-11 18:26:42 +00:00
parent 22421dffb3
commit b7ce285f8b
2 changed files with 4 additions and 1 deletions

View File

@ -40,6 +40,9 @@ public:
virtual docstring const screenLabel() const;
///
docstring const & commandname() const { return name_; }
///
bool isActive() const { return false; }
private:
virtual std::auto_ptr<Inset> doClone() const;

View File

@ -732,7 +732,7 @@ goto_char_backwards:
&& cur.inMacroMode() && cur.macroName() != "\\"
&& cur.macroModeClose()) {
MathAtom const atom = cur.prevAtom();
if (atom->asNestInset() && atom->nargs() > 0) {
if (atom->asNestInset() && atom->isActive()) {
cur.posLeft();
cur.pushLeft(*cur.nextInset());
}