]> git.lyx.org Git - lyx.git/blobdiff - src/insets/insetcollapsable.C
Fixed S&R functions with insets.
[lyx.git] / src / insets / insetcollapsable.C
index b5c7cb021230d9764ad86f3b6fd940afbcb49e46..ce43acc582135c7dfc603ace9d0a760c7e93a5fe 100644 (file)
@@ -238,6 +238,9 @@ void InsetCollapsable::edit(BufferView * bv, int xp, int yp,
 
        if (collapsed_) {
                collapsed_ = false;
+               // set this only here as it should be recollapsed only if
+               // it was already collapsed!
+               first_after_edit = true;
                if (!bv->lockInset(this))
                        return;
                bv->updateInset(this, true);
@@ -256,7 +259,6 @@ void InsetCollapsable::edit(BufferView * bv, int xp, int yp,
                        inset.edit(bv, xp, yy, button);
                }
        }
-       first_after_edit = true;
 }