diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-09-25 13:29:49 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-09-26 09:18:39 +0200 |
commit | 7b171dbfb5b50b684eb221270759482fe49b4e15 (patch) | |
tree | 58d97e95bad60c87e1daf9b61d184c57fb3f951c /extensions | |
parent | f04bd7975292d297b72e8bb23aa74a2a5198aa23 (diff) |
loplugin:constmethod in embeddedobj..extensions
Change-Id: Iec6a9ff8b62ac1986cca205435273b64b71f33cd
Reviewed-on: https://gerrit.libreoffice.org/79539
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'extensions')
30 files changed, 54 insertions, 54 deletions
diff --git a/extensions/source/abpilot/abspage.cxx b/extensions/source/abpilot/abspage.cxx index 33770402a664..646bec495186 100644 --- a/extensions/source/abpilot/abspage.cxx +++ b/extensions/source/abpilot/abspage.cxx @@ -67,7 +67,7 @@ namespace abp return m_pDialog->getSettings(); } - const Reference< XComponentContext > & AddressBookSourcePage::getORB() + const Reference< XComponentContext > & AddressBookSourcePage::getORB() const { return m_pDialog->getORB(); } diff --git a/extensions/source/abpilot/abspage.hxx b/extensions/source/abpilot/abspage.hxx index e3fdce0f5077..9c8816f68b7a 100644 --- a/extensions/source/abpilot/abspage.hxx +++ b/extensions/source/abpilot/abspage.hxx @@ -44,7 +44,7 @@ namespace abp OAddressBookSourcePilot* getDialog(); const OAddressBookSourcePilot* getDialog() const; const css::uno::Reference< css::uno::XComponentContext > & - getORB(); + getORB() const; AddressSettings& getSettings(); const AddressSettings& getSettings() const; diff --git a/extensions/source/abpilot/abspilot.hxx b/extensions/source/abpilot/abspilot.hxx index 2a3ed894389e..6f274dc2e241 100644 --- a/extensions/source/abpilot/abspilot.hxx +++ b/extensions/source/abpilot/abspilot.hxx @@ -49,7 +49,7 @@ namespace abp /// get the service factory which was used to create the dialog const css::uno::Reference< css::uno::XComponentContext >& - getORB() { return m_xORB; } + getORB() const { return m_xORB; } AddressSettings& getSettings() { return m_aSettings; } const AddressSettings& getSettings() const { return m_aSettings; } diff --git a/extensions/source/bibliography/bibbeam.cxx b/extensions/source/bibliography/bibbeam.cxx index e2f668d66d1f..d48ad56aab09 100644 --- a/extensions/source/bibliography/bibbeam.cxx +++ b/extensions/source/bibliography/bibbeam.cxx @@ -236,7 +236,7 @@ namespace bib return xReturn; } - Reference< frame::XDispatchProviderInterception > BibBeamer::getDispatchProviderInterception() + Reference< frame::XDispatchProviderInterception > BibBeamer::getDispatchProviderInterception() const { Reference< frame::XDispatchProviderInterception > xReturn; if ( pGridWin ) diff --git a/extensions/source/bibliography/bibbeam.hxx b/extensions/source/bibliography/bibbeam.hxx index b9dd224e3263..e2f2c8eade87 100644 --- a/extensions/source/bibliography/bibbeam.hxx +++ b/extensions/source/bibliography/bibbeam.hxx @@ -58,7 +58,7 @@ namespace bib getControlContainer() override; public: css::uno::Reference< css::frame::XDispatchProviderInterception > - getDispatchProviderInterception(); + getDispatchProviderInterception() const; BibBeamer(vcl::Window* pParent,BibDataManager* pDatMan ); virtual ~BibBeamer() override; diff --git a/extensions/source/bibliography/bibconfig.hxx b/extensions/source/bibliography/bibconfig.hxx index 73240e94efc8..0240b69c036a 100644 --- a/extensions/source/bibliography/bibconfig.hxx +++ b/extensions/source/bibliography/bibconfig.hxx @@ -124,7 +124,7 @@ public: void setBeamerSize(long nSize) {SetModified(); nBeamerSize = nSize;} long getBeamerSize()const {return nBeamerSize;} void setViewSize(long nSize) {SetModified(); nViewSize = nSize;} - long getViewSize() {return nViewSize;} + long getViewSize() const {return nViewSize;} const OUString& getQueryField() const {return sQueryField;} void setQueryField(const OUString& rSet) {SetModified(); sQueryField = rSet;} diff --git a/extensions/source/bibliography/bibmod.hxx b/extensions/source/bibliography/bibmod.hxx index 4df21e1d7f12..10f2777d838d 100644 --- a/extensions/source/bibliography/bibmod.hxx +++ b/extensions/source/bibliography/bibmod.hxx @@ -33,7 +33,7 @@ class BibModul BibModul(); ~BibModul(); - const std::locale& GetResLocale() { return m_aResLocale; } + const std::locale& GetResLocale() const { return m_aResLocale; } static BibConfig* GetConfig(); static BibDataManager* createDataManager(); diff --git a/extensions/source/bibliography/bibview.cxx b/extensions/source/bibliography/bibview.cxx index 63e14b82141e..1664b9f3c249 100644 --- a/extensions/source/bibliography/bibview.cxx +++ b/extensions/source/bibliography/bibview.cxx @@ -205,7 +205,7 @@ namespace bib return mpBibView->getControlContainer(); } - Reference< awt::XControlContainer > BibView::getControlContainer() + Reference< awt::XControlContainer > BibView::getControlContainer() const { Reference< awt::XControlContainer > xReturn; if ( m_pGeneralPage ) diff --git a/extensions/source/bibliography/bibview.hxx b/extensions/source/bibliography/bibview.hxx index 72caf5325156..5ac24ae9bc03 100644 --- a/extensions/source/bibliography/bibview.hxx +++ b/extensions/source/bibliography/bibview.hxx @@ -74,7 +74,7 @@ namespace bib virtual void dispose() override; void UpdatePages(); - css::uno::Reference< css::awt::XControlContainer > getControlContainer(); + css::uno::Reference< css::awt::XControlContainer > getControlContainer() const; virtual void GetFocus() override; diff --git a/extensions/source/bibliography/datman.cxx b/extensions/source/bibliography/datman.cxx index ed29de7a5b08..2d006f60ed30 100644 --- a/extensions/source/bibliography/datman.cxx +++ b/extensions/source/bibliography/datman.cxx @@ -443,7 +443,7 @@ OUString DBChangeDialog_Impl::GetCurrentURL()const } // XDispatchProvider -BibInterceptorHelper::BibInterceptorHelper( ::bib::BibBeamer* pBibBeamer, css::uno::Reference< css::frame::XDispatch > const & xDispatch) +BibInterceptorHelper::BibInterceptorHelper( const ::bib::BibBeamer* pBibBeamer, css::uno::Reference< css::frame::XDispatch > const & xDispatch) { if( pBibBeamer ) { @@ -752,7 +752,7 @@ Reference< XForm > BibDataManager::createDatabaseForm(BibDBDescriptor& rDesc) return xResult; } -Sequence< OUString > BibDataManager::getDataSources() +Sequence< OUString > BibDataManager::getDataSources() const { Sequence< OUString > aTableNameSeq; @@ -795,7 +795,7 @@ void BibDataManager::setFilter(const OUString& rQuery) } -OUString BibDataManager::getFilter() +OUString BibDataManager::getFilter() const { OUString aQueryString; @@ -814,7 +814,7 @@ OUString BibDataManager::getFilter() } -Sequence< OUString > BibDataManager::getQueryFields() +Sequence< OUString > BibDataManager::getQueryFields() const { Sequence< OUString > aFieldSeq; Reference< XNameAccess > xFields = getColumns( m_xForm ); @@ -823,7 +823,7 @@ Sequence< OUString > BibDataManager::getQueryFields() return aFieldSeq; } -OUString BibDataManager::getQueryField() +OUString BibDataManager::getQueryField() const { BibConfig* pConfig = BibModul::GetConfig(); OUString aFieldString = pConfig->getQueryField(); @@ -1374,7 +1374,7 @@ uno::Reference< form::runtime::XFormController > const & BibDataManager::GetForm return m_xFormCtrl; } -void BibDataManager::RegisterInterceptor( ::bib::BibBeamer* pBibBeamer) +void BibDataManager::RegisterInterceptor( const ::bib::BibBeamer* pBibBeamer) { DBG_ASSERT( !m_xInterceptorHelper.is(), "BibDataManager::RegisterInterceptor: called twice!" ); @@ -1383,7 +1383,7 @@ void BibDataManager::RegisterInterceptor( ::bib::BibBeamer* pBibBeamer) } -bool BibDataManager::HasActiveConnection() +bool BibDataManager::HasActiveConnection() const { return getConnection( m_xForm ).is(); } diff --git a/extensions/source/bibliography/datman.hxx b/extensions/source/bibliography/datman.hxx index 1de83d5a03ea..eab668b7e571 100644 --- a/extensions/source/bibliography/datman.hxx +++ b/extensions/source/bibliography/datman.hxx @@ -59,7 +59,7 @@ protected: virtual ~BibInterceptorHelper( ) override; public: - BibInterceptorHelper( ::bib::BibBeamer* pBibBeamer, css::uno::Reference< css::frame::XDispatch > const & xDispatch); + BibInterceptorHelper( const ::bib::BibBeamer* pBibBeamer, css::uno::Reference< css::frame::XDispatch > const & xDispatch); void ReleaseInterceptor(); @@ -124,23 +124,23 @@ public: css::uno::Reference< css::awt::XControlModel > updateGridModel(); - css::uno::Sequence< OUString> getDataSources(); + css::uno::Sequence< OUString> getDataSources() const; - const OUString& getActiveDataSource() {return aDataSourceURL;} + const OUString& getActiveDataSource() const {return aDataSourceURL;} void setActiveDataSource(const OUString& rURL); - const OUString& getActiveDataTable() { return aActiveDataTable;} + const OUString& getActiveDataTable() const { return aActiveDataTable;} void setActiveDataTable(const OUString& rTable); void setFilter(const OUString& rQuery); - OUString getFilter(); + OUString getFilter() const; - css::uno::Sequence< OUString> getQueryFields(); - OUString getQueryField(); + css::uno::Sequence< OUString> getQueryFields() const; + OUString getQueryField() const; void startQueryWith(const OUString& rQuery); - const css::uno::Reference< css::sdb::XSingleSelectQueryComposer >& getParser() { return m_xParser; } - const css::uno::Reference< css::form::XForm >& getForm() { return m_xForm; } + const css::uno::Reference< css::sdb::XSingleSelectQueryComposer >& getParser() const { return m_xParser; } + const css::uno::Reference< css::form::XForm >& getForm() const { return m_xForm; } static OUString getControlName(sal_Int32 nFormatKey ); @@ -161,9 +161,9 @@ public: void ResetIdentifierMapping() {sIdentifierMapping.clear();} css::uno::Reference< css::form::runtime::XFormController > const & GetFormController(); - void RegisterInterceptor( ::bib::BibBeamer* pBibBeamer); + void RegisterInterceptor( const ::bib::BibBeamer* pBibBeamer); - bool HasActiveConnection(); + bool HasActiveConnection() const; }; diff --git a/extensions/source/dbpilots/controlwizard.cxx b/extensions/source/dbpilots/controlwizard.cxx index a5570ca49cbf..ba4dc948e0c0 100644 --- a/extensions/source/dbpilots/controlwizard.cxx +++ b/extensions/source/dbpilots/controlwizard.cxx @@ -110,7 +110,7 @@ namespace dbp m_pDialog->setFormConnection( OAccessRegulator(), _rxConn, _bAutoDispose ); } - const OControlWizardContext& OControlWizardPage::getContext() + const OControlWizardContext& OControlWizardPage::getContext() const { return m_pDialog->getContext(); } diff --git a/extensions/source/dbpilots/controlwizard.hxx b/extensions/source/dbpilots/controlwizard.hxx index 8fb62b9bc2b2..884992bfa30a 100644 --- a/extensions/source/dbpilots/controlwizard.hxx +++ b/extensions/source/dbpilots/controlwizard.hxx @@ -56,7 +56,7 @@ namespace dbp protected: OControlWizard* getDialog(); const OControlWizard* getDialog() const; - const OControlWizardContext& getContext(); + const OControlWizardContext& getContext() const; bool updateContext(); void setFormConnection(const css::uno::Reference< css::sdbc::XConnection >& _rxConn, bool _bAutoDispose = true ); css::uno::Reference< css::sdbc::XConnection > diff --git a/extensions/source/dbpilots/listcombowizard.cxx b/extensions/source/dbpilots/listcombowizard.cxx index 0c0957b41764..3c6e0d94e998 100644 --- a/extensions/source/dbpilots/listcombowizard.cxx +++ b/extensions/source/dbpilots/listcombowizard.cxx @@ -216,7 +216,7 @@ namespace dbp return true; } - Reference< XNameAccess > OLCPage::getTables() + Reference< XNameAccess > OLCPage::getTables() const { Reference< XConnection > xConn = getFormConnection(); DBG_ASSERT(xConn.is(), "OLCPage::getTables: should have an active connection when reaching this page!"); diff --git a/extensions/source/dbpilots/listcombowizard.hxx b/extensions/source/dbpilots/listcombowizard.hxx index 1ecafaf5cf87..93f373eaa6d0 100644 --- a/extensions/source/dbpilots/listcombowizard.hxx +++ b/extensions/source/dbpilots/listcombowizard.hxx @@ -88,7 +88,7 @@ namespace dbp bool isListBox() { return static_cast<OListComboWizard*>(getDialog())->isListBox(); } protected: - css::uno::Reference< css::container::XNameAccess > getTables(); + css::uno::Reference< css::container::XNameAccess > getTables() const; css::uno::Sequence< OUString > getTableFields(); }; diff --git a/extensions/source/propctrlr/browserline.cxx b/extensions/source/propctrlr/browserline.cxx index 4c3a56ecfc46..afb01b626153 100644 --- a/extensions/source/propctrlr/browserline.cxx +++ b/extensions/source/propctrlr/browserline.cxx @@ -195,7 +195,7 @@ namespace pcr } - bool OBrowserLine::IsVisible() + bool OBrowserLine::IsVisible() const { return m_aFtTitle->IsVisible(); } diff --git a/extensions/source/propctrlr/browserline.hxx b/extensions/source/propctrlr/browserline.hxx index f71f9578cd86..45b98a56128e 100644 --- a/extensions/source/propctrlr/browserline.hxx +++ b/extensions/source/propctrlr/browserline.hxx @@ -92,7 +92,7 @@ namespace pcr void SetPosSizePixel(Point aPos,Size aSize); void Show(bool bFlag=true); void Hide(); - bool IsVisible(); + bool IsVisible() const; vcl::Window* GetRefWindow(); void SetTabOrder(vcl::Window* pRefWindow, ZOrderFlags nFlags ); diff --git a/extensions/source/propctrlr/browserlistbox.cxx b/extensions/source/propctrlr/browserlistbox.cxx index 3bfeee430d88..63e5fbf8a680 100644 --- a/extensions/source/propctrlr/browserlistbox.cxx +++ b/extensions/source/propctrlr/browserlistbox.cxx @@ -735,7 +735,7 @@ namespace pcr } - sal_Int32 OBrowserListBox::GetMinimumWidth() + sal_Int32 OBrowserListBox::GetMinimumWidth() const { return m_nTheNameSize + 2 * FRAME_OFFSET + (m_nRowHeight - 4) * 8; } diff --git a/extensions/source/propctrlr/browserlistbox.hxx b/extensions/source/propctrlr/browserlistbox.hxx index 473301dcda2d..c99bf87dd2e8 100644 --- a/extensions/source/propctrlr/browserlistbox.hxx +++ b/extensions/source/propctrlr/browserlistbox.hxx @@ -135,7 +135,7 @@ namespace pcr void EnablePropertyControls( const OUString& _rEntryName, sal_Int16 _nControls, bool _bEnable ); void EnablePropertyLine( const OUString& _rEntryName, bool _bEnable ); - sal_Int32 GetMinimumWidth(); + sal_Int32 GetMinimumWidth() const; sal_Int32 GetMinimumHeight(); diff --git a/extensions/source/propctrlr/browserpage.cxx b/extensions/source/propctrlr/browserpage.cxx index b25527e54e25..ac058cba4ef8 100644 --- a/extensions/source/propctrlr/browserpage.cxx +++ b/extensions/source/propctrlr/browserpage.cxx @@ -61,7 +61,7 @@ namespace pcr m_aListBox->ActivateListBox(IsVisible()); } - sal_Int32 OBrowserPage::getMinimumWidth() + sal_Int32 OBrowserPage::getMinimumWidth() const { return m_aListBox->GetMinimumWidth() + LAYOUT_BORDER_LEFT + LAYOUT_BORDER_RIGHT; } diff --git a/extensions/source/propctrlr/browserpage.hxx b/extensions/source/propctrlr/browserpage.hxx index 55288a0a08a2..983b9f9e5422 100644 --- a/extensions/source/propctrlr/browserpage.hxx +++ b/extensions/source/propctrlr/browserpage.hxx @@ -41,7 +41,7 @@ namespace pcr virtual ~OBrowserPage() override; virtual void dispose() override; - sal_Int32 getMinimumWidth(); + sal_Int32 getMinimumWidth() const; sal_Int32 getMinimumHeight(); OBrowserListBox& getListBox() { return *m_aListBox.get(); } diff --git a/extensions/source/propctrlr/browserview.cxx b/extensions/source/propctrlr/browserview.cxx index 804c55d91914..821e7c6b9eb5 100644 --- a/extensions/source/propctrlr/browserview.cxx +++ b/extensions/source/propctrlr/browserview.cxx @@ -105,7 +105,7 @@ namespace pcr m_pPropBox->SetSizePixel(aSize); } - css::awt::Size OPropertyBrowserView::getMinimumSize() + css::awt::Size OPropertyBrowserView::getMinimumSize() const { Size aSize = GetOutputSizePixel(); if( m_pPropBox ) diff --git a/extensions/source/propctrlr/browserview.hxx b/extensions/source/propctrlr/browserview.hxx index 30203162fdab..46f188e1ff95 100644 --- a/extensions/source/propctrlr/browserview.hxx +++ b/extensions/source/propctrlr/browserview.hxx @@ -55,7 +55,7 @@ namespace pcr void setPageActivationHandler(const Link<LinkParamNone*,void>& _rHdl) { m_aPageActivationHandler = _rHdl; } - css::awt::Size getMinimumSize(); + css::awt::Size getMinimumSize() const; private: DECL_LINK(OnPageActivation, LinkParamNone*, void); diff --git a/extensions/source/propctrlr/commoncontrol.hxx b/extensions/source/propctrlr/commoncontrol.hxx index b6c0add791e1..10ca0023f7a7 100644 --- a/extensions/source/propctrlr/commoncontrol.hxx +++ b/extensions/source/propctrlr/commoncontrol.hxx @@ -75,13 +75,13 @@ namespace pcr // XPropertyControl /// @throws css::uno::RuntimeException - ::sal_Int16 getControlType() { return m_nControlType; } + ::sal_Int16 getControlType() const { return m_nControlType; } /// @throws css::uno::RuntimeException - const css::uno::Reference< css::inspection::XPropertyControlContext >& getControlContext() { return m_xContext; } + const css::uno::Reference< css::inspection::XPropertyControlContext >& getControlContext() const { return m_xContext; } /// @throws css::uno::RuntimeException void setControlContext( const css::uno::Reference< css::inspection::XPropertyControlContext >& _controlcontext ); /// @throws css::uno::RuntimeException - bool isModified( ) { return m_bModified; } + bool isModified( ) const { return m_bModified; } /// @throws css::uno::RuntimeException void notifyModifiedValue( ); diff --git a/extensions/source/propctrlr/propertyeditor.cxx b/extensions/source/propctrlr/propertyeditor.cxx index 40c88d82cc52..e0b6abb3ce99 100644 --- a/extensions/source/propctrlr/propertyeditor.cxx +++ b/extensions/source/propctrlr/propertyeditor.cxx @@ -103,7 +103,7 @@ namespace pcr } - sal_Int32 OPropertyEditor::getMinimumHeight() + sal_Int32 OPropertyEditor::getMinimumHeight() const { sal_Int32 nMinHeight( LAYOUT_BORDER_TOP + LAYOUT_BORDER_BOTTOM ); @@ -127,7 +127,7 @@ namespace pcr } - sal_Int32 OPropertyEditor::getMinimumWidth() + sal_Int32 OPropertyEditor::getMinimumWidth() const { sal_uInt16 nCount = m_aTabControl->GetPageCount(); sal_Int32 nPageMinWidth = 0; @@ -262,7 +262,7 @@ namespace pcr } - sal_uInt16 OPropertyEditor::GetCurPage() + sal_uInt16 OPropertyEditor::GetCurPage() const { if(m_aTabControl->GetPageCount()>0) return m_aTabControl->GetCurPageId(); diff --git a/extensions/source/propctrlr/propertyeditor.hxx b/extensions/source/propctrlr/propertyeditor.hxx index 5469e372f795..ada9db6f1261 100644 --- a/extensions/source/propctrlr/propertyeditor.hxx +++ b/extensions/source/propctrlr/propertyeditor.hxx @@ -87,7 +87,7 @@ namespace pcr sal_uInt16 AppendPage( const OUString& r, const OString& _rHelpId ); void SetPage( sal_uInt16 ); void RemovePage(sal_uInt16 nID); - sal_uInt16 GetCurPage(); + sal_uInt16 GetCurPage() const; void ClearAll(); void SetPropertyValue(const OUString& _rEntryName, const css::uno::Any& _rValue, bool _bUnknownValue ); @@ -105,8 +105,8 @@ namespace pcr void setPageActivationHandler(const Link<LinkParamNone*,void>& _rHdl) { m_aPageActivationHandler = _rHdl; } - sal_Int32 getMinimumWidth(); - sal_Int32 getMinimumHeight(); + sal_Int32 getMinimumWidth() const; + sal_Int32 getMinimumHeight() const; void CommitModified(); diff --git a/extensions/source/scanner/sane.hxx b/extensions/source/scanner/sane.hxx index bdc271065064..19cff7a32f58 100644 --- a/extensions/source/scanner/sane.hxx +++ b/extensions/source/scanner/sane.hxx @@ -102,7 +102,7 @@ public: static bool IsSane() { return pSaneLib != nullptr; } - bool IsOpen() + bool IsOpen() const { return maHandle != nullptr; } static int CountDevices() { return nDevices; } @@ -147,7 +147,7 @@ public: bool ActivateButtonOption( int ); int CountOptions() { return mnOptions; } - int GetDeviceNumber() { return mnDevice; } + int GetDeviceNumber() const { return mnDevice; } bool Open( const char* ); bool Open( int ); diff --git a/extensions/source/scanner/sanedlg.cxx b/extensions/source/scanner/sanedlg.cxx index a2e9649412d2..9ddbaa519c1d 100644 --- a/extensions/source/scanner/sanedlg.cxx +++ b/extensions/source/scanner/sanedlg.cxx @@ -121,7 +121,7 @@ public: mbDragEnable = false; } - bool IsDragEnabled() + bool IsDragEnabled() const { return mbDragEnable; } diff --git a/extensions/source/scanner/sanedlg.hxx b/extensions/source/scanner/sanedlg.hxx index 353dfa1ca09a..00e3f59da53a 100644 --- a/extensions/source/scanner/sanedlg.hxx +++ b/extensions/source/scanner/sanedlg.hxx @@ -105,7 +105,7 @@ public: virtual short run() override; void UpdateScanArea( bool ); - bool getDoScan() { return doScan;} + bool getDoScan() const { return doScan;} }; diff --git a/extensions/source/update/feed/updatefeed.cxx b/extensions/source/update/feed/updatefeed.cxx index e49fb29c4c54..8d00603cae75 100644 --- a/extensions/source/update/feed/updatefeed.cxx +++ b/extensions/source/update/feed/updatefeed.cxx @@ -134,7 +134,7 @@ class UpdateInformationProvider : lang::XServiceInfo > { OUString getUserAgent(bool bExtended); - bool isUserAgentExtended(); + bool isUserAgentExtended() const; public: static uno::Reference< uno::XInterface > createInstance(const uno::Reference<uno::XComponentContext>& xContext); @@ -325,7 +325,7 @@ UpdateInformationProvider::UpdateInformationProvider( } bool -UpdateInformationProvider::isUserAgentExtended() +UpdateInformationProvider::isUserAgentExtended() const { bool bExtendedUserAgent = false; try { |