diff options
author | Caolán McNamara <caolanm@redhat.com> | 2012-04-24 15:46:11 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2012-04-24 16:07:45 +0100 |
commit | 070dfe4840cfb5854be6aba99dd65b9015ed0a90 (patch) | |
tree | df628ff2910d179ce65c5ec20694da76c4ba4f37 /editeng | |
parent | 9886c392383007ff86c849f61c641e4603f13259 (diff) |
WaE: mixing comparison of bool and sal_Bool
Diffstat (limited to 'editeng')
-rw-r--r-- | editeng/inc/editeng/editeng.hxx | 4 | ||||
-rw-r--r-- | editeng/inc/editeng/editobj.hxx | 4 | ||||
-rw-r--r-- | editeng/source/editeng/editattr.hxx | 4 | ||||
-rw-r--r-- | editeng/source/editeng/editeng.cxx | 4 | ||||
-rw-r--r-- | editeng/source/editeng/editobj.cxx | 8 | ||||
-rw-r--r-- | editeng/source/editeng/editobj2.hxx | 17 | ||||
-rw-r--r-- | editeng/source/editeng/impedit.hxx | 6 | ||||
-rw-r--r-- | editeng/source/editeng/impedit3.cxx | 6 |
8 files changed, 25 insertions, 28 deletions
diff --git a/editeng/inc/editeng/editeng.hxx b/editeng/inc/editeng/editeng.hxx index f2208a9e5056..8b23f00a5834 100644 --- a/editeng/inc/editeng/editeng.hxx +++ b/editeng/inc/editeng/editeng.hxx @@ -223,8 +223,8 @@ public: void SetPaperSize( const Size& rSize ); const Size& GetPaperSize() const; - void SetVertical( sal_Bool bVertical ); - sal_Bool IsVertical() const; + void SetVertical( bool bVertical ); + bool IsVertical() const; void SetFixedCellHeight( sal_Bool bUseFixedCellHeight ); diff --git a/editeng/inc/editeng/editobj.hxx b/editeng/inc/editeng/editobj.hxx index b495efbfe631..c57a70b0e3e0 100644 --- a/editeng/inc/editeng/editobj.hxx +++ b/editeng/inc/editeng/editobj.hxx @@ -72,8 +72,8 @@ public: virtual sal_uLong GetObjectSettings() const; virtual void SetObjectSettings( sal_uLong n ); - virtual sal_Bool IsVertical() const; - virtual void SetVertical( sal_Bool bVertical ); + virtual bool IsVertical() const; + virtual void SetVertical( bool bVertical ); virtual sal_uInt16 GetScriptType() const; diff --git a/editeng/source/editeng/editattr.hxx b/editeng/source/editeng/editattr.hxx index 1a371d038927..d2cdb42aec35 100644 --- a/editeng/source/editeng/editattr.hxx +++ b/editeng/source/editeng/editattr.hxx @@ -107,10 +107,10 @@ public: { return ( ( nStart <= nIndex ) && ( nEnd >= nIndex ) ); } sal_Bool IsInside( sal_uInt16 nIndex ) const { return ( ( nStart < nIndex ) && ( nEnd > nIndex ) ); } - sal_Bool IsEmpty() const + bool IsEmpty() const { return nStart == nEnd; } - sal_Bool IsFeature() const { return bFeature; } + bool IsFeature() const { return bFeature; } void SetFeature( sal_Bool b) { bFeature = b; } sal_Bool IsEdge() const { return bEdge; } diff --git a/editeng/source/editeng/editeng.cxx b/editeng/source/editeng/editeng.cxx index 4c75f6f8f325..dd4cfb0510da 100644 --- a/editeng/source/editeng/editeng.cxx +++ b/editeng/source/editeng/editeng.cxx @@ -482,13 +482,13 @@ const Size& EditEngine::GetPaperSize() const return pImpEditEngine->GetPaperSize(); } -void EditEngine::SetVertical( sal_Bool bVertical ) +void EditEngine::SetVertical( bool bVertical ) { DBG_CHKTHIS( EditEngine, 0 ); pImpEditEngine->SetVertical( bVertical ); } -sal_Bool EditEngine::IsVertical() const +bool EditEngine::IsVertical() const { DBG_CHKTHIS( EditEngine, 0 ); return pImpEditEngine->IsVertical(); diff --git a/editeng/source/editeng/editobj.cxx b/editeng/source/editeng/editobj.cxx index 67099ba9ca6f..a2aaa17855cf 100644 --- a/editeng/source/editeng/editobj.cxx +++ b/editeng/source/editeng/editobj.cxx @@ -343,13 +343,13 @@ void EditTextObject::SetObjectSettings( sal_uLong ) OSL_FAIL( "Virtual method direct from EditTextObject!" ); } -sal_Bool EditTextObject::IsVertical() const +bool EditTextObject::IsVertical() const { OSL_FAIL( "Virtual method direct from EditTextObject!" ); return false; } -void EditTextObject::SetVertical( sal_Bool bVertical ) +void EditTextObject::SetVertical( bool bVertical ) { OSL_FAIL( "Virtual method direct from EditTextObject!" ); ((BinTextObject*)this)->SetVertical( bVertical ); @@ -616,12 +616,12 @@ void BinTextObject::SetObjectSettings( sal_uLong n ) nObjSettings = n; } -sal_Bool BinTextObject::IsVertical() const +bool BinTextObject::IsVertical() const { return bVertical; } -void BinTextObject::SetVertical( sal_Bool b ) +void BinTextObject::SetVertical( bool b ) { if ( b != bVertical ) { diff --git a/editeng/source/editeng/editobj2.hxx b/editeng/source/editeng/editobj2.hxx index cd0eb69e4b2f..ea633faac59c 100644 --- a/editeng/source/editeng/editobj2.hxx +++ b/editeng/source/editeng/editobj2.hxx @@ -65,7 +65,11 @@ public: sal_uInt16 GetLen() const { return nEnd-nStart; } - inline sal_Bool IsFeature(); + bool IsFeature() + { + sal_uInt16 nWhich = pItem->Which(); + return ((nWhich >= EE_FEATURE_START) && (nWhich <= EE_FEATURE_END)); + } inline bool operator==( const XEditAttribute& rCompare ); }; @@ -79,13 +83,6 @@ inline bool XEditAttribute::operator==( const XEditAttribute& rCompare ) (*pItem == *rCompare.pItem)); } -inline sal_Bool XEditAttribute::IsFeature() -{ - sal_uInt16 nWhich = pItem->Which(); - return ( ( nWhich >= EE_FEATURE_START ) && - ( nWhich <= EE_FEATURE_END ) ); -} - typedef XEditAttribute* XEditAttributePtr; SV_DECL_PTRARR( XEditAttributeListImpl, XEditAttributePtr, 0 ) @@ -216,8 +213,8 @@ public: sal_uLong GetObjectSettings() const; void SetObjectSettings( sal_uLong n ); - sal_Bool IsVertical() const; - void SetVertical( sal_Bool b ); + bool IsVertical() const; + void SetVertical( bool b ); sal_uInt16 GetScriptType() const; void SetScriptType( sal_uInt16 nType ); diff --git a/editeng/source/editeng/impedit.hxx b/editeng/source/editeng/impedit.hxx index a662dab59683..9aefbe3024fb 100644 --- a/editeng/source/editeng/impedit.hxx +++ b/editeng/source/editeng/impedit.hxx @@ -573,7 +573,7 @@ private: EditPaM SplitContent( sal_uInt16 nNode, sal_uInt16 nSepPos ); EditPaM ConnectContents( sal_uInt16 nLeftNode, sal_Bool bBackward ); - void ShowParagraph( sal_uInt16 nParagraph, sal_Bool bShow ); + void ShowParagraph( sal_uInt16 nParagraph, bool bShow ); EditPaM PageUp( const EditPaM& rPaM, EditView* pView); EditPaM PageDown( const EditPaM& rPaM, EditView* pView); @@ -689,8 +689,8 @@ public: inline EditUndoManager& GetUndoManager(); - void SetUpdateMode( sal_Bool bUp, EditView* pCurView = 0, sal_Bool bForceUpdate = sal_False ); - bool GetUpdateMode() const { return bUpdate; } + void SetUpdateMode( bool bUp, EditView* pCurView = 0, sal_Bool bForceUpdate = sal_False ); + bool GetUpdateMode() const { return bUpdate; } ViewsType& GetEditViews() { return aEditViews; } const ViewsType& GetEditViews() const { return aEditViews; } diff --git a/editeng/source/editeng/impedit3.cxx b/editeng/source/editeng/impedit3.cxx index a08a6c7cbf6c..e19b88a19d94 100644 --- a/editeng/source/editeng/impedit3.cxx +++ b/editeng/source/editeng/impedit3.cxx @@ -3759,9 +3759,9 @@ EditPaM ImpEditEngine::ConnectContents( sal_uInt16 nLeftNode, sal_Bool bBackward return ImpConnectParagraphs( pLeftNode, pRightNode, bBackward ); } -void ImpEditEngine::SetUpdateMode( sal_Bool bUp, EditView* pCurView, sal_Bool bForceUpdate ) +void ImpEditEngine::SetUpdateMode( bool bUp, EditView* pCurView, sal_Bool bForceUpdate ) { - sal_Bool bChanged = ( GetUpdateMode() != bUp ); + bool bChanged = ( GetUpdateMode() != bUp ); // When switching from sal_True to sal_False, all selections were visible, // => paint over @@ -3774,7 +3774,7 @@ void ImpEditEngine::SetUpdateMode( sal_Bool bUp, EditView* pCurView, sal_Bool bF FormatAndUpdate( pCurView ); } -void ImpEditEngine::ShowParagraph( sal_uInt16 nParagraph, sal_Bool bShow ) +void ImpEditEngine::ShowParagraph( sal_uInt16 nParagraph, bool bShow ) { ParaPortion* pPPortion = GetParaPortions().SafeGetObject( nParagraph ); DBG_ASSERT( pPPortion, "ShowParagraph: Paragraph does not exist! "); |