writerfilter/source/dmapper/DomainMapper.cxx | 14 ++------------ writerfilter/source/dmapper/DomainMapper.hxx | 3 --- writerfilter/source/dmapper/DomainMapper_Impl.cxx | 16 +++++----------- writerfilter/source/dmapper/DomainMapper_Impl.hxx | 1 - writerfilter/source/dmapper/SdtHelper.cxx | 8 ++------ writerfilter/source/dmapper/SdtHelper.hxx | 1 - writerfilter/source/dmapper/TableManager.cxx | 8 ++++---- writerfilter/source/dmapper/TableManager.hxx | 21 --------------------- writerfilter/source/rtftok/rtfdocumentimpl.cxx | 7 +------ writerfilter/source/rtftok/rtfdocumentimpl.hxx | 1 - xmlhelp/source/cxxhelp/provider/urlparameter.cxx | 4 ++-- xmlhelp/source/cxxhelp/provider/urlparameter.hxx | 8 ++------ 12 files changed, 18 insertions(+), 74 deletions(-)
New commits: commit 3c4c5aa8cce98fb95473d63d05ba9097e9032ccc Author: Noel Grandin <noel.gran...@collabora.co.uk> Date: Mon Oct 24 14:29:17 2016 +0200 loplugin:expandablemethods in writerfilter..xmlhelp Change-Id: I23ce30e2f15b6fe857a727f1ef84c40d8d0b127d diff --git a/writerfilter/source/dmapper/DomainMapper.cxx b/writerfilter/source/dmapper/DomainMapper.cxx index f37025f..d69cf50 100644 --- a/writerfilter/source/dmapper/DomainMapper.cxx +++ b/writerfilter/source/dmapper/DomainMapper.cxx @@ -190,9 +190,9 @@ DomainMapper::~DomainMapper() // Grab-bag handling comphelper::SequenceAsHashMap aProperties; // Add the saved w:themeFontLang setting - aProperties["ThemeFontLangProps"] = uno::makeAny(GetThemeFontLangProperties()); + aProperties["ThemeFontLangProps"] = uno::makeAny(m_pImpl->GetSettingsTable()->GetThemeFontLangProperties()); // Add the saved compat settings - aProperties["CompatSettings"] = uno::makeAny(GetCompatSettings()); + aProperties["CompatSettings"] = uno::makeAny(m_pImpl->GetSettingsTable()->GetCompatSettings()); uno::Reference<beans::XPropertySet> xDocProps(m_pImpl->GetTextDocument(), uno::UNO_QUERY); if (xDocProps.is()) { @@ -3675,16 +3675,6 @@ beans::PropertyValue DomainMapper::getInteropGrabBag() return aRet; } -uno::Sequence<beans::PropertyValue> DomainMapper::GetThemeFontLangProperties() const -{ - return m_pImpl->GetSettingsTable()->GetThemeFontLangProperties(); -} - -uno::Sequence<beans::PropertyValue> DomainMapper::GetCompatSettings() const -{ - return m_pImpl->GetSettingsTable()->GetCompatSettings(); -} - void DomainMapper::HandleRedline( Sprm& rSprm ) { sal_uInt32 nSprmId = rSprm.getId(); diff --git a/writerfilter/source/dmapper/DomainMapper.hxx b/writerfilter/source/dmapper/DomainMapper.hxx index 764be3c..d1b3622 100644 --- a/writerfilter/source/dmapper/DomainMapper.hxx +++ b/writerfilter/source/dmapper/DomainMapper.hxx @@ -120,9 +120,6 @@ public: /// Get the stored tokens and clear the internal storage. css::beans::PropertyValue getInteropGrabBag(); - css::uno::Sequence<css::beans::PropertyValue> GetThemeFontLangProperties() const; - css::uno::Sequence<css::beans::PropertyValue> GetCompatSettings() const; - void HandleRedline( Sprm& rSprm ); private: diff --git a/writerfilter/source/dmapper/DomainMapper_Impl.cxx b/writerfilter/source/dmapper/DomainMapper_Impl.cxx index 980601c..be369fa7 100644 --- a/writerfilter/source/dmapper/DomainMapper_Impl.cxx +++ b/writerfilter/source/dmapper/DomainMapper_Impl.cxx @@ -1682,7 +1682,11 @@ void DomainMapper_Impl::CheckParaMarkerRedline( uno::Reference< text::XTextRange if ( m_pParaMarkerRedline.get( ) ) { CreateRedline( xRange, m_pParaMarkerRedline ); - ResetParaMarkerRedline( ); + if ( m_pParaMarkerRedline.get( ) ) + { + m_pParaMarkerRedline.reset(); + m_currentRedline.reset(); + } } } @@ -5005,16 +5009,6 @@ void DomainMapper_Impl::RemoveTopRedline( ) m_currentRedline.reset(); } -void DomainMapper_Impl::ResetParaMarkerRedline( ) -{ - if ( m_pParaMarkerRedline.get( ) ) - { - m_pParaMarkerRedline.reset(); - m_currentRedline.reset(); - } -} - - void DomainMapper_Impl::ApplySettingsTable() { if (m_pSettingsTable && m_xTextFactory.is()) diff --git a/writerfilter/source/dmapper/DomainMapper_Impl.hxx b/writerfilter/source/dmapper/DomainMapper_Impl.hxx index ec40e8e..b643b7f 100644 --- a/writerfilter/source/dmapper/DomainMapper_Impl.hxx +++ b/writerfilter/source/dmapper/DomainMapper_Impl.hxx @@ -773,7 +773,6 @@ public: void SetCurrentRedlineRevertProperties( const css::uno::Sequence<css::beans::PropertyValue>& aProperties ); void SetCurrentRedlineIsRead(); void RemoveTopRedline( ); - void ResetParaMarkerRedline( ); void SetCurrentRedlineInitials( const OUString& sInitials ); bool IsFirstRun() { return m_bIsFirstRun;} void SetIsFirstRun(bool bval) { m_bIsFirstRun = bval;} diff --git a/writerfilter/source/dmapper/SdtHelper.cxx b/writerfilter/source/dmapper/SdtHelper.cxx index d2e8ab8..a27c017 100644 --- a/writerfilter/source/dmapper/SdtHelper.cxx +++ b/writerfilter/source/dmapper/SdtHelper.cxx @@ -80,7 +80,8 @@ void SdtHelper::createDropDownControl() xPropertySet->setPropertyValue("Dropdown", uno::makeAny(true)); xPropertySet->setPropertyValue("StringItemList", uno::makeAny(comphelper::containerToSequence(m_aDropDownItems))); - createControlShape(lcl_getOptimalWidth(m_rDM_Impl.GetStyleSheetTable(), aDefaultText, m_aDropDownItems), xControlModel); + createControlShape(lcl_getOptimalWidth(m_rDM_Impl.GetStyleSheetTable(), aDefaultText, m_aDropDownItems), + xControlModel, uno::Sequence<beans::PropertyValue>()); m_aDropDownItems.clear(); } @@ -142,11 +143,6 @@ void SdtHelper::createDateControl(OUString& rContentText, const beans::PropertyV createControlShape(lcl_getOptimalWidth(m_rDM_Impl.GetStyleSheetTable(), rContentText, aItems), xControlModel, aGrabBag.getAsConstPropertyValueList()); } -void SdtHelper::createControlShape(awt::Size aSize, uno::Reference<awt::XControlModel> const& xControlModel) -{ - createControlShape(aSize, xControlModel, uno::Sequence<beans::PropertyValue>()); -} - void SdtHelper::createControlShape(awt::Size aSize, uno::Reference<awt::XControlModel> const& xControlModel, const uno::Sequence<beans::PropertyValue>& rGrabBag) { uno::Reference<drawing::XControlShape> xControlShape(m_rDM_Impl.GetTextFactory()->createInstance("com.sun.star.drawing.ControlShape"), uno::UNO_QUERY); diff --git a/writerfilter/source/dmapper/SdtHelper.hxx b/writerfilter/source/dmapper/SdtHelper.hxx index 28bd059..86c634d 100644 --- a/writerfilter/source/dmapper/SdtHelper.hxx +++ b/writerfilter/source/dmapper/SdtHelper.hxx @@ -67,7 +67,6 @@ class SdtHelper bool m_bOutsideAParagraph; /// Create and append the drawing::XControlShape, containing the various models. - void createControlShape(css::awt::Size aSize, css::uno::Reference<css::awt::XControlModel> const&); void createControlShape(css::awt::Size aSize, css::uno::Reference<css::awt::XControlModel> const&, const css::uno::Sequence<css::beans::PropertyValue>& rGrabBag); public: SdtHelper(DomainMapper_Impl& rDM_Impl); diff --git a/writerfilter/source/dmapper/TableManager.cxx b/writerfilter/source/dmapper/TableManager.cxx index e69d322..bbb2806 100644 --- a/writerfilter/source/dmapper/TableManager.cxx +++ b/writerfilter/source/dmapper/TableManager.cxx @@ -68,7 +68,7 @@ void TableManager::insertTableProps(const TablePropertyMapPtr& pProps) if (getTableProps().get() && getTableProps() != pProps) getTableProps()->InsertProps(pProps); else - setTableProps(pProps); + mState.setTableProps(pProps); #ifdef DEBUG_WRITERFILTER TagLogger::getInstance().endElement(); @@ -84,7 +84,7 @@ void TableManager::insertRowProps(const TablePropertyMapPtr& pProps) if (getRowProps().get()) getRowProps()->InsertProps(pProps); else - setRowProps(pProps); + mState.setRowProps(pProps); #ifdef DEBUG_WRITERFILTER TagLogger::getInstance().endElement(); @@ -113,7 +113,7 @@ void TableManager::cellProps(const TablePropertyMapPtr& pProps) if (getCellProps().get()) getCellProps()->InsertProps(pProps); else - setCellProps(pProps); + mState.setCellProps(pProps); #ifdef DEBUG_WRITERFILTER TagLogger::getInstance().endElement(); @@ -264,7 +264,7 @@ void TableManager::endParagraphGroup() { ensureOpenCell(getCellProps()); - if (isCellEnd()) + if (mState.isCellEnd()) { endOfCellAction(); closeCell(getHandle()); diff --git a/writerfilter/source/dmapper/TableManager.hxx b/writerfilter/source/dmapper/TableManager.hxx index d94a805..7c9ba15 100644 --- a/writerfilter/source/dmapper/TableManager.hxx +++ b/writerfilter/source/dmapper/TableManager.hxx @@ -211,23 +211,12 @@ protected: return mState.getCellProps(); } - void setCellProps(TablePropertyMapPtr pProps) - { - mState.setCellProps(pProps); - } - public: TablePropertyMapPtr getRowProps() { return mState.getRowProps(); } - void setRowProps(TablePropertyMapPtr pProps) - { - mState.setRowProps(pProps); - } - - protected: void setInCell(bool bInCell) { @@ -244,11 +233,6 @@ protected: mState.setCellEnd(bCellEnd); } - bool isCellEnd() const - { - return mState.isCellEnd(); - } - void setRowEnd(bool bRowEnd) { mState.setRowEnd(bRowEnd); @@ -264,11 +248,6 @@ protected: return mState.getTableProps(); } - void setTableProps(TablePropertyMapPtr pProps) - { - mState.setTableProps(pProps); - } - const css::uno::Reference<css::text::XTextRange>& getHandle() { return mCurHandle; diff --git a/writerfilter/source/rtftok/rtfdocumentimpl.cxx b/writerfilter/source/rtftok/rtfdocumentimpl.cxx index 577cddc..a65d7b6 100644 --- a/writerfilter/source/rtftok/rtfdocumentimpl.cxx +++ b/writerfilter/source/rtftok/rtfdocumentimpl.cxx @@ -308,11 +308,6 @@ void RTFDocumentImpl::setSuperstream(RTFDocumentImpl* pSuperstream) m_pSuperstream = pSuperstream; } -void RTFDocumentImpl::setAuthorInitials(OUString& rAuthorInitials) -{ - m_aAuthorInitials = rAuthorInitials; -} - bool RTFDocumentImpl::isSubstream() const { return m_pSuperstream != nullptr; @@ -343,7 +338,7 @@ void RTFDocumentImpl::resolveSubstream(std::size_t nPos, Id nId, OUString& rIgno } if (!m_aAuthorInitials.isEmpty()) { - pImpl->setAuthorInitials(m_aAuthorInitials); + pImpl->m_aAuthorInitials = m_aAuthorInitials; m_aAuthorInitials.clear(); } pImpl->m_nDefaultFontIndex = m_nDefaultFontIndex; diff --git a/writerfilter/source/rtftok/rtfdocumentimpl.hxx b/writerfilter/source/rtftok/rtfdocumentimpl.hxx index 3fec689..0a21bbf 100644 --- a/writerfilter/source/rtftok/rtfdocumentimpl.hxx +++ b/writerfilter/source/rtftok/rtfdocumentimpl.hxx @@ -413,7 +413,6 @@ public: return *m_pMapperStream; } void setSuperstream(RTFDocumentImpl* pSuperstream); - void setAuthorInitials(OUString& rAuthorInitials); const css::uno::Reference<css::lang::XMultiServiceFactory>& getModelFactory() { return m_xModelFactory; diff --git a/xmlhelp/source/cxxhelp/provider/urlparameter.cxx b/xmlhelp/source/cxxhelp/provider/urlparameter.cxx index f0e3b76..d1819e9 100644 --- a/xmlhelp/source/cxxhelp/provider/urlparameter.cxx +++ b/xmlhelp/source/cxxhelp/provider/urlparameter.cxx @@ -199,7 +199,7 @@ OUString URLParameter::get_the_tag() } -OUString URLParameter::get_the_path() +OUString URLParameter::get_path() { if(m_bUseDB) { if( ! m_bHelpDataFileRead ) @@ -227,7 +227,7 @@ OUString URLParameter::get_the_title() } -OUString URLParameter::get_the_jar() +OUString URLParameter::get_jar() { if(m_bUseDB) { if( ! m_bHelpDataFileRead ) diff --git a/xmlhelp/source/cxxhelp/provider/urlparameter.hxx b/xmlhelp/source/cxxhelp/provider/urlparameter.hxx index 21dd802..2890999 100644 --- a/xmlhelp/source/cxxhelp/provider/urlparameter.hxx +++ b/xmlhelp/source/cxxhelp/provider/urlparameter.hxx @@ -127,13 +127,13 @@ namespace chelp { // Not called for an directory - OUString get_path() { return get_the_path(); } + OUString get_path(); const OUString& get_eid() const { return m_aEid; } OUString get_title(); - OUString get_jar() { return get_the_jar(); } + OUString get_jar(); const OUString& get_ExtensionRegistryPath() const { return m_aExtensionRegistryPath; } @@ -214,12 +214,8 @@ namespace chelp { OUString get_the_tag(); - OUString get_the_path(); - OUString get_the_title(); - OUString get_the_jar(); - void readHelpDataFile(); void parse() throw( css::ucb::IllegalIdentifierException ); _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits