diff options
author | Miklos Vajna <vmiklos@collabora.co.uk> | 2016-11-23 09:15:14 +0100 |
---|---|---|
committer | Andras Timar <andras.timar@collabora.com> | 2017-02-17 12:24:46 +0100 |
commit | 48e2fb1c34e6f95ae934f46d12b13712b02ea53c (patch) | |
tree | cc52213ac52c0d972c18e99dab8f0be51867c561 /sw | |
parent | a481971d171a5ee50251ca578284a10324c568af (diff) |
sw: clean up redundant initializers in rtfstringbuffer
Change-Id: Ie4bb6689b3b9bdfcfaab1f1c9320792672fb847a
Reviewed-on: https://gerrit.libreoffice.org/31107
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
Tested-by: Jenkins <ci@libreoffice.org>
(cherry picked from commit 6920eb20ae271b4f1cdbf574eb4beb8c796fcc6d)
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/filter/ww8/rtfexportfilter.cxx | 4 | ||||
-rw-r--r-- | sw/source/filter/ww8/rtfstringbuffer.cxx | 15 |
2 files changed, 6 insertions, 13 deletions
diff --git a/sw/source/filter/ww8/rtfexportfilter.cxx b/sw/source/filter/ww8/rtfexportfilter.cxx index 34bdd46ed466..81707231c7d2 100644 --- a/sw/source/filter/ww8/rtfexportfilter.cxx +++ b/sw/source/filter/ww8/rtfexportfilter.cxx @@ -36,9 +36,7 @@ RtfExportFilter::RtfExportFilter(const uno::Reference< uno::XComponentContext >& { } -RtfExportFilter::~RtfExportFilter() -{ -} +RtfExportFilter::~RtfExportFilter() = default; sal_Bool RtfExportFilter::filter(const uno::Sequence< beans::PropertyValue >& aDescriptor) throw(uno::RuntimeException, std::exception) { diff --git a/sw/source/filter/ww8/rtfstringbuffer.cxx b/sw/source/filter/ww8/rtfstringbuffer.cxx index a8394d03dd2c..3d7cffc76a7d 100644 --- a/sw/source/filter/ww8/rtfstringbuffer.cxx +++ b/sw/source/filter/ww8/rtfstringbuffer.cxx @@ -10,15 +10,13 @@ #include "rtfattributeoutput.hxx" RtfStringBufferValue::RtfStringBufferValue() - : m_aBuffer(), - m_pFlyFrameFormat(nullptr), + : m_pFlyFrameFormat(nullptr), m_pGrfNode(nullptr) { } RtfStringBufferValue::RtfStringBufferValue(const SwFlyFrameFormat* pFlyFrameFormat, const SwGrfNode* pGrfNode) - : m_aBuffer(), - m_pFlyFrameFormat(pFlyFrameFormat), + : m_pFlyFrameFormat(pFlyFrameFormat), m_pGrfNode(pGrfNode) { } @@ -41,10 +39,7 @@ bool RtfStringBufferValue::isGraphic() const return m_pFlyFrameFormat != nullptr && m_pGrfNode != nullptr; } -RtfStringBuffer::RtfStringBuffer() - : m_aValues() -{ -} +RtfStringBuffer::RtfStringBuffer() = default; sal_Int32 RtfStringBuffer::getLength() const { @@ -73,7 +68,7 @@ OString RtfStringBuffer::makeStringAndClear() OStringBuffer& RtfStringBuffer::getLastBuffer() { if (m_aValues.empty() || m_aValues.back().isGraphic()) - m_aValues.push_back(RtfStringBufferValue()); + m_aValues.emplace_back(RtfStringBufferValue()); return m_aValues.back().m_aBuffer; } @@ -89,7 +84,7 @@ void RtfStringBuffer::clear() void RtfStringBuffer::append(const SwFlyFrameFormat* pFlyFrameFormat, const SwGrfNode* pGrfNode) { - m_aValues.push_back(RtfStringBufferValue(pFlyFrameFormat, pGrfNode)); + m_aValues.emplace_back(RtfStringBufferValue(pFlyFrameFormat, pGrfNode)); } void RtfStringBuffer::appendAndClear(RtfStringBuffer& rBuf) |