diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2014-01-28 20:00:11 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2014-01-28 20:26:22 +0100 |
commit | 2fd074b23fad94abcfafa52193c29985789cdb8a (patch) | |
tree | 3ed0b74fef904cfcb1ee364b009bb70601165a52 /starmath | |
parent | 48fc43550abb5fa62abef5b3fc977e24d0ab56f0 (diff) |
bool improvements
Change-Id: I3f0749caeae8a772e6fb668eefc9d8784e7f22b5
Diffstat (limited to 'starmath')
-rw-r--r-- | starmath/source/cursor.cxx | 20 | ||||
-rw-r--r-- | starmath/source/dialog.cxx | 4 | ||||
-rw-r--r-- | starmath/source/mathtype.cxx | 2 | ||||
-rw-r--r-- | starmath/source/node.cxx | 4 | ||||
-rw-r--r-- | starmath/source/smdetect.cxx | 4 | ||||
-rw-r--r-- | starmath/source/unomodel.cxx | 2 | ||||
-rw-r--r-- | starmath/source/view.cxx | 2 | ||||
-rw-r--r-- | starmath/source/visitors.cxx | 2 |
8 files changed, 20 insertions, 20 deletions
diff --git a/starmath/source/cursor.cxx b/starmath/source/cursor.cxx index e00ca8109d27..9288879bbe3b 100644 --- a/starmath/source/cursor.cxx +++ b/starmath/source/cursor.cxx @@ -491,9 +491,9 @@ void SmCursor::InsertSubSup(SmSubSup eSubSup) { if(HasSelection()) { SmNode *pSNode = FindSelectedNode(pTree); OSL_ENSURE(pSNode != NULL, "There must be a selected node when HasSelection is true!"); - pLine = FindTopMostNodeInLine(pSNode, sal_True); + pLine = FindTopMostNodeInLine(pSNode, true); } else - pLine = FindTopMostNodeInLine(position->CaretPos.pSelectedNode, sal_False); + pLine = FindTopMostNodeInLine(position->CaretPos.pSelectedNode, false); //Find Parent and offset in parent SmStructureNode *pLineParent = pLine->GetParent(); @@ -594,7 +594,7 @@ bool SmCursor::InsertLimit(SmSubSup eSubSup, bool bMoveCaret) { pSubject = (SmOperNode*)position->CaretPos.pSelectedNode; else { //If not, check if parent of the current line is a SmOperNode - SmNode *pLineNode = FindTopMostNodeInLine(position->CaretPos.pSelectedNode, sal_False); + SmNode *pLineNode = FindTopMostNodeInLine(position->CaretPos.pSelectedNode, false); if(pLineNode->GetParent() && pLineNode->GetParent()->GetType() == NOPER) pSubject = (SmOperNode*)pLineNode->GetParent(); } @@ -662,9 +662,9 @@ void SmCursor::InsertBrackets(SmBracketType eBracketType) { if(HasSelection()) { SmNode *pSNode = FindSelectedNode(pTree); OSL_ENSURE(pSNode != NULL, "There must be a selected node if HasSelection()"); - pLine = FindTopMostNodeInLine(pSNode, sal_True); + pLine = FindTopMostNodeInLine(pSNode, true); } else - pLine = FindTopMostNodeInLine(position->CaretPos.pSelectedNode, sal_False); + pLine = FindTopMostNodeInLine(position->CaretPos.pSelectedNode, false); //Find parent and offset in parent SmStructureNode *pLineParent = pLine->GetParent(); @@ -797,9 +797,9 @@ bool SmCursor::InsertRow() { if(HasSelection()) { SmNode *pSNode = FindSelectedNode(pTree); OSL_ENSURE(pSNode != NULL, "There must be a selected node if HasSelection()"); - pLine = FindTopMostNodeInLine(pSNode, sal_True); + pLine = FindTopMostNodeInLine(pSNode, true); } else - pLine = FindTopMostNodeInLine(position->CaretPos.pSelectedNode, sal_False); + pLine = FindTopMostNodeInLine(position->CaretPos.pSelectedNode, false); //Find parent and offset in parent SmStructureNode *pLineParent = pLine->GetParent(); @@ -917,9 +917,9 @@ void SmCursor::InsertFraction() { if(HasSelection()) { SmNode *pSNode = FindSelectedNode(pTree); OSL_ENSURE(pSNode != NULL, "There must be a selected node when HasSelection is true!"); - pLine = FindTopMostNodeInLine(pSNode, sal_True); + pLine = FindTopMostNodeInLine(pSNode, true); } else - pLine = FindTopMostNodeInLine(position->CaretPos.pSelectedNode, sal_False); + pLine = FindTopMostNodeInLine(position->CaretPos.pSelectedNode, false); //Find Parent and offset in parent SmStructureNode *pLineParent = pLine->GetParent(); @@ -1422,7 +1422,7 @@ void SmCursor::BeginEdit(){ void SmCursor::EndEdit(){ if(--nEditSections > 0) return; - pDocShell->SetFormulaArranged(sal_False); + pDocShell->SetFormulaArranged(false); //Okay, I don't know what this does... :) //It's used in SmDocShell::SetText and with places where everything is modified. //I think it does some magic, with sfx, but everything is totally undocumented so diff --git a/starmath/source/dialog.cxx b/starmath/source/dialog.cxx index 3c381c5fa828..7cab5ff2fb61 100644 --- a/starmath/source/dialog.cxx +++ b/starmath/source/dialog.cxx @@ -2332,7 +2332,7 @@ bool SmSymDefineDialog::SelectFont(const OUString &rFontName, bool bApplyFont) bRet = true; aSymbolDisplay.SetSymbol( aCharsetDisplay.GetSelectCharacter(), aCharsetDisplay.GetFont() ); } - bRet = sal_True; + bRet = true; } else aFonts.SetNoSelection(); @@ -2362,7 +2362,7 @@ bool SmSymDefineDialog::SelectStyle(const OUString &rStyleName, bool bApplyFont) bRet = true; aSymbolDisplay.SetSymbol( aCharsetDisplay.GetSelectCharacter(), aCharsetDisplay.GetFont() ); } - bRet = sal_True; + bRet = true; } else aStyles.SetText(OUString()); diff --git a/starmath/source/mathtype.cxx b/starmath/source/mathtype.cxx index 94e0de1ad8c2..2adc2aaa8ebf 100644 --- a/starmath/source/mathtype.cxx +++ b/starmath/source/mathtype.cxx @@ -1740,7 +1740,7 @@ int MathType::HandleRecords(int nLevel,sal_uInt8 nSelector, *pS >> aFont.nStyle; aUserStyles.insert(aFont); std::vector<sal_Char> aSeq; - while(1) + while(true) { sal_Char nChar8(0); *pS >> nChar8; diff --git a/starmath/source/node.cxx b/starmath/source/node.cxx index 334e52674755..6ffd0fb2531f 100644 --- a/starmath/source/node.cxx +++ b/starmath/source/node.cxx @@ -862,7 +862,7 @@ void SmTableNode::Arrange(const OutputDevice &rDev, const SmFormat &rFormat) nFormulaBaseline = GetBaseline(); else { - SmTmpDevice aTmpDev ((OutputDevice &) rDev, sal_True); + SmTmpDevice aTmpDev ((OutputDevice &) rDev, true); aTmpDev.SetFont(GetFont()); SmRect aRect = (SmRect(aTmpDev, &rFormat, OUString("a"), @@ -2098,7 +2098,7 @@ void SmFontNode::CreateTextFromNode(OUString &rText) rText += ::rtl::math::doubleToUString( static_cast<double>(aFontSize), rtl_math_StringFormat_Automatic, - rtl_math_DecimalPlaces_Max, '.', sal_True); + rtl_math_DecimalPlaces_Max, '.', true); rText += " "; } break; diff --git a/starmath/source/smdetect.cxx b/starmath/source/smdetect.cxx index ca9453ad09c7..cd6a2c760475 100644 --- a/starmath/source/smdetect.cxx +++ b/starmath/source/smdetect.cxx @@ -157,7 +157,7 @@ OUString SAL_CALL SmFilterDetect::detect( Sequence< PropertyValue >& lDescriptor SfxApplication* pApp = SFX_APP(); SfxAllItemSet *pSet = new SfxAllItemSet( pApp->GetPool() ); TransformParameters( SID_OPENDOC, lDescriptor, *pSet ); - SFX_ITEMSET_ARG( pSet, pItem, SfxBoolItem, SID_DOC_READONLY, sal_False ); + SFX_ITEMSET_ARG( pSet, pItem, SfxBoolItem, SID_DOC_READONLY, false ); bWasReadOnly = pItem && pItem->GetValue(); @@ -298,7 +298,7 @@ OUString SAL_CALL SmFilterDetect::detect( Sequence< PropertyValue >& lDescriptor aTypeName = OUString(); if (pStrm && !pStrm->GetError()) { - SotStorageRef aStorage = new SotStorage ( pStrm, sal_False ); + SotStorageRef aStorage = new SotStorage ( pStrm, false ); if ( !aStorage->GetError() ) { if (aStorage->IsStream("Equation Native")) diff --git a/starmath/source/unomodel.cxx b/starmath/source/unomodel.cxx index 1c3811f3d4dc..994e9ebb5d42 100644 --- a/starmath/source/unomodel.cxx +++ b/starmath/source/unomodel.cxx @@ -690,7 +690,7 @@ void SmModel::_setPropertyValues(const PropertyMapEntry** ppEntries, const Any* SmSym aSymbol ( pDescriptor->sName, aFont, static_cast < sal_Unicode > (pDescriptor->nCharacter), pDescriptor->sSymbolSet ); aSymbol.SetExportName ( pDescriptor->sExportName ); - aSymbol.SetDocSymbol( sal_True ); + aSymbol.SetDocSymbol( true ); rManager.AddOrReplaceSymbol ( aSymbol ); } } diff --git a/starmath/source/view.cxx b/starmath/source/view.cxx index 4c8e22c703dc..627a443b4f9c 100644 --- a/starmath/source/view.cxx +++ b/starmath/source/view.cxx @@ -1730,7 +1730,7 @@ void SmViewShell::Execute(SfxRequest& rReq) pImpl->pRequest = new SfxRequest( rReq ); delete pImpl->pDocInserter; pImpl->pDocInserter = new ::sfx2::DocumentInserter( - GetDoc()->GetFactory().GetFactoryName(), 0 ); + GetDoc()->GetFactory().GetFactoryName(), false ); pImpl->pDocInserter->StartExecuteModal( LINK( this, SmViewShell, DialogClosedHdl ) ); break; } diff --git a/starmath/source/visitors.cxx b/starmath/source/visitors.cxx index 93ea409dde1f..922d6c333e46 100644 --- a/starmath/source/visitors.cxx +++ b/starmath/source/visitors.cxx @@ -2291,7 +2291,7 @@ void SmNodeToTextVisitor::Visit( SmFontNode* pNode ) Append( ::rtl::math::doubleToUString( static_cast<double>( pNode->GetSizeParameter( ) ), rtl_math_StringFormat_Automatic, - rtl_math_DecimalPlaces_Max, '.', sal_True ) ); + rtl_math_DecimalPlaces_Max, '.', true ) ); Append( " " ); } break; |