summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2016-09-14 08:53:38 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2016-09-14 08:46:12 +0000
commit0761f97525b3f3ce2cd73f8db28bf389a3c44f57 (patch)
tree29e1b724f563011eaab28c40eba8e4db8e2fa898
parente44addfd5d227123928d1295bb8582799aaac6a0 (diff)
loplugin:constantparam in accessibility to basic
Change-Id: Id77cbcaefebf310a5d99c6ac12d154e182fd0a1c Reviewed-on: https://gerrit.libreoffice.org/28860 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
-rw-r--r--accessibility/inc/extended/AccessibleGridControlTableCell.hxx3
-rw-r--r--accessibility/inc/standard/vclxaccessiblemenuseparator.hxx2
-rw-r--r--accessibility/source/extended/AccessibleGridControlTable.cxx6
-rw-r--r--accessibility/source/extended/AccessibleGridControlTableCell.cxx5
-rw-r--r--accessibility/source/standard/vclxaccessiblemenuseparator.cxx4
-rw-r--r--basic/source/sbx/sbxbase.cxx10
-rw-r--r--include/basic/sbxfac.hxx4
7 files changed, 11 insertions, 23 deletions
diff --git a/accessibility/inc/extended/AccessibleGridControlTableCell.hxx b/accessibility/inc/extended/AccessibleGridControlTableCell.hxx
index 7b3bba66b427..6edf28c07560 100644
--- a/accessibility/inc/extended/AccessibleGridControlTableCell.hxx
+++ b/accessibility/inc/extended/AccessibleGridControlTableCell.hxx
@@ -76,8 +76,7 @@ namespace accessibility
AccessibleGridControlTableCell( const css::uno::Reference< css::accessibility::XAccessible >& _rxParent,
::svt::table::IAccessibleTable& _rTable,
sal_Int32 _nRowId,
- sal_uInt16 _nColId,
- svt::table::AccessibleTableControlObjType eObjType);
+ sal_uInt16 _nColId);
// XInterface -------------------------------------------------------------
diff --git a/accessibility/inc/standard/vclxaccessiblemenuseparator.hxx b/accessibility/inc/standard/vclxaccessiblemenuseparator.hxx
index 556e461172a5..c477caa7450e 100644
--- a/accessibility/inc/standard/vclxaccessiblemenuseparator.hxx
+++ b/accessibility/inc/standard/vclxaccessiblemenuseparator.hxx
@@ -29,7 +29,7 @@
class VCLXAccessibleMenuSeparator : public OAccessibleMenuItemComponent
{
public:
- VCLXAccessibleMenuSeparator( Menu* pParent, sal_uInt16 nItemPos, Menu* pMenu = nullptr );
+ VCLXAccessibleMenuSeparator( Menu* pParent, sal_uInt16 nItemPos );
virtual ~VCLXAccessibleMenuSeparator() override;
// XServiceInfo
diff --git a/accessibility/source/extended/AccessibleGridControlTable.cxx b/accessibility/source/extended/AccessibleGridControlTable.cxx
index 5ac584f2e4b1..38a04749c0ec 100644
--- a/accessibility/source/extended/AccessibleGridControlTable.cxx
+++ b/accessibility/source/extended/AccessibleGridControlTable.cxx
@@ -66,7 +66,7 @@ AccessibleGridControlTable::getAccessibleChild( sal_Int32 nChildIndex )
}
if(!m_pAccessCellVector[nChildIndex].is())
{
- AccessibleGridControlTableCell* pCell = new AccessibleGridControlTableCell(this, m_aTable, nChildIndex/m_aTable.GetColumnCount(), nChildIndex%m_aTable.GetColumnCount(), TCTYPE_TABLECELL);
+ AccessibleGridControlTableCell* pCell = new AccessibleGridControlTableCell(this, m_aTable, nChildIndex/m_aTable.GetColumnCount(), nChildIndex%m_aTable.GetColumnCount());
m_pCellVector[nChildIndex] = pCell;
m_pAccessCellVector[nChildIndex] = pCell;
}
@@ -99,7 +99,7 @@ AccessibleGridControlTable::getAccessibleAtPoint( const awt::Point& rPoint )
sal_Int32 nRow = 0;
sal_Int32 nColumnPos = 0;
if( m_aTable.ConvertPointToCellAddress( nRow, nColumnPos, VCLPoint( rPoint ) ) )
- xChild = new AccessibleGridControlTableCell(this, m_aTable, nRow, nColumnPos, TCTYPE_TABLECELL);
+ xChild = new AccessibleGridControlTableCell(this, m_aTable, nRow, nColumnPos);
return xChild;
}
@@ -219,7 +219,7 @@ Reference< XAccessible > SAL_CALL AccessibleGridControlTable::getAccessibleCellA
}
if(!m_pAccessCellVector[nChildIndex].is())
{
- AccessibleGridControlTableCell* pCell = new AccessibleGridControlTableCell(this, m_aTable, nRow, nColumn, TCTYPE_TABLECELL);
+ AccessibleGridControlTableCell* pCell = new AccessibleGridControlTableCell(this, m_aTable, nRow, nColumn);
m_pCellVector[nChildIndex] = pCell;
m_pAccessCellVector[nChildIndex] = pCell;
}
diff --git a/accessibility/source/extended/AccessibleGridControlTableCell.cxx b/accessibility/source/extended/AccessibleGridControlTableCell.cxx
index 85bd0022fe49..7703b3f3a2ec 100644
--- a/accessibility/source/extended/AccessibleGridControlTableCell.cxx
+++ b/accessibility/source/extended/AccessibleGridControlTableCell.cxx
@@ -103,9 +103,8 @@ namespace accessibility
AccessibleGridControlTableCell::AccessibleGridControlTableCell(const css::uno::Reference<XAccessible >& _rxParent,
::svt::table::IAccessibleTable& _rTable,
sal_Int32 _nRowPos,
- sal_uInt16 _nColPos,
- ::svt::table::AccessibleTableControlObjType eObjType)
- :AccessibleGridControlCell( _rxParent, _rTable, _nRowPos, _nColPos, eObjType )
+ sal_uInt16 _nColPos)
+ :AccessibleGridControlCell( _rxParent, _rTable, _nRowPos, _nColPos, TCTYPE_TABLECELL )
{
}
diff --git a/accessibility/source/standard/vclxaccessiblemenuseparator.cxx b/accessibility/source/standard/vclxaccessiblemenuseparator.cxx
index 6c2695260e61..3e92cf818ddc 100644
--- a/accessibility/source/standard/vclxaccessiblemenuseparator.cxx
+++ b/accessibility/source/standard/vclxaccessiblemenuseparator.cxx
@@ -31,8 +31,8 @@ using namespace ::comphelper;
// class VCLXAccessibleMenuSeparator
-VCLXAccessibleMenuSeparator::VCLXAccessibleMenuSeparator( Menu* pParent, sal_uInt16 nItemPos, Menu* pMenu )
- :OAccessibleMenuItemComponent( pParent, nItemPos, pMenu )
+VCLXAccessibleMenuSeparator::VCLXAccessibleMenuSeparator( Menu* pParent, sal_uInt16 nItemPos )
+ :OAccessibleMenuItemComponent( pParent, nItemPos, nullptr )
{
}
diff --git a/basic/source/sbx/sbxbase.cxx b/basic/source/sbx/sbxbase.cxx
index c5e11629a161..d0296fcf4c5f 100644
--- a/basic/source/sbx/sbxbase.cxx
+++ b/basic/source/sbx/sbxbase.cxx
@@ -119,15 +119,7 @@ void SbxBase::AddFactory( SbxFactory* pFac )
{
SbxAppData& r = GetSbxData_Impl();
- // From 1996-03-06: take the HandleLast-Flag into account
- sal_uInt16 nPos = r.m_Factories.size(); // Insert position
- if( !pFac->IsHandleLast() ) // Only if not self HandleLast
- {
- // Rank new factory in front of factories with HandleLast
- while (nPos > 0 && r.m_Factories[ nPos-1 ]->IsHandleLast())
- nPos--;
- }
- r.m_Factories.insert(r.m_Factories.begin() + nPos, std::unique_ptr<SbxFactory>(pFac));
+ r.m_Factories.insert(r.m_Factories.begin(), std::unique_ptr<SbxFactory>(pFac));
}
void SbxBase::RemoveFactory( SbxFactory* pFac )
diff --git a/include/basic/sbxfac.hxx b/include/basic/sbxfac.hxx
index 5b3e3b4cf7b8..04358d899425 100644
--- a/include/basic/sbxfac.hxx
+++ b/include/basic/sbxfac.hxx
@@ -29,11 +29,9 @@ class SbxObject;
class BASIC_DLLPUBLIC SbxFactory
{
- bool bHandleLast; // true: Factory is asked at last because of its expensiveness
public:
virtual ~SbxFactory();
- SbxFactory( bool bLast=false ) { bHandleLast = bLast; }
- bool IsHandleLast() { return bHandleLast; }
+ SbxFactory() {}
virtual SbxBase* Create( sal_uInt16 nSbxId, sal_uInt32 );
virtual SbxObject* CreateObject( const OUString& );
};