summaryrefslogtreecommitdiff
path: root/sc/source
diff options
context:
space:
mode:
Diffstat (limited to 'sc/source')
-rw-r--r--sc/source/core/data/fillinfo.cxx2
-rw-r--r--sc/source/core/data/formulacell.cxx4
-rw-r--r--sc/source/filter/excel/excel.cxx5
-rw-r--r--sc/source/ui/drawfunc/drtxtob.cxx2
-rw-r--r--sc/source/ui/drawfunc/fudraw.cxx2
-rw-r--r--sc/source/ui/view/formatsh.cxx4
6 files changed, 8 insertions, 11 deletions
diff --git a/sc/source/core/data/fillinfo.cxx b/sc/source/core/data/fillinfo.cxx
index 3d4c2f3b279c..bb760bda8c57 100644
--- a/sc/source/core/data/fillinfo.cxx
+++ b/sc/source/core/data/fillinfo.cxx
@@ -584,7 +584,7 @@ void ScDocument::FillInfo(
++nArrRow;
}
- else if (bRowHidden && nLastHiddenRow >= 0)
+ else if (nLastHiddenRow >= 0)
{
nCurRow = nLastHiddenRow;
if (nCurRow > nThisRow)
diff --git a/sc/source/core/data/formulacell.cxx b/sc/source/core/data/formulacell.cxx
index aadb8e11b4d0..bdc832c55d39 100644
--- a/sc/source/core/data/formulacell.cxx
+++ b/sc/source/core/data/formulacell.cxx
@@ -3219,7 +3219,7 @@ bool ScFormulaCell::UpdateReferenceOnShift(
if (!bHasRefs)
{
bHasColRowNames = (formula::FormulaTokenArrayPlainIterator(*pCode).GetNextColRowName() != nullptr);
- bHasRefs = bHasRefs || bHasColRowNames;
+ bHasRefs = bHasColRowNames;
}
bool bOnRefMove = pCode->IsRecalcModeOnRefMove();
@@ -3347,7 +3347,7 @@ bool ScFormulaCell::UpdateReferenceOnMove(
if (!bHasRefs)
{
bHasColRowNames = (formula::FormulaTokenArrayPlainIterator(*pCode).GetNextColRowName() != nullptr);
- bHasRefs = bHasRefs || bHasColRowNames;
+ bHasRefs = bHasColRowNames;
}
bool bOnRefMove = pCode->IsRecalcModeOnRefMove();
diff --git a/sc/source/filter/excel/excel.cxx b/sc/source/filter/excel/excel.cxx
index 221f274f3038..c45bca6e26a8 100644
--- a/sc/source/filter/excel/excel.cxx
+++ b/sc/source/filter/excel/excel.cxx
@@ -217,10 +217,7 @@ ErrCode ScFormatFilterPluginImpl::ScExportExcel5( SfxMedium& rMedium, ScDocument
OSL_ENSURE( pMedStrm, "::ScExportExcel5 - medium without output stream" );
if( !pMedStrm ) return SCERR_IMPORT_OPEN; // should not happen
- ErrCode eRet = SCERR_IMPORT_UNKNOWN_BIFF;
- if( eFormat == ExpBiff5 || eFormat == ExpBiff8 )
- eRet = lcl_ExportExcelBiff( rMedium, pDocument, pMedStrm, eFormat == ExpBiff8, eNach );
-
+ ErrCode eRet = lcl_ExportExcelBiff(rMedium, pDocument, pMedStrm, eFormat == ExpBiff8, eNach);
return eRet;
}
diff --git a/sc/source/ui/drawfunc/drtxtob.cxx b/sc/source/ui/drawfunc/drtxtob.cxx
index 242c3fc57a75..d688bf7977d8 100644
--- a/sc/source/ui/drawfunc/drtxtob.cxx
+++ b/sc/source/ui/drawfunc/drtxtob.cxx
@@ -265,7 +265,7 @@ void ScDrawTextObjectBar::Execute( SfxRequest &rReq )
SvxLinkInsertMode eMode = pHyper->GetInsertMode();
bool bDone = false;
- if ( pOutView && ( eMode == HLINK_DEFAULT || eMode == HLINK_FIELD ) )
+ if (eMode == HLINK_DEFAULT || eMode == HLINK_FIELD)
{
const SvxFieldItem* pFieldItem = pOutView->GetFieldAtSelection();
if (pFieldItem)
diff --git a/sc/source/ui/drawfunc/fudraw.cxx b/sc/source/ui/drawfunc/fudraw.cxx
index 65a3f0b843da..d0cd38557ec6 100644
--- a/sc/source/ui/drawfunc/fudraw.cxx
+++ b/sc/source/ui/drawfunc/fudraw.cxx
@@ -487,7 +487,7 @@ bool FuDraw::KeyInput(const KeyEvent& rKEvt)
else
{
// move handle with index nHandleIndex
- if(pHdl && (nX || nY))
+ if (nX || nY)
{
// now move the Handle (nX, nY)
Point aStartPoint(pHdl->GetPos());
diff --git a/sc/source/ui/view/formatsh.cxx b/sc/source/ui/view/formatsh.cxx
index ba3896ecab2e..cc4fa6fa9ed9 100644
--- a/sc/source/ui/view/formatsh.cxx
+++ b/sc/source/ui/view/formatsh.cxx
@@ -393,7 +393,7 @@ void ScFormatShell::ExecuteStyle( SfxRequest& rReq )
pStyleSheet = &(pStylePool->Make( aStyleName, eFamily,
SfxStyleSearchBits::UserDefined ) );
- if ( pStyleSheet && pStyleSheet->HasParentSupport() )
+ if (pStyleSheet->HasParentSupport())
pStyleSheet->SetParent(aRefName);
}
break;
@@ -2180,7 +2180,7 @@ void ScFormatShell::GetAttrState( SfxItemSet& rSet )
rSet.Put( SvxColorItem(aCol, SID_FRAME_LINECOLOR ) );
rSet.InvalidateItem(SID_FRAME_LINECOLOR);
}
- else if( !bCol && !bColDisable) // if no line available
+ else if (!bCol) // if no line available
{
aCol = COL_AUTO;
rSet.Put( SvxColorItem(aCol, SID_FRAME_LINECOLOR ) );