summaryrefslogtreecommitdiff
path: root/toolkit
diff options
context:
space:
mode:
authorMike Kaganski <mike.kaganski@collabora.com>2024-01-27 15:42:54 +0600
committerMike Kaganski <mike.kaganski@collabora.com>2024-01-27 12:43:48 +0100
commit0fa827dbb2147d1d3850b2181eb6ab6a02a04500 (patch)
tree721d02c64c26365e605a2348fd1ff744c4dd8d29 /toolkit
parentdb227dc7d032d642983c313ab74c34a301464c2a (diff)
Drop std::as_const from css::uno::Sequence iterations
Obsoleted by commit 2484de6728bd11bb7949003d112f1ece2223c7a1 (Remove non-const Sequence::begin()/end() in internal code, 2021-10-15) and commit fb3c04bd1930eedacd406874e1a285d62bbf27d9 (Drop non-const Sequence::operator[] in internal code, 2021-11-05). Change-Id: Idbafef5d34c0d4771cbbf75b9db9712e504164cd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/162640 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'toolkit')
-rw-r--r--toolkit/source/awt/vclxtoolkit.cxx4
-rw-r--r--toolkit/source/awt/vclxwindow1.cxx2
-rw-r--r--toolkit/source/controls/geometrycontrolmodel.cxx2
-rw-r--r--toolkit/source/controls/stdtabcontroller.cxx4
-rw-r--r--toolkit/source/controls/unocontrolmodel.cxx6
5 files changed, 9 insertions, 9 deletions
diff --git a/toolkit/source/awt/vclxtoolkit.cxx b/toolkit/source/awt/vclxtoolkit.cxx
index fc6b7b9df8d9..d6d7e0986eb1 100644
--- a/toolkit/source/awt/vclxtoolkit.cxx
+++ b/toolkit/source/awt/vclxtoolkit.cxx
@@ -1699,7 +1699,7 @@ vcl::Window* VCLXToolkit::ImplCreateWindow( rtl::Reference<VCLXWindow>* ppNewCom
css::uno::Sequence< css::beans::NamedValue > aProps;
if( anyHandle >>= aProps )
{
- for( const css::beans::NamedValue& rProp : std::as_const(aProps) )
+ for (const css::beans::NamedValue& rProp : aProps)
{
if ( rProp.Name == "WINDOW" )
rProp.Value >>= nWindowHandle;
@@ -1947,7 +1947,7 @@ css::uno::Reference< css::awt::XWindowPeer > VCLXToolkit::createSystemChild( con
css::uno::Sequence< css::beans::NamedValue > aProps;
if( Parent >>= aProps )
{
- for( const css::beans::NamedValue& rProp : std::as_const(aProps) )
+ for (const css::beans::NamedValue& rProp : aProps)
{
if ( rProp.Name == "WINDOW" )
rProp.Value >>= nWindowHandle;
diff --git a/toolkit/source/awt/vclxwindow1.cxx b/toolkit/source/awt/vclxwindow1.cxx
index edc78f7d9258..a55245cafc68 100644
--- a/toolkit/source/awt/vclxwindow1.cxx
+++ b/toolkit/source/awt/vclxwindow1.cxx
@@ -52,7 +52,7 @@ void VCLXWindow::SetSystemParent_Impl(const css::uno::Any& rHandle)
css::uno::Sequence<css::beans::NamedValue> aProps;
if (rHandle >>= aProps)
{
- for (const css::beans::NamedValue& rProp : std::as_const(aProps))
+ for (const css::beans::NamedValue& rProp : aProps)
{
if (rProp.Name == "WINDOW")
rProp.Value >>= nHandle;
diff --git a/toolkit/source/controls/geometrycontrolmodel.cxx b/toolkit/source/controls/geometrycontrolmodel.cxx
index 70e8817da217..c76657d9fbe6 100644
--- a/toolkit/source/controls/geometrycontrolmodel.cxx
+++ b/toolkit/source/controls/geometrycontrolmodel.cxx
@@ -531,7 +531,7 @@ constexpr OUStringLiteral GCM_PROPERTY_RESOURCERESOLVER = u"ResourceResolver";
);
// now loop through our own props
- for ( const Property& rProp : std::as_const(aProps) )
+ for (const Property& rProp : aProps)
{
// look for the current property in the properties of our aggregate
const Property* pAggPropPos = ::std::find_if( std::cbegin(aAggregateProps), std::cend(aAggregateProps), PropertyNameEqual( rProp.Name ) );
diff --git a/toolkit/source/controls/stdtabcontroller.cxx b/toolkit/source/controls/stdtabcontroller.cxx
index bac4aea58547..e645c8b41570 100644
--- a/toolkit/source/controls/stdtabcontroller.cxx
+++ b/toolkit/source/controls/stdtabcontroller.cxx
@@ -92,7 +92,7 @@ bool StdTabController::ImplCreateComponentSequence(
}
bool bOK = true;
- for ( const Reference< XControl >& xCtrl : std::as_const(rControls) )
+ for (const Reference<XControl>& xCtrl : rControls)
{
// Get the matching control for this model
if ( !xCtrl.is() )
@@ -259,7 +259,7 @@ void StdTabController::autoTabOrder( )
// insert sort algorithm
std::vector< ComponentEntry > aCtrls;
aCtrls.reserve(nCtrls);
- for ( const Reference< XWindow >& rComponent : std::as_const(aCompSeq) )
+ for (const Reference<XWindow>& rComponent : aCompSeq)
{
XWindow* pC = rComponent.get();
ComponentEntry newEntry;
diff --git a/toolkit/source/controls/unocontrolmodel.cxx b/toolkit/source/controls/unocontrolmodel.cxx
index fea09b486d63..6b24829a6310 100644
--- a/toolkit/source/controls/unocontrolmodel.cxx
+++ b/toolkit/source/controls/unocontrolmodel.cxx
@@ -643,7 +643,7 @@ void UnoControlModel::write( const css::uno::Reference< css::io::XObjectOutputSt
rValue >>= aSeq;
tools::Long nEntries = aSeq.getLength();
OutStream->writeLong( nEntries );
- for ( const auto& rVal : std::as_const(aSeq) )
+ for (const auto& rVal : aSeq)
OutStream->writeUTF( rVal );
}
else if ( rType == cppu::UnoType< cppu::UnoSequenceType<cppu::UnoUnsignedShortType> >::get() )
@@ -652,7 +652,7 @@ void UnoControlModel::write( const css::uno::Reference< css::io::XObjectOutputSt
rValue >>= aSeq;
tools::Long nEntries = aSeq.getLength();
OutStream->writeLong( nEntries );
- for ( const auto nVal : std::as_const(aSeq) )
+ for (const auto nVal : aSeq)
OutStream->writeShort( nVal );
}
else if ( rType == cppu::UnoType< css::uno::Sequence<sal_Int16> >::get() )
@@ -661,7 +661,7 @@ void UnoControlModel::write( const css::uno::Reference< css::io::XObjectOutputSt
rValue >>= aSeq;
tools::Long nEntries = aSeq.getLength();
OutStream->writeLong( nEntries );
- for ( const auto nVal : std::as_const(aSeq) )
+ for (const auto nVal : aSeq)
OutStream->writeShort( nVal );
}
else if ( rType.getTypeClass() == TypeClass_ENUM )