From 071948d452943dce32ff6f7331aed1fd9379fea8 Mon Sep 17 00:00:00 2001 From: Tor Lillqvist Date: Mon, 2 Sep 2013 21:04:10 +0300 Subject: WaE: statement aligned ... [loplugin] Change-Id: I80256c748fecf1e5d7ffa73fdcde0ed453455b72 --- sfx2/source/dialog/dinfdlg.cxx | 36 +++++++++++++++++++----------------- 1 file changed, 19 insertions(+), 17 deletions(-) diff --git a/sfx2/source/dialog/dinfdlg.cxx b/sfx2/source/dialog/dinfdlg.cxx index 48aad69135c1..8df6b8466717 100644 --- a/sfx2/source/dialog/dinfdlg.cxx +++ b/sfx2/source/dialog/dinfdlg.cxx @@ -2564,32 +2564,34 @@ sal_Bool SfxCmisPropertiesPage::FillItemSet( SfxItemSet& rSet ) std::vector< document::CmisProperty > changedProps; for ( sal_Int32 i = 0; i< aNewProps.getLength( ); ++i ) - if ( aOldProps[i].Updatable && !aNewProps[i].Id.isEmpty( ) ) { - if ( aOldProps[i].Type == CMIS_TYPE_DATETIME ) + if ( aOldProps[i].Updatable && !aNewProps[i].Id.isEmpty( ) ) { - Sequence< util::DateTime > oldValue; - aOldProps[i].Value >>= oldValue; - // We only edit hours and minutes - // don't compare NanoSeconds and Seconds - for ( sal_Int32 ii = 0; ii < oldValue.getLength( ); ++ii ) + if ( aOldProps[i].Type == CMIS_TYPE_DATETIME ) { - oldValue[ii].NanoSeconds = 0; - oldValue[ii].Seconds = 0; + Sequence< util::DateTime > oldValue; + aOldProps[i].Value >>= oldValue; + // We only edit hours and minutes + // don't compare NanoSeconds and Seconds + for ( sal_Int32 ii = 0; ii < oldValue.getLength( ); ++ii ) + { + oldValue[ii].NanoSeconds = 0; + oldValue[ii].Seconds = 0; + } + Sequence< util::DateTime > newValue; + aNewProps[i].Value >>= newValue; + if ( oldValue != newValue ) + { + modifiedNum++; + changedProps.push_back( aNewProps[i] ); + } } - Sequence< util::DateTime > newValue; - aNewProps[i].Value >>= newValue; - if ( oldValue != newValue ) + else if ( aOldProps[i].Value != aNewProps[i].Value ) { modifiedNum++; changedProps.push_back( aNewProps[i] ); } } - else if ( aOldProps[i].Value != aNewProps[i].Value ) - { - modifiedNum++; - changedProps.push_back( aNewProps[i] ); - } } Sequence< document::CmisProperty> aModifiedProps( modifiedNum ); sal_Int32 nCount = 0; -- cgit