diff options
author | Zdibák Zoltán <zdibakzoltan@gmail.com> | 2018-10-30 19:27:57 +0100 |
---|---|---|
committer | Markus Mohrhard <markus.mohrhard@googlemail.com> | 2018-10-31 02:17:39 +0100 |
commit | 5066325953943814fa66f6d6a835d848903b742d (patch) | |
tree | 56fe9b470b8a0d4152ead63b23d94d3203fe4538 /sc | |
parent | 949e16267ba5338f58bae353806c36f6eec55fcc (diff) |
cppCheck RedundantAssignment variable bRecording
Change-Id: I2fb7c2ce3581bf6347a5b6ee85d7e603e2b58800
Reviewed-on: https://gerrit.libreoffice.org/62643
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/core/data/postit.cxx | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/sc/source/core/data/postit.cxx b/sc/source/core/data/postit.cxx index 8e961ce28222..acc77eb882f6 100644 --- a/sc/source/core/data/postit.cxx +++ b/sc/source/core/data/postit.cxx @@ -466,11 +466,10 @@ void removeFromDrawPageAndFree( const std::shared_ptr< SdrCaptionObj >& pCaption if (pDrawPage) { pDrawPage->RecalcObjOrdNums(); - bool bRecording = false; ScDrawLayer* pDrawLayer(dynamic_cast< ScDrawLayer* >(&pCaption->getSdrModelFromSdrObject())); SAL_WARN_IF( !pDrawLayer, "sc.core", "ScCaptionPtr::removeFromDrawPageAndFree - object without drawing layer"); // create drawing undo action (before removing the object to have valid draw page in undo action) - bRecording = (pDrawLayer && pDrawLayer->IsRecording()); + bool bRecording = (pDrawLayer && pDrawLayer->IsRecording()); if (bRecording) pDrawLayer->AddCalcUndo( o3tl::make_unique<ScUndoDelSdrCaptionObj>( pCaption )); // remove the object from the drawing page, delete if undo is disabled |