diff options
author | Noel Grandin <noel@peralex.com> | 2016-06-26 21:48:06 +0200 |
---|---|---|
committer | Eike Rathke <erack@redhat.com> | 2016-07-13 12:27:45 +0000 |
commit | c4cb83504faa1d241a116001fd27f7148de300ba (patch) | |
tree | 2cd6c2e215abd29e9b9e18669b1688127a62ab75 /sc/source/filter/oox/pagesettings.cxx | |
parent | c8720ee6ecfc653ad024b8e99d2a0dff95db9de8 (diff) |
loplugin:singlevalfields in sc(part2)
the meFilterType field in WorkbookGlobals lead to a chain reaction
of code removal.
Change-Id: Iaa8b467c1c76cab78f8ce1796709590b666028db
Reviewed-on: https://gerrit.libreoffice.org/26682
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Eike Rathke <erack@redhat.com>
Tested-by: Eike Rathke <erack@redhat.com>
Diffstat (limited to 'sc/source/filter/oox/pagesettings.cxx')
-rw-r--r-- | sc/source/filter/oox/pagesettings.cxx | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/sc/source/filter/oox/pagesettings.cxx b/sc/source/filter/oox/pagesettings.cxx index 3a484578de26..de3dca675699 100644 --- a/sc/source/filter/oox/pagesettings.cxx +++ b/sc/source/filter/oox/pagesettings.cxx @@ -567,18 +567,17 @@ double HeaderFooterParser::parse( const Reference<sheet::XHeaderFooterContent>& } break; case 'Z': // file path (without file name), OOXML, BIFF12, and BIFF8 only - if( (getFilterType() == FILTER_OOXML) || ((getFilterType() == FILTER_BIFF) && (getBiff() == BIFF8)) ) - { - Reference<text::XTextContent> xContent = createField( maFileNameService ); - PropertySet aPropSet( xContent ); - // FilenameDisplayFormat::PATH not supported by Calc - aPropSet.setProperty( PROP_FileFormat, css::text::FilenameDisplayFormat::FULL ); - appendField( xContent ); - /* path only is not supported -- if we find a '&Z&F' - combination for path/name, skip the '&F' part */ - if( (pcChar + 2 < pcEnd) && (pcChar[ 1 ] == '&') && ((pcChar[ 2 ] == 'f') || (pcChar[ 2 ] == 'F')) ) - pcChar += 2; - } + { + Reference<text::XTextContent> xContent = createField( maFileNameService ); + PropertySet aPropSet( xContent ); + // FilenameDisplayFormat::PATH not supported by Calc + aPropSet.setProperty( PROP_FileFormat, css::text::FilenameDisplayFormat::FULL ); + appendField( xContent ); + /* path only is not supported -- if we find a '&Z&F' + combination for path/name, skip the '&F' part */ + if( (pcChar + 2 < pcEnd) && (pcChar[ 1 ] == '&') && ((pcChar[ 2 ] == 'f') || (pcChar[ 2 ] == 'F')) ) + pcChar += 2; + } break; case 'D': // date { @@ -635,7 +634,7 @@ double HeaderFooterParser::parse( const Reference<sheet::XHeaderFooterContent>& break; case 'K': // text color (not in BIFF) - if( (getFilterType() == FILTER_OOXML) && (pcChar + 6 < pcEnd) ) + if( pcChar + 6 < pcEnd ) { setAttributes(); // eat the following 6 characters |