diff options
author | Caolán McNamara <caolanm@redhat.com> | 2012-09-12 15:45:04 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2012-09-12 16:33:54 +0100 |
commit | 85b0beae596e3177e0435d313a0ee4e90a6fde77 (patch) | |
tree | aaa31e050c9291a11e561f30bbb6a6bb3a6a532d /sw | |
parent | 5a27cae5883be57ee58e44c4dd288752912600c7 (diff) |
Resolves: fdo#40025 add text correction undo id
instead of a single overwrite foo so now the undo message is
"Text Correction" for a spell or grammar change
Change-Id: I0227780ba9024ff903632923dd94238719b65764
Diffstat (limited to 'sw')
-rw-r--r-- | sw/inc/swundo.hxx | 3 | ||||
-rw-r--r-- | sw/source/core/edit/edlingu.cxx | 4 | ||||
-rw-r--r-- | sw/source/core/undo/undo.hrc | 3 | ||||
-rw-r--r-- | sw/source/core/undo/undo.src | 4 |
4 files changed, 10 insertions, 4 deletions
diff --git a/sw/inc/swundo.hxx b/sw/inc/swundo.hxx index 9e0715404d3a..ade8718199b5 100644 --- a/sw/inc/swundo.hxx +++ b/sw/inc/swundo.hxx @@ -178,7 +178,8 @@ enum SwUndoId UNDO_UI_INSERT_URLTXT, UNDO_UI_DELETE_INVISIBLECNTNT, UNDO_UI_REPLACE_STYLE, - UNDO_UI_DELETE_PAGE_BREAK + UNDO_UI_DELETE_PAGE_BREAK, + UNDO_UI_TEXT_CORRECTION }; diff --git a/sw/source/core/edit/edlingu.cxx b/sw/source/core/edit/edlingu.cxx index e0c30ecf6e2d..17feb3ec842c 100644 --- a/sw/source/core/edit/edlingu.cxx +++ b/sw/source/core/edit/edlingu.cxx @@ -1289,7 +1289,7 @@ void SwEditShell::ApplyChangedSentence(const ::svx::SpellPortions& rNewPortions, // iterate over the new portions, beginning at the end to take advantage of the previously // saved content positions - pDoc->GetIDocumentUndoRedo().StartUndo( UNDO_OVERWRITE, NULL ); + pDoc->GetIDocumentUndoRedo().StartUndo( UNDO_UI_TEXT_CORRECTION, NULL ); StartAction(); SwPaM *pCrsr = GetCrsr(); @@ -1418,7 +1418,7 @@ void SwEditShell::ApplyChangedSentence(const ::svx::SpellPortions& rNewPortions, // set continuation position for spell/grammar checking to the end of this sentence pSpellIter->SetCurr( new SwPosition( *pCrsr->Start() ) ); - pDoc->GetIDocumentUndoRedo().EndUndo( UNDO_OVERWRITE, NULL ); + pDoc->GetIDocumentUndoRedo().EndUndo( UNDO_UI_TEXT_CORRECTION, NULL ); EndAction(); } } diff --git a/sw/source/core/undo/undo.hrc b/sw/source/core/undo/undo.hrc index 2bd47c6b87db..57a56a36395b 100644 --- a/sw/source/core/undo/undo.hrc +++ b/sw/source/core/undo/undo.hrc @@ -161,7 +161,8 @@ #define STR_DELETE_INVISIBLECNTNT (UI_UNDO_BEGIN + 12) #define STR_REPLACE_STYLE (UI_UNDO_BEGIN + 13) #define STR_DELETE_PAGE_BREAK (UI_UNDO_BEGIN + 14) -#define UI_UNDO_END STR_DELETE_PAGE_BREAK +#define STR_TEXT_CORRECTION (UI_UNDO_BEGIN + 15) +#define UI_UNDO_END STR_TEXT_CORRECTION #define UNDO_MORE_STRINGS_BEGIN (UI_UNDO_END + 1) #define STR_OCCURRENCES_OF (UNDO_MORE_STRINGS_BEGIN) diff --git a/sw/source/core/undo/undo.src b/sw/source/core/undo/undo.src index d1222feb01e7..a8104f750b7a 100644 --- a/sw/source/core/undo/undo.src +++ b/sw/source/core/undo/undo.src @@ -193,6 +193,10 @@ String STR_DELETE_PAGE_BREAK { Text [ en-US ] = "Delete page break" ; }; +String STR_TEXT_CORRECTION +{ + Text [ en-US ] = "Text Correction" ; +}; String STR_OUTLINE_LR { Text [ en-US ] = "Promote/demote outline" ; |