diff options
author | Arkadiy Illarionov <qarkai@gmail.com> | 2019-05-04 21:20:18 +0300 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-06-05 19:24:57 +0200 |
commit | 2ed3d691b42525f6c1cc430d5863febcb102816e (patch) | |
tree | 97088acb96f8ad26f2ae67f3f8e5c2f6aab05cf0 /dbaccess/source/ui/querydesign | |
parent | 6c31c2b01dd32cc7ba1230f2c4a98b8f7def219b (diff) |
Use hasElements to check Sequence emptiness in cppcanvas..desktop
Similar to clang-tidy readability-container-size-empty
Change-Id: I81c0ff78d2ecc7d984e3ed5e5ce60efe327fc162
Reviewed-on: https://gerrit.libreoffice.org/71799
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'dbaccess/source/ui/querydesign')
-rw-r--r-- | dbaccess/source/ui/querydesign/querycontroller.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/dbaccess/source/ui/querydesign/querycontroller.cxx b/dbaccess/source/ui/querydesign/querycontroller.cxx index 9ed4334768e8..3b4840492269 100644 --- a/dbaccess/source/ui/querydesign/querycontroller.cxx +++ b/dbaccess/source/ui/querydesign/querycontroller.cxx @@ -600,7 +600,7 @@ void OQueryController::Execute(sal_uInt16 _nId, const Sequence< PropertyValue >& setModified(true); break; case SID_QUERY_LIMIT: - if ( aArgs.getLength() >= 1 && aArgs[0].Name == "DBLimit.Value" ) + if ( aArgs.hasElements() && aArgs[0].Name == "DBLimit.Value" ) { aArgs[0].Value >>= m_nLimit; setModified(true); @@ -767,7 +767,7 @@ void OQueryController::impl_initialize() Sequence< PropertyValue > aCurrentQueryDesignProps; aCurrentQueryDesignProps = rArguments.getOrDefault( "CurrentQueryDesign", aCurrentQueryDesignProps ); - if ( aCurrentQueryDesignProps.getLength() ) + if ( aCurrentQueryDesignProps.hasElements() ) { ::comphelper::NamedValueCollection aCurrentQueryDesign( aCurrentQueryDesignProps ); if ( aCurrentQueryDesign.has( OUString(PROPERTY_GRAPHICAL_DESIGN) ) ) @@ -1678,7 +1678,7 @@ void OQueryController::impl_reset( const bool i_bForceCurrentControllerSettings if ( bValid ) { // load the layoutInformation - if ( aLayoutInformation.getLength() ) + if ( aLayoutInformation.hasElements() ) { try { |