Kaydet (Commit) d9234556 authored tarafından Caolán McNamara's avatar Caolán McNamara

don't blow up on .odt export with !hasValue footers/headers

Change-Id: I2507c23b7b17b9172f720548d32cdfe299d4fa20
üst a9097843
...@@ -127,20 +127,21 @@ void XMLTextMasterPageExport::exportMasterPageContent( ...@@ -127,20 +127,21 @@ void XMLTextMasterPageExport::exportMasterPageContent(
else else
{ {
aAny = rPropSet->getPropertyValue( sHeaderOn ); aAny = rPropSet->getPropertyValue( sHeaderOn );
sal_Bool bHeader = *(sal_Bool *)aAny.getValue(); sal_Bool bHeader = sal_False;
aAny >>= bHeader;
sal_Bool bHeaderFirst = sal_False; sal_Bool bHeaderFirst = sal_False;
if( bHeader ) if( bHeader )
{ {
aAny = rPropSet->getPropertyValue( sFirstShareContent ); aAny = rPropSet->getPropertyValue( sFirstShareContent );
bHeaderFirst = !*(sal_Bool *)aAny.getValue(); aAny >>= bHeaderFirst;
} }
sal_Bool bHeaderLeft = sal_False; sal_Bool bHeaderLeft = sal_False;
if( bHeader ) if( bHeader )
{ {
aAny = rPropSet->getPropertyValue( sHeaderShareContent ); aAny = rPropSet->getPropertyValue( sHeaderShareContent );
bHeaderLeft = !*(sal_Bool *)aAny.getValue(); aAny >>= bHeaderLeft;
} }
if( xHeaderText.is() ) if( xHeaderText.is() )
...@@ -174,20 +175,21 @@ void XMLTextMasterPageExport::exportMasterPageContent( ...@@ -174,20 +175,21 @@ void XMLTextMasterPageExport::exportMasterPageContent(
} }
aAny = rPropSet->getPropertyValue( sFooterOn ); aAny = rPropSet->getPropertyValue( sFooterOn );
sal_Bool bFooter = *(sal_Bool *)aAny.getValue(); sal_Bool bFooter = sal_False;
aAny >>= bFooter;
sal_Bool bFooterFirst = sal_False; sal_Bool bFooterFirst = sal_False;
if( bFooter ) if( bFooter )
{ {
aAny = rPropSet->getPropertyValue( sFirstShareContent ); aAny = rPropSet->getPropertyValue( sFirstShareContent );
bFooterFirst = !*(sal_Bool *)aAny.getValue(); aAny >>= bFooterFirst;
} }
sal_Bool bFooterLeft = sal_False; sal_Bool bFooterLeft = sal_False;
if( bFooter ) if( bFooter )
{ {
aAny = rPropSet->getPropertyValue( sFooterShareContent ); aAny = rPropSet->getPropertyValue( sFooterShareContent );
bFooterLeft = !*(sal_Bool *)aAny.getValue(); aAny >>= bFooterLeft;
} }
if( xFooterText.is() ) if( xFooterText.is() )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment