]> git.lyx.org Git - lyx.git/blobdiff - src/DocIterator.cpp
fix #9826: Outline disclosure of subsection content disappears one second after
[lyx.git] / src / DocIterator.cpp
index 9783db14a10d9562df0444c144ced76037b4f87b..28d23e8d110f4f4658e676b6d1b67ad4447a10d4 100644 (file)
@@ -226,6 +226,15 @@ CursorSlice const & DocIterator::innerTextSlice() const
 }
 
 
+DocIterator DocIterator::getInnerText() const
+{
+       DocIterator texted = *this;
+       while (!texted.inTexted())
+               texted.pop_back();
+       return texted;
+}
+
+
 pit_type DocIterator::lastpit() const
 {
        return inMathed() ? 0 : text()->paragraphs().size() - 1;
@@ -590,8 +599,7 @@ void DocIterator::sanitize()
                        fixIfBroken();
                        break;
                }
-               if ((inset->inMathed() && !inset->isActive())
-                   || (!inset->inMathed() && !inset->editable())) {
+               if (!inset->isActive()) {
                        LYXERR0("Inset found on cursor stack is not active.");
                        fixIfBroken();
                        break;