[PATCH] Make Undo & Redo work with the visual formula editor.

Luke Dixon 6b8b4567 at gmail.com
Sun Feb 13 08:28:22 PST 2011


---
 starmath/source/cursor.cxx   |    2 +-
 starmath/source/document.cxx |    1 +
 2 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/starmath/source/cursor.cxx b/starmath/source/cursor.cxx
index 33ae549..4e65f48 100644
--- a/starmath/source/cursor.cxx
+++ b/starmath/source/cursor.cxx
@@ -1461,7 +1461,7 @@ void SmCursor::EndEdit(){
     SmNodeToTextVisitor(pTree, formula);
     //pTree->CreateTextFromNode(formula);
     pDocShell->aText = formula;
-    pDocShell->GetEditEngine().SetText(formula);
+    pDocShell->GetEditEngine().SetText(0, formula);
 }
 
 void SmCursor::RequestRepaint(){
diff --git a/starmath/source/document.cxx b/starmath/source/document.cxx
index d98c406..eddbe9b 100644
--- a/starmath/source/document.cxx
+++ b/starmath/source/document.cxx
@@ -1174,6 +1174,7 @@ void SmDocShell::Execute(SfxRequest& rReq)
                     (pTmpUndoMgr->*fnDo)( 0 );
             }
             Repaint();
+            UpdateText();
             SfxViewFrame* pFrm = SfxViewFrame::GetFirst( this );
             while( pFrm )
             {
-- 
1.7.4


--=-RB0eDbB0JKPu9LunGf2H--



More information about the LibreOffice mailing list