[Libreoffice-commits] core.git: 2 commits - sw/source
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Thu Aug 16 06:56:00 UTC 2018
sw/source/filter/ww8/docxattributeoutput.cxx | 12 ++----------
sw/source/filter/ww8/docxattributeoutput.hxx | 2 +-
sw/source/filter/ww8/ww8toolbar.cxx | 2 +-
3 files changed, 4 insertions(+), 12 deletions(-)
New commits:
commit 4f286af9e85e979382e2c1cea7e0b80640044234
Author: Noel Grandin <noel.grandin at collabora.co.uk>
AuthorDate: Wed Aug 15 13:41:52 2018 +0200
Commit: Noel Grandin <noel.grandin at collabora.co.uk>
CommitDate: Thu Aug 16 08:55:47 2018 +0200
fix bug in SwCTBWrapper::ImportCustomToolBar
the code structure here and at the callsite indicats that wants true to
mean "successfully imported"
Change-Id: Ibe3242e85ed970494c2ee0deb4b898db0fe85d0d
Reviewed-on: https://gerrit.libreoffice.org/59130
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>
diff --git a/sw/source/filter/ww8/ww8toolbar.cxx b/sw/source/filter/ww8/ww8toolbar.cxx
index a807a6b35489..fa868eda0350 100644
--- a/sw/source/filter/ww8/ww8toolbar.cxx
+++ b/sw/source/filter/ww8/ww8toolbar.cxx
@@ -205,7 +205,7 @@ bool SwCTBWrapper::ImportCustomToolBar( SfxObjectShell& rDocSh )
continue;
}
}
- return false;
+ return true;
}
Customization::Customization( SwCTBWrapper* wrapper )
commit 87b04949ee633c9bd8f1407394a104ec70e4031d
Author: Noel Grandin <noel.grandin at collabora.co.uk>
AuthorDate: Wed Aug 15 10:51:03 2018 +0200
Commit: Noel Grandin <noel.grandin at collabora.co.uk>
CommitDate: Thu Aug 16 08:55:31 2018 +0200
loplugin:returnconstant in DocxAttributeOutput
It appears that the last code which returned something other than true
from PostponeOLE was removed in
commit 21d356f691a7c1859f85a19c79060a3d31cffc21
Date: Fri Feb 28 10:44:53 2014 +0100
sw: export OLE objects outside run properties
Change-Id: Ie0197be980014a7ceb58c6b71adf69babd734e4e
Reviewed-on: https://gerrit.libreoffice.org/59128
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>
diff --git a/sw/source/filter/ww8/docxattributeoutput.cxx b/sw/source/filter/ww8/docxattributeoutput.cxx
index f97ffe2645a6..3696f11070ef 100644
--- a/sw/source/filter/ww8/docxattributeoutput.cxx
+++ b/sw/source/filter/ww8/docxattributeoutput.cxx
@@ -4756,14 +4756,7 @@ void DocxAttributeOutput::WriteOLE2Obj( const SdrObject* pSdrObj, SwOLENode& rOL
return;
if( WriteOLEMath( rOLENode ))
return;
- if( PostponeOLE( rOLENode, rSize, pFlyFrameFormat ))
- return;
- // Then we fall back to just export the object as a graphic.
- if( !m_pPostponedGraphic )
- FlyFrameGraphic( nullptr, rSize, pFlyFrameFormat, &rOLENode );
- else
- // w:drawing should not be inside w:rPr, so write it out later
- m_pPostponedGraphic->push_back(PostponedGraphic(nullptr, rSize, pFlyFrameFormat, &rOLENode, nullptr));
+ PostponeOLE( rOLENode, rSize, pFlyFrameFormat );
}
bool DocxAttributeOutput::WriteOLEChart( const SdrObject* pSdrObj, const Size& rSize )
@@ -5183,14 +5176,13 @@ bool DocxAttributeOutput::ExportAsActiveXControl(const SdrObject* pObject) const
return true;
}
-bool DocxAttributeOutput::PostponeOLE( SwOLENode& rNode, const Size& rSize, const SwFlyFrameFormat* pFlyFrameFormat )
+void DocxAttributeOutput::PostponeOLE( SwOLENode& rNode, const Size& rSize, const SwFlyFrameFormat* pFlyFrameFormat )
{
if( !m_pPostponedOLEs )
//cannot be postponed, try to write now
WriteOLE( rNode, rSize, pFlyFrameFormat );
else
m_pPostponedOLEs->push_back( PostponedOLE( &rNode, rSize, pFlyFrameFormat ) );
- return true;
}
/*
diff --git a/sw/source/filter/ww8/docxattributeoutput.hxx b/sw/source/filter/ww8/docxattributeoutput.hxx
index 4d380bf6e656..e4c331ad0dcc 100644
--- a/sw/source/filter/ww8/docxattributeoutput.hxx
+++ b/sw/source/filter/ww8/docxattributeoutput.hxx
@@ -392,7 +392,7 @@ private:
void WriteOLE2Obj( const SdrObject* pSdrObj, SwOLENode& rNode, const Size& rSize, const SwFlyFrameFormat* pFlyFrameFormat);
bool WriteOLEChart( const SdrObject* pSdrObj, const Size& rSize );
bool WriteOLEMath( const SwOLENode& rNode );
- bool PostponeOLE( SwOLENode& rNode, const Size& rSize, const SwFlyFrameFormat* pFlyFrameFormat );
+ void PostponeOLE( SwOLENode& rNode, const Size& rSize, const SwFlyFrameFormat* pFlyFrameFormat );
void WriteOLE( SwOLENode& rNode, const Size& rSize, const SwFlyFrameFormat* rFlyFrameFormat );
void WriteActiveXControl(const SdrObject* pObject, const SwFrameFormat& rFrameFormat, bool bInsideRun);
More information about the Libreoffice-commits
mailing list