]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/InsetMathGrid.cpp
Another warning.
[lyx.git] / src / mathed / InsetMathGrid.cpp
index b4c3b2b611fa40bccb3f7f3358c994dad2e26149..d37870d4ada3b7cc24908a559b75394e0c789e44 100644 (file)
@@ -644,12 +644,9 @@ void InsetMathGrid::updateBuffer(ParIterator const & it, UpdateType utype)
 }
 
 
-docstring InsetMathGrid::eolString(row_type row, bool fragile, bool last_eoln) const
+docstring InsetMathGrid::eolString(row_type row, bool fragile,
+               bool /*latex*/, bool last_eoln) const
 {
-       // Never add \\ on the last empty line of substack, tabular and xymatrix
-       if (asSubstackInset() || asTabularInset() || asXYMatrixInset())
-               last_eoln = false;
-
        docstring eol;
 
        if (!rowinfo_[row].crskip_.zero())
@@ -1065,7 +1062,7 @@ void InsetMathGrid::write(WriteStream & os,
                                ModeSpecifier specifier(os, TEXT_MODE);
                        os << eocString(col, lastcol);
                }
-               eol = eolString(row, os.fragile(), last_eoln);
+               eol = eolString(row, os.fragile(), os.latex(), last_eoln);
                os << eol;
                // append newline only if line wasn't completely empty
                // and the formula is not written on a single line
@@ -1375,10 +1372,9 @@ void InsetMathGrid::doDispatch(Cursor & cur, FuncRequest & cmd)
                                        cell(i).append(grid.cell(grid.index(r, c)));
                }
                cur.clearSelection(); // bug 393
-               // FIXME audit setBuffer/updateBuffer calls
+               // FIXME audit setBuffer calls
                cur.inset().setBuffer(*buffer_);
-               // FIXME audit setBuffer/updateBuffer calls
-               cur.buffer()->updateBuffer();
+               cur.forceBufferUpdate();
                cur.finishUndo();
                break;
        }