[Libreoffice-commits] core.git: 3 commits - include/xmloff sd/source xmloff/source
include/xmloff/autolayout.hxx | 32 +++--- sd/source/core/sdpage.cxx |2 sd/source/ui/controller/slidelayoutcontroller.cxx |2 sd/source/ui/sidebar/LayoutMenu.cxx |2 xmloff/source/draw/sdxmlexp.cxx | 47 ++ xmloff/source/draw/ximpstyl.cxx | 46 ++--- 6 files changed, 64 insertions(+), 67 deletions(-) New commits: commit c72a91512caceec6b47ab397bc3514945af462d8 Author: Tor LillqvistDate: Tue Feb 21 00:14:01 2017 +0200 Use symbolic AUTOLAYOUT_* names Change-Id: I76a23c99bf92f33ebea1e138ccb3e948dee5ab84 diff --git a/xmloff/source/draw/sdxmlexp.cxx b/xmloff/source/draw/sdxmlexp.cxx index dec026c..5fb48ca 100644 --- a/xmloff/source/draw/sdxmlexp.cxx +++ b/xmloff/source/draw/sdxmlexp.cxx @@ -326,7 +326,7 @@ ImpXMLAutoLayoutInfo::ImpXMLAutoLayoutInfo(sal_uInt16 nTyp, ImpXMLEXPPageMasterI aLayoutSize.Width() = long( aLayoutSize.Width() * 0.854 ); aLayoutSize.Height() = long( aLayoutSize.Height() * 0.444 ); } -else if((mnType >= 22 && mnType <= 26) || (mnType == 31)) // AUTOLAYOUT_HANDOUT +else if((mnType >= 22 && mnType <= 26) || (mnType == 31)) // AUTOLAYOUT_HANDOUT* { // keep info for inner area in maPresRect, put info for gap size // to maTitleRect position @@ -366,9 +366,8 @@ ImpXMLAutoLayoutInfo::ImpXMLAutoLayoutInfo(sal_uInt16 nTyp, ImpXMLEXPPageMasterI - (aClassicTSize.Height() + (aClassicLPos.Y() - (aClassicTPos.Y() + aClassicTSize.Height(; aLayoutSize.Height() = (aClassicLPos.Y() + aClassicLSize.Height()) - aClassicTPos.Y(); } -else if( mnType == 32 ) +else if( mnType == AUTOLAYOUT_ONLY_TEXT ) { -// AUTOLAYOUT_ONLY_TEXT aLayoutPos = aTitlePos; aLayoutSize.Width() = aTitleSize.Width(); aLayoutSize.Height() = long( aLayoutSize.Height() * 0.825 ); @@ -794,7 +793,7 @@ void SdXMLExport::ImpWriteAutoLayoutInfos() // write presentation placeholders switch(pInfo->GetLayoutType()) { -case 0 : // AUTOLAYOUT_TITLE +case AUTOLAYOUT_TITLE : { ImpWriteAutoLayoutPlaceholder(XmlPlaceholderTitle, pInfo->GetTitleRectangle()); ImpWriteAutoLayoutPlaceholder(XmlPlaceholderSubtitle, pInfo->GetPresRectangle()); @@ -806,7 +805,7 @@ void SdXMLExport::ImpWriteAutoLayoutInfos() ImpWriteAutoLayoutPlaceholder(XmlPlaceholderOutline, pInfo->GetPresRectangle()); break; } -case 2 : // AUTOLAYOUT_CHART +case AUTOLAYOUT_CHART : { ImpWriteAutoLayoutPlaceholder(XmlPlaceholderTitle, pInfo->GetTitleRectangle()); ImpWriteAutoLayoutPlaceholder(XmlPlaceholderChart, pInfo->GetPresRectangle()); @@ -824,7 +823,7 @@ void SdXMLExport::ImpWriteAutoLayoutInfos() ImpWriteAutoLayoutPlaceholder(XmlPlaceholderOutline, aRight); break; } -case 4 : // AUTOLAYOUT_TEXTCHART +case AUTOLAYOUT_TEXTCHART : { Rectangle aLeft(pInfo->GetPresRectangle()); aLeft.setWidth(long(aLeft.GetWidth() * 0.488)); @@ -836,7 +835,7 @@ void SdXMLExport::ImpWriteAutoLayoutInfos() ImpWriteAutoLayoutPlaceholder(XmlPlaceholderChart, aRight); break; } -case 6 : // AUTOLAYOUT_TEXTCLIP +case AUTOLAYOUT_TEXTCLIP : { Rectangle aLeft(pInfo->GetPresRectangle()); aLeft.setWidth(long(aLeft.GetWidth() * 0.488)); @@ -848,7 +847,7 @@ void SdXMLExport::ImpWriteAutoLayoutInfos() ImpWriteAutoLayoutPlaceholder(XmlPlaceholderGraphic, aRight); break; } -case 7 : // AUTOLAYOUT_CHARTTEXT +case AUTOLAYOUT_CHARTTEXT : { Rectangle aLeft(pInfo->GetPresRectangle()); aLeft.setWidth(long(aLeft.GetWidth() * 0.488)); @@ -860,13 +859,13 @@ void SdXMLExport::ImpWriteAutoLayoutInfos() ImpWriteAutoLayoutPlaceholder(XmlPlaceholderOutline, aRight); break; } -case 8 : // AUTOLAYOUT_TAB +case AUTOLAYOUT_TAB : { ImpWriteAutoLayoutPlaceholder(XmlPlaceholderTitle, pInfo->GetTitleRectangle());
[Libreoffice-commits] core.git: 3 commits - include/xmloff sd/source xmloff/source
include/xmloff/shapeexport.hxx |1 - sd/source/ui/unoidl/unoobj.cxx | 12 +++- xmloff/source/draw/shapeexport.cxx |7 +++ 3 files changed, 6 insertions(+), 14 deletions(-) New commits: commit 34ba29887fe2ad47c5a8663bbdc511d46ab732b2 Author: David TardonDate: Mon Nov 14 16:35:50 2016 +0100 replace explicit delete and simplify Change-Id: I750a965195aef32b29bb98725fd1c74c876b051d diff --git a/sd/source/ui/unoidl/unoobj.cxx b/sd/source/ui/unoidl/unoobj.cxx index 83db0e6..ac8f484 100644 --- a/sd/source/ui/unoidl/unoobj.cxx +++ b/sd/source/ui/unoidl/unoobj.cxx @@ -19,6 +19,7 @@ #include +#include #include #include @@ -904,15 +905,8 @@ bool SdXShape::IsEmptyPresObj() const if( pTextObj == nullptr ) return true; -OutlinerParaObject* pParaObj = pTextObj->GetEditOutlinerParaObject(); -if( pParaObj ) -{ -delete pParaObj; -} -else -{ -return true; -} +const std::unique_ptr pParaObj(pTextObj->GetEditOutlinerParaObject()); +return !pParaObj; } return false; commit 0d97ac5ae3e92b1b04339e60e66ca8cb41a19609 Author: David Tardon Date: Mon Nov 14 15:25:28 2016 +0100 fix typo Change-Id: I2dd093a12518c2c23d9f1610fb8a4b45a94656ab diff --git a/xmloff/source/draw/shapeexport.cxx b/xmloff/source/draw/shapeexport.cxx index 3f269ef..a6656c7 100644 --- a/xmloff/source/draw/shapeexport.cxx +++ b/xmloff/source/draw/shapeexport.cxx @@ -1471,7 +1471,7 @@ bool XMLShapeExport::ImpExportPresentationAttributes( const uno::Reference< bean uno::Reference< beans::XPropertySetInfo > xPropSetInfo( xPropSet->getPropertySetInfo() ); -// is empty pes shape? +// is empty pres. shape? if( xPropSetInfo.is() && xPropSetInfo->hasPropertyByName("IsEmptyPresentationObject")) { xPropSet->getPropertyValue("IsEmptyPresentationObject") >>= bIsEmpty; commit 4ead110a8c574379545f9cf1d4a914c7bb43bc2a Author: David Tardon Date: Mon Nov 14 15:24:32 2016 +0100 remove prop. name variable It is not used consistently anyway. Change-Id: Ia842668dfb36dc2a8fbf3b938758b81c78d5c868 diff --git a/include/xmloff/shapeexport.hxx b/include/xmloff/shapeexport.hxx index ce74b19..56588fa 100644 --- a/include/xmloff/shapeexport.hxx +++ b/include/xmloff/shapeexport.hxx @@ -186,7 +186,6 @@ private: const OUString msPrintable; const OUString msVisible; -const OUString msEmptyPres; const OUString msModel; const OUString msStartShape; const OUString msEndShape; diff --git a/xmloff/source/draw/shapeexport.cxx b/xmloff/source/draw/shapeexport.cxx index a22ee35..3f269ef 100644 --- a/xmloff/source/draw/shapeexport.cxx +++ b/xmloff/source/draw/shapeexport.cxx @@ -155,7 +155,6 @@ XMLShapeExport::XMLShapeExport(SvXMLExport& rExp, msZIndex( "ZOrder" ), msPrintable( "Printable" ), msVisible( "Visible" ), -msEmptyPres( "IsEmptyPresentationObject" ), msModel( "Model" ), msStartShape( "StartShape" ), msEndShape( "EndShape" ), @@ -308,9 +307,9 @@ void XMLShapeExport::collectShapeAutoStyles(const uno::Reference< drawing::XShap { uno::Reference< beans::XPropertySetInfo > xPropSetInfo( xPropSet->getPropertySetInfo() ); -if( xPropSetInfo.is() && xPropSetInfo->hasPropertyByName(msEmptyPres) ) +if( xPropSetInfo.is() && xPropSetInfo->hasPropertyByName("IsEmptyPresentationObject") ) { -uno::Any aAny = xPropSet->getPropertyValue(msEmptyPres); +uno::Any aAny = xPropSet->getPropertyValue("IsEmptyPresentationObject"); aAny >>= bIsEmptyPresObj; } ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits