summaryrefslogtreecommitdiff
path: root/editeng
diff options
context:
space:
mode:
authorNorbert Thiebaud <nthiebaud@gmail.com>2013-07-05 16:25:03 -0500
committerNorbert Thiebaud <nthiebaud@gmail.com>2013-07-07 20:00:16 +0000
commit009851223b5ced4ed2662af2e2ae81c0f9200e45 (patch)
treea8ab339589ea23b98513d394eabc4f135e69ccae /editeng
parent35b42a9d1282a92dbc9a7fbc51d279812070688c (diff)
module svl: all String and some bool and related clean-up
Change-Id: I36eb559fa58dbe75384b7119c788af0048813aed Reviewed-on: https://gerrit.libreoffice.org/4733 Reviewed-by: Norbert Thiebaud <nthiebaud@gmail.com> Tested-by: Norbert Thiebaud <nthiebaud@gmail.com>
Diffstat (limited to 'editeng')
-rw-r--r--editeng/source/editeng/editundo.cxx28
-rw-r--r--editeng/source/editeng/editundo.hxx2
-rw-r--r--editeng/source/editeng/impedit4.cxx4
3 files changed, 17 insertions, 17 deletions
diff --git a/editeng/source/editeng/editundo.cxx b/editeng/source/editeng/editundo.cxx
index dfc8df189530..1ce72741152b 100644
--- a/editeng/source/editeng/editundo.cxx
+++ b/editeng/source/editeng/editundo.cxx
@@ -48,10 +48,10 @@ void EditUndoManager::SetEditEngine(EditEngine* pNew)
mpEditEngine = pNew;
}
-sal_Bool EditUndoManager::Undo()
+bool EditUndoManager::Undo()
{
if ( !mpEditEngine || GetUndoActionCount() == 0 )
- return sal_False;
+ return false;
DBG_ASSERT( mpEditEngine->GetActiveView(), "Active View?" );
@@ -62,14 +62,14 @@ sal_Bool EditUndoManager::Undo()
else
{
OSL_FAIL("Undo in engine is not possible without a View! ");
- return sal_False;
+ return false;
}
}
mpEditEngine->GetActiveView()->GetImpEditView()->DrawSelection(); // Remove the old selection
mpEditEngine->SetUndoMode( sal_True );
- sal_Bool bDone = SfxUndoManager::Undo();
+ bool bDone = SfxUndoManager::Undo();
mpEditEngine->SetUndoMode( sal_False );
EditSelection aNewSel( mpEditEngine->GetActiveView()->GetImpEditView()->GetEditSelection() );
@@ -83,10 +83,10 @@ sal_Bool EditUndoManager::Undo()
return bDone;
}
-sal_Bool EditUndoManager::Redo()
+bool EditUndoManager::Redo()
{
if ( !mpEditEngine || GetRedoActionCount() == 0 )
- return sal_False;
+ return false;
DBG_ASSERT( mpEditEngine->GetActiveView(), "Active View?" );
@@ -97,14 +97,14 @@ sal_Bool EditUndoManager::Redo()
else
{
OSL_FAIL( "Redo in Engine ohne View nicht moeglich!" );
- return sal_False;
+ return false;
}
}
mpEditEngine->GetActiveView()->GetImpEditView()->DrawSelection(); // Remove the old selection
mpEditEngine->SetUndoMode( sal_True );
- sal_Bool bDone = SfxUndoManager::Redo();
+ bool bDone = SfxUndoManager::Redo();
mpEditEngine->SetUndoMode( sal_False );
EditSelection aNewSel( mpEditEngine->GetActiveView()->GetImpEditView()->GetEditSelection() );
@@ -138,9 +138,9 @@ sal_uInt16 EditUndo::GetId() const
return nId;
}
-sal_Bool EditUndo::CanRepeat(SfxRepeatTarget&) const
+bool EditUndo::CanRepeat(SfxRepeatTarget&) const
{
- return sal_False;
+ return false;
}
OUString EditUndo::GetComment() const
@@ -320,21 +320,21 @@ void EditUndoInsertChars::Redo()
GetEditEngine()->GetActiveView()->GetImpEditView()->SetEditSelection( EditSelection( aPaM, aNewPaM ) );
}
-sal_Bool EditUndoInsertChars::Merge( SfxUndoAction* pNextAction )
+bool EditUndoInsertChars::Merge( SfxUndoAction* pNextAction )
{
EditUndoInsertChars* pNext = dynamic_cast<EditUndoInsertChars*>(pNextAction);
if (!pNext)
return false;
if ( aEPaM.nPara != pNext->aEPaM.nPara )
- return sal_False;
+ return false;
if ( ( aEPaM.nIndex + aText.Len() ) == pNext->aEPaM.nIndex )
{
aText += pNext->aText;
- return sal_True;
+ return true;
}
- return sal_False;
+ return false;
}
EditUndoRemoveChars::EditUndoRemoveChars(
diff --git a/editeng/source/editeng/editundo.hxx b/editeng/source/editeng/editundo.hxx
index 834a9c4b4554..7f7d4e3114f7 100644
--- a/editeng/source/editeng/editundo.hxx
+++ b/editeng/source/editeng/editundo.hxx
@@ -110,7 +110,7 @@ public:
virtual void Undo();
virtual void Redo();
- virtual sal_Bool Merge( SfxUndoAction *pNextAction );
+ virtual bool Merge( SfxUndoAction *pNextAction );
};
// -----------------------------------------------------------------------
diff --git a/editeng/source/editeng/impedit4.cxx b/editeng/source/editeng/impedit4.cxx
index dedd6b2c1497..0252b8d78e3e 100644
--- a/editeng/source/editeng/impedit4.cxx
+++ b/editeng/source/editeng/impedit4.cxx
@@ -492,7 +492,7 @@ sal_uInt32 ImpEditEngine::WriteRTF( SvStream& rOutput, EditSelection aSel )
}
// Parent ... (only if necessary)
- if ( pStyle->GetParent().Len() && ( pStyle->GetParent() != pStyle->GetName() ) )
+ if ( !pStyle->GetParent().isEmpty() && ( pStyle->GetParent() != pStyle->GetName() ) )
{
SfxStyleSheet* pParent = (SfxStyleSheet*)GetStyleSheetPool()->Find( pStyle->GetParent(), pStyle->GetFamily() );
DBG_ASSERT( pParent, "Parent not found!" );
@@ -503,7 +503,7 @@ sal_uInt32 ImpEditEngine::WriteRTF( SvStream& rOutput, EditSelection aSel )
// Next Style ... (more)
SfxStyleSheet* pNext = pStyle;
- if ( pStyle->GetFollow().Len() && ( pStyle->GetFollow() != pStyle->GetName() ) )
+ if ( !pStyle->GetFollow().isEmpty() && ( pStyle->GetFollow() != pStyle->GetName() ) )
pNext = (SfxStyleSheet*)GetStyleSheetPool()->Find( pStyle->GetFollow(), pStyle->GetFamily() );
DBG_ASSERT( pNext, "Next ot found!" );