[Libreoffice-commits] core.git: svl/source
himajin100000
himajin100000 at gmail.com
Sat Mar 31 09:03:02 UTC 2018
svl/source/items/stylepool.cxx | 12 +++++++++++-
1 file changed, 11 insertions(+), 1 deletion(-)
New commits:
commit abbd8994740ee4c51bf473edba7b7dabf72c3a47
Author: himajin100000 <himajin100000 at gmail.com>
Date: Wed Mar 28 18:22:40 2018 +0900
explicitly pass false as arguments of createIterator
StylePool::createIterator has default paramters,but StylePoolImpl's does not.
Change-Id: I1eff95cd3dc9e9bf7bae04aa78920c2d82acabd8
Reviewed-on: https://gerrit.libreoffice.org/52160
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>
diff --git a/svl/source/items/stylepool.cxx b/svl/source/items/stylepool.cxx
index 15fb042ef0e9..f1ddc7e0ab7b 100644
--- a/svl/source/items/stylepool.cxx
+++ b/svl/source/items/stylepool.cxx
@@ -334,10 +334,16 @@ private:
std::map< const SfxItemSet*, Node > maRoot;
// #i86923#
std::unique_ptr<SfxItemSet> mpIgnorableItems;
+#ifdef DEBUG
+ sal_Int32 mnCount;
+#endif
public:
// #i86923#
explicit StylePoolImpl( SfxItemSet const * pIgnorableItems )
: maRoot(),
+#ifdef DEBUG
+ mnCount(0),
+#endif
mpIgnorableItems( pIgnorableItems != nullptr
? pIgnorableItems->Clone( false )
: nullptr )
@@ -355,6 +361,7 @@ public:
bool bSkipIgnorableItems );
};
+
std::shared_ptr<SfxItemSet> StylePoolImpl::insertItemSet( const SfxItemSet& rSet )
{
bool bNonPoolable = false;
@@ -400,6 +407,9 @@ std::shared_ptr<SfxItemSet> StylePoolImpl::insertItemSet( const SfxItemSet& rSet
{
pCurNode->setItemSet( rSet );
bNonPoolable = false; // to avoid a double insertion
+#ifdef DEBUG
+ ++mnCount;
+#endif
}
// If rSet contains at least one non poolable item, a new itemset has to be inserted
if( bNonPoolable )
@@ -407,7 +417,7 @@ std::shared_ptr<SfxItemSet> StylePoolImpl::insertItemSet( const SfxItemSet& rSet
#ifdef DEBUG
{
sal_Int32 nCheck = -1;
- IStylePoolIteratorAccess* pIter = createIterator();
+ IStylePoolIteratorAccess* pIter = createIterator(false,false);
std::shared_ptr<SfxItemSet> pTemp;
do
{
More information about the Libreoffice-commits
mailing list