summaryrefslogtreecommitdiff
path: root/sc/source/ui
diff options
context:
space:
mode:
authorJochen Nitschke <j.nitschke+logerrit@ok.de>2018-04-16 21:02:14 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-04-17 08:16:33 +0200
commit821371fb453f880240efa71ac3f556831be161d9 (patch)
tree18d952a838f2ff96168cf6059e897b1cb216779b /sc/source/ui
parent0f166ef5240ee155bf2544e6bc3c985b1e3bf646 (diff)
cppcheck: identicalInnerCondition in sc
and remove a related known condition dpcache.cxx Change-Id: I6069849c33ea03eff61a55eb790ce6a8aad3d915 Reviewed-on: https://gerrit.libreoffice.org/53005 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sc/source/ui')
-rw-r--r--sc/source/ui/app/inputhdl.cxx5
-rw-r--r--sc/source/ui/view/printfun.cxx6
2 files changed, 3 insertions, 8 deletions
diff --git a/sc/source/ui/app/inputhdl.cxx b/sc/source/ui/app/inputhdl.cxx
index 5ac088044ac6..b609e6e22e8e 100644
--- a/sc/source/ui/app/inputhdl.cxx
+++ b/sc/source/ui/app/inputhdl.cxx
@@ -3446,10 +3446,7 @@ bool ScInputHandler::KeyInput( const KeyEvent& rKEvt, bool bStartEdit /* = false
}
if( bUsed && bFormulaMode && nCode == KEY_BACKSPACE )
{
- if (bFormulaMode)
- UseFormulaData();
- else
- UseColData();
+ UseFormulaData();
}
}
diff --git a/sc/source/ui/view/printfun.cxx b/sc/source/ui/view/printfun.cxx
index c1f11cdc8a56..082572aa52ad 100644
--- a/sc/source/ui/view/printfun.cxx
+++ b/sc/source/ui/view/printfun.cxx
@@ -1374,8 +1374,7 @@ void ScPrintFunc::DrawBorder( long nScrX, long nScrY, long nScrW, long nScrH,
{
ScDocumentUniquePtr pBorderDoc(new ScDocument( SCDOCMODE_UNDO ));
pBorderDoc->InitUndo( pDoc, 0,0, true,true );
- if (pBorderData)
- pBorderDoc->ApplyAttr( 0,0,0, *pBorderData );
+ pBorderDoc->ApplyAttr( 0,0,0, *pBorderData );
ScTableInfo aTabInfo;
pBorderDoc->FillInfo( aTabInfo, 0,0, 0,0, 0,
@@ -1390,8 +1389,7 @@ void ScPrintFunc::DrawBorder( long nScrX, long nScrY, long nScrW, long nScrH,
nScrX+nLeft, nScrY+nTop, 0,0, 0,0, nScaleX, nScaleY );
aOutputData.SetUseStyleColor( bUseStyleColor );
- if (pBorderData)
- aOutputData.DrawFrame(*pDev);
+ aOutputData.DrawFrame(*pDev);
}
}