summaryrefslogtreecommitdiff
path: root/sw/source/uibase/uiview
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-03-16 09:11:42 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-03-16 07:56:25 +0000
commit8ae9dcec653c4ad3eeb8c3e1fa9b1684e2bd64a2 (patch)
treed72e1a17603bb146cce0d02ffeec46acb57335c6 /sw/source/uibase/uiview
parent3b7d751ad4f950aae0641a75b2ea993025629c9d (diff)
convert SwUndoId to scoped enum
Change-Id: I782fdd53641c0d7c629265b6179de70aa54382f9 Reviewed-on: https://gerrit.libreoffice.org/35246 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw/source/uibase/uiview')
-rw-r--r--sw/source/uibase/uiview/formatclipboard.cxx4
-rw-r--r--sw/source/uibase/uiview/view2.cxx2
-rw-r--r--sw/source/uibase/uiview/viewling.cxx12
-rw-r--r--sw/source/uibase/uiview/viewsrch.cxx2
4 files changed, 10 insertions, 10 deletions
diff --git a/sw/source/uibase/uiview/formatclipboard.cxx b/sw/source/uibase/uiview/formatclipboard.cxx
index 99e49c2ce089..ea79b16805a0 100644
--- a/sw/source/uibase/uiview/formatclipboard.cxx
+++ b/sw/source/uibase/uiview/formatclipboard.cxx
@@ -467,7 +467,7 @@ void SwFormatClipboard::Paste( SwWrtShell& rWrtShell, SfxStyleSheetBasePool* pPo
}
rWrtShell.StartAction();
- rWrtShell.StartUndo(UNDO_INSATTR);
+ rWrtShell.StartUndo(SwUndoId::INSATTR);
ItemVector aItemVector;
@@ -573,7 +573,7 @@ void SwFormatClipboard::Paste( SwWrtShell& rWrtShell, SfxStyleSheetBasePool* pPo
if( m_pTableItemSet && nSelectionType & (nsSelectionType::SEL_TBL | nsSelectionType::SEL_TBL_CELLS) )
lcl_setTableAttributes( *m_pTableItemSet, rWrtShell );
- rWrtShell.EndUndo(UNDO_INSATTR);
+ rWrtShell.EndUndo(SwUndoId::INSATTR);
rWrtShell.EndAction();
if(!m_bPersistentCopy)
diff --git a/sw/source/uibase/uiview/view2.cxx b/sw/source/uibase/uiview/view2.cxx
index 50928019c4f9..7b534fdc0f7a 100644
--- a/sw/source/uibase/uiview/view2.cxx
+++ b/sw/source/uibase/uiview/view2.cxx
@@ -447,7 +447,7 @@ bool SwView::InsertGraphicDlg( SfxRequest& rReq )
// #i123922# determine if we really want to insert or replace the graphic at a selected object
const bool bReplaceMode(rSh.HasSelection() && nsSelectionType::SEL_FRM == rSh.GetSelectionType());
- rSh.StartUndo(UNDO_INSERT, &aRewriter);
+ rSh.StartUndo(SwUndoId::INSERT, &aRewriter);
int nError = InsertGraphic( aFileName, aFilterName, bAsLink, &GraphicFilter::GetGraphicFilter() );
diff --git a/sw/source/uibase/uiview/viewling.cxx b/sw/source/uibase/uiview/viewling.cxx
index 55b1c55c3726..1b3a9a80aec1 100644
--- a/sw/source/uibase/uiview/viewling.cxx
+++ b/sw/source/uibase/uiview/viewling.cxx
@@ -181,11 +181,11 @@ void SwView::ExecLingu(SfxRequest &rReq)
// since this conversion is not interactive the whole converted
// document should be undone in a single undo step.
- m_pWrtShell->StartUndo( UNDO_OVERWRITE );
+ m_pWrtShell->StartUndo( SwUndoId::OVERWRITE );
StartTextConversion( nSourceLang, nTargetLang, &aTargetFont, nOptions, false );
- m_pWrtShell->EndUndo( UNDO_OVERWRITE );
+ m_pWrtShell->EndUndo( SwUndoId::OVERWRITE );
if (bRestoreCursor)
{
@@ -448,7 +448,7 @@ void SwView::HyphenateDocument()
Reference< XLinguProperties > xProp( ::GetLinguPropertySet() );
- m_pWrtShell->StartUndo(UNDO_INSATTR); // valid later
+ m_pWrtShell->StartUndo(SwUndoId::INSATTR); // valid later
bool bHyphSpecial = xProp.is() && xProp->getIsHyphSpecial();
bool bSelection = static_cast<SwCursorShell*>(m_pWrtShell)->HasSelection() ||
@@ -477,7 +477,7 @@ void SwView::HyphenateDocument()
{
SwHyphWrapper aWrap( this, xHyph, bStart, bOther, bSelection );
aWrap.SpellDocument();
- m_pWrtShell->EndUndo(UNDO_INSATTR);
+ m_pWrtShell->EndUndo(SwUndoId::INSATTR);
}
pVOpt->SetIdle( bOldIdle );
}
@@ -504,7 +504,7 @@ void SwView::InsertThesaurusSynonym( const OUString &rSynonmText, const OUString
m_pWrtShell->SetInsMode();
m_pWrtShell->StartAllAction();
- m_pWrtShell->StartUndo(UNDO_DELETE);
+ m_pWrtShell->StartUndo(SwUndoId::DELETE);
if( !bSelection )
{
@@ -534,7 +534,7 @@ void SwView::InsertThesaurusSynonym( const OUString &rSynonmText, const OUString
m_pWrtShell->Insert( rSynonmText );
- m_pWrtShell->EndUndo(UNDO_DELETE);
+ m_pWrtShell->EndUndo(SwUndoId::DELETE);
m_pWrtShell->EndAllAction();
m_pWrtShell->SetInsMode( bOldIns );
diff --git a/sw/source/uibase/uiview/viewsrch.cxx b/sw/source/uibase/uiview/viewsrch.cxx
index f29aa9427924..70857e6e7a8b 100644
--- a/sw/source/uibase/uiview/viewsrch.cxx
+++ b/sw/source/uibase/uiview/viewsrch.cxx
@@ -686,7 +686,7 @@ void SwView::Replace()
aRewriter.AddRule(UndoArg2, SW_RESSTR(STR_YIELDS));
aRewriter.AddRule(UndoArg3, m_pSrchItem->GetReplaceString());
- m_pWrtShell->StartUndo(UNDO_UI_REPLACE_STYLE, &aRewriter);
+ m_pWrtShell->StartUndo(SwUndoId::UI_REPLACE_STYLE, &aRewriter);
m_pWrtShell->SetTextFormatColl( m_pWrtShell->GetParaStyle(
m_pSrchItem->GetReplaceString(),