summaryrefslogtreecommitdiff
path: root/xmloff/source/draw
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-11-01 13:14:09 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-11-08 07:37:40 +0100
commit7f48fa8152bd3320af7276d811b752c5a762dcce (patch)
treea95f2aec74a17050e825eb78833ee8f0274cb728 /xmloff/source/draw
parentf10b7e820844d94b4dbec3dcaf24392275940914 (diff)
loplugin:collapseif in tools..xmloff
Change-Id: Iea1227a9f13a0a618d9bb6b0bbedaa5ce8d1a4f5 Reviewed-on: https://gerrit.libreoffice.org/62732 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'xmloff/source/draw')
-rw-r--r--xmloff/source/draw/animationexport.cxx9
-rw-r--r--xmloff/source/draw/ximpshap.cxx17
2 files changed, 10 insertions, 16 deletions
diff --git a/xmloff/source/draw/animationexport.cxx b/xmloff/source/draw/animationexport.cxx
index 72938424411a..de66a89dcd8d 100644
--- a/xmloff/source/draw/animationexport.cxx
+++ b/xmloff/source/draw/animationexport.cxx
@@ -881,13 +881,10 @@ void AnimationsExporterImpl::exportNode( const Reference< XAnimationNode >& xNod
}
aTemp = xNode->getEndSync();
- if( aTemp.hasValue() )
+ if( aTemp.hasValue() && (aTemp >>= nTemp) )
{
- if( aTemp >>= nTemp )
- {
- SvXMLUnitConverter::convertEnum( sTmp, nTemp, aAnimations_EnumMap_Endsync );
- mrExport.AddAttribute( XML_NAMESPACE_SMIL, XML_ENDSYNC, sTmp.makeStringAndClear() );
- }
+ SvXMLUnitConverter::convertEnum( sTmp, nTemp, aAnimations_EnumMap_Endsync );
+ mrExport.AddAttribute( XML_NAMESPACE_SMIL, XML_ENDSYNC, sTmp.makeStringAndClear() );
}
sal_Int16 nContainerNodeType = EffectNodeType::DEFAULT;
diff --git a/xmloff/source/draw/ximpshap.cxx b/xmloff/source/draw/ximpshap.cxx
index a8f9a7a1dbff..8988e52dd9f1 100644
--- a/xmloff/source/draw/ximpshap.cxx
+++ b/xmloff/source/draw/ximpshap.cxx
@@ -3894,19 +3894,16 @@ void SdXMLTableShapeContext::StartElement( const css::uno::Reference< css::xml::
uno::Reference< beans::XPropertySet > xProps(mxShape, uno::UNO_QUERY);
- if(bIsPresShape)
+ if(bIsPresShape && xProps.is())
{
- if(xProps.is())
+ uno::Reference< beans::XPropertySetInfo > xPropsInfo( xProps->getPropertySetInfo() );
+ if( xPropsInfo.is() )
{
- uno::Reference< beans::XPropertySetInfo > xPropsInfo( xProps->getPropertySetInfo() );
- if( xPropsInfo.is() )
- {
- if( !mbIsPlaceholder && xPropsInfo->hasPropertyByName("IsEmptyPresentationObject"))
- xProps->setPropertyValue("IsEmptyPresentationObject", css::uno::Any(false) );
+ if( !mbIsPlaceholder && xPropsInfo->hasPropertyByName("IsEmptyPresentationObject"))
+ xProps->setPropertyValue("IsEmptyPresentationObject", css::uno::Any(false) );
- if( mbIsUserTransformed && xPropsInfo->hasPropertyByName("IsPlaceholderDependent"))
- xProps->setPropertyValue("IsPlaceholderDependent", css::uno::Any(false) );
- }
+ if( mbIsUserTransformed && xPropsInfo->hasPropertyByName("IsPlaceholderDependent"))
+ xProps->setPropertyValue("IsPlaceholderDependent", css::uno::Any(false) );
}
}