[Libreoffice-commits] core.git: Branch 'feature/perfwork4' - include/svx svx/inc svx/source

Kohei Yoshida kohei.yoshida at collabora.com
Thu Oct 23 13:46:18 PDT 2014


 include/svx/sdr/properties/attributeproperties.hxx  |    2 +-
 include/svx/sdr/properties/defaultproperties.hxx    |    2 +-
 include/svx/sdr/properties/e3dproperties.hxx        |    2 +-
 include/svx/sdr/properties/emptyproperties.hxx      |    2 +-
 include/svx/sdr/properties/properties.hxx           |    2 +-
 include/svx/sdr/properties/textproperties.hxx       |    2 +-
 svx/inc/sdr/properties/captionproperties.hxx        |    2 +-
 svx/inc/sdr/properties/circleproperties.hxx         |    2 +-
 svx/inc/sdr/properties/connectorproperties.hxx      |    2 +-
 svx/inc/sdr/properties/customshapeproperties.hxx    |    2 +-
 svx/inc/sdr/properties/graphicproperties.hxx        |    2 +-
 svx/inc/sdr/properties/groupproperties.hxx          |    2 +-
 svx/inc/sdr/properties/measureproperties.hxx        |    2 +-
 svx/inc/sdr/properties/pageproperties.hxx           |    2 +-
 svx/source/sdr/properties/attributeproperties.cxx   |    8 ++++----
 svx/source/sdr/properties/captionproperties.cxx     |    6 +++---
 svx/source/sdr/properties/circleproperties.cxx      |    6 +++---
 svx/source/sdr/properties/connectorproperties.cxx   |    6 +++---
 svx/source/sdr/properties/customshapeproperties.cxx |    6 +++---
 svx/source/sdr/properties/defaultproperties.cxx     |    6 +++---
 svx/source/sdr/properties/e3dproperties.cxx         |    6 +++---
 svx/source/sdr/properties/emptyproperties.cxx       |    6 +++---
 svx/source/sdr/properties/graphicproperties.cxx     |    6 +++---
 svx/source/sdr/properties/groupproperties.cxx       |    4 ++--
 svx/source/sdr/properties/measureproperties.cxx     |    6 +++---
 svx/source/sdr/properties/pageproperties.cxx        |    6 +++---
 svx/source/sdr/properties/textproperties.cxx        |    6 +++---
 svx/source/table/cell.cxx                           |    8 ++++----
 svx/source/table/svdotable.cxx                      |    8 ++++----
 29 files changed, 61 insertions(+), 61 deletions(-)

New commits:
commit c038ffa360f49e2e08e39726ce74764d485c591b
Author: Kohei Yoshida <kohei.yoshida at collabora.com>
Date:   Thu Oct 23 16:43:51 2014 -0400

    CreateObjectSpecificItemSet to return a pointer, not a reference.
    
    I hope the reason is obvious....
    
    Change-Id: Ibe30038991b4916a6af230043176f09bd9952ff9

diff --git a/include/svx/sdr/properties/attributeproperties.hxx b/include/svx/sdr/properties/attributeproperties.hxx
index a14b634..bbe4be826 100644
--- a/include/svx/sdr/properties/attributeproperties.hxx
+++ b/include/svx/sdr/properties/attributeproperties.hxx
@@ -44,7 +44,7 @@ namespace sdr
             SfxStyleSheet*                                  mpStyleSheet;
 
             // create a new itemset
-            virtual SfxItemSet& CreateObjectSpecificItemSet(SfxItemPool& pPool) SAL_OVERRIDE;
+            virtual SfxItemSet* CreateObjectSpecificItemSet(SfxItemPool& pPool) SAL_OVERRIDE;
 
             // Do the ItemChange, may do special handling
             virtual void ItemChange(const sal_uInt16 nWhich, const SfxPoolItem* pNewItem = 0) SAL_OVERRIDE;
diff --git a/include/svx/sdr/properties/defaultproperties.hxx b/include/svx/sdr/properties/defaultproperties.hxx
index 9e9defe..4fc3b69 100644
--- a/include/svx/sdr/properties/defaultproperties.hxx
+++ b/include/svx/sdr/properties/defaultproperties.hxx
@@ -36,7 +36,7 @@ namespace sdr
             SfxItemSet*                                     mpItemSet;
 
             // create a new itemset
-            virtual SfxItemSet& CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
+            virtual SfxItemSet* CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
 
             // test changeability for a single item
             virtual bool AllowItemChange(const sal_uInt16 nWhich, const SfxPoolItem* pNewItem = 0) const SAL_OVERRIDE;
diff --git a/include/svx/sdr/properties/e3dproperties.hxx b/include/svx/sdr/properties/e3dproperties.hxx
index 39e1023..722b433 100644
--- a/include/svx/sdr/properties/e3dproperties.hxx
+++ b/include/svx/sdr/properties/e3dproperties.hxx
@@ -33,7 +33,7 @@ namespace sdr
         {
         protected:
             // create a new itemset
-            virtual SfxItemSet& CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
+            virtual SfxItemSet* CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
 
             // react on ItemSet changes
             virtual void ItemSetChanged(const SfxItemSet& rSet) SAL_OVERRIDE;
diff --git a/include/svx/sdr/properties/emptyproperties.hxx b/include/svx/sdr/properties/emptyproperties.hxx
index 1c7f025..df5b457 100644
--- a/include/svx/sdr/properties/emptyproperties.hxx
+++ b/include/svx/sdr/properties/emptyproperties.hxx
@@ -36,7 +36,7 @@ namespace sdr
             SfxItemSet*                                     mpEmptyItemSet;
 
             // create a new itemset
-            virtual SfxItemSet& CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
+            virtual SfxItemSet* CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
 
             // test changeability for a single item
             virtual bool AllowItemChange(const sal_uInt16 nWhich, const SfxPoolItem* pNewItem = 0) const SAL_OVERRIDE;
diff --git a/include/svx/sdr/properties/properties.hxx b/include/svx/sdr/properties/properties.hxx
index 2bb32df..4b7e6f2 100644
--- a/include/svx/sdr/properties/properties.hxx
+++ b/include/svx/sdr/properties/properties.hxx
@@ -56,7 +56,7 @@ namespace sdr
             SdrObject&                                      mrObject;
 
             // create a new object specific itemset with object specific ranges.
-            virtual SfxItemSet& CreateObjectSpecificItemSet(SfxItemPool& pPool) = 0;
+            virtual SfxItemSet* CreateObjectSpecificItemSet(SfxItemPool& pPool) = 0;
 
             // internal access to SdrObject
             SdrObject& GetSdrObject() const
diff --git a/include/svx/sdr/properties/textproperties.hxx b/include/svx/sdr/properties/textproperties.hxx
index 3a6a5c6..f6dbc6a 100644
--- a/include/svx/sdr/properties/textproperties.hxx
+++ b/include/svx/sdr/properties/textproperties.hxx
@@ -38,7 +38,7 @@ namespace sdr
 
         protected:
             // create a new itemset
-            virtual SfxItemSet& CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
+            virtual SfxItemSet* CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
 
             // Do the ItemChange, may do special handling
             virtual void ItemChange(const sal_uInt16 nWhich, const SfxPoolItem* pNewItem = 0) SAL_OVERRIDE;
diff --git a/svx/inc/sdr/properties/captionproperties.hxx b/svx/inc/sdr/properties/captionproperties.hxx
index e4c88d2..04fdc09 100644
--- a/svx/inc/sdr/properties/captionproperties.hxx
+++ b/svx/inc/sdr/properties/captionproperties.hxx
@@ -32,7 +32,7 @@ namespace sdr
         {
         protected:
             // create a new itemset
-            virtual SfxItemSet& CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
+            virtual SfxItemSet* CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
 
             // react on ItemSet changes
             virtual void ItemSetChanged(const SfxItemSet& rSet) SAL_OVERRIDE;
diff --git a/svx/inc/sdr/properties/circleproperties.hxx b/svx/inc/sdr/properties/circleproperties.hxx
index 980ad87..3b9a18a 100644
--- a/svx/inc/sdr/properties/circleproperties.hxx
+++ b/svx/inc/sdr/properties/circleproperties.hxx
@@ -32,7 +32,7 @@ namespace sdr
         {
         protected:
             // create a new itemset
-            virtual SfxItemSet& CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
+            virtual SfxItemSet* CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
 
             // react on ItemSet changes
             virtual void ItemSetChanged(const SfxItemSet& rSet) SAL_OVERRIDE;
diff --git a/svx/inc/sdr/properties/connectorproperties.hxx b/svx/inc/sdr/properties/connectorproperties.hxx
index 2553fb5..6159295 100644
--- a/svx/inc/sdr/properties/connectorproperties.hxx
+++ b/svx/inc/sdr/properties/connectorproperties.hxx
@@ -32,7 +32,7 @@ namespace sdr
         {
         protected:
             // create a new itemset
-            virtual SfxItemSet& CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
+            virtual SfxItemSet* CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
 
             // react on ItemSet changes
             virtual void ItemSetChanged(const SfxItemSet& rSet) SAL_OVERRIDE;
diff --git a/svx/inc/sdr/properties/customshapeproperties.hxx b/svx/inc/sdr/properties/customshapeproperties.hxx
index ac58b4e..78bc6b4 100644
--- a/svx/inc/sdr/properties/customshapeproperties.hxx
+++ b/svx/inc/sdr/properties/customshapeproperties.hxx
@@ -35,7 +35,7 @@ namespace sdr
 
         protected:
             // create a new itemset
-            virtual SfxItemSet& CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
+            virtual SfxItemSet* CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
 
             // test changeability for a single item
             virtual bool AllowItemChange(const sal_uInt16 nWhich, const SfxPoolItem* pNewItem = 0) const SAL_OVERRIDE;
diff --git a/svx/inc/sdr/properties/graphicproperties.hxx b/svx/inc/sdr/properties/graphicproperties.hxx
index 8a55e28..2bcc5ac 100644
--- a/svx/inc/sdr/properties/graphicproperties.hxx
+++ b/svx/inc/sdr/properties/graphicproperties.hxx
@@ -32,7 +32,7 @@ namespace sdr
         {
         protected:
             // create a new itemset
-            virtual SfxItemSet& CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
+            virtual SfxItemSet* CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
 
             // react on ItemSet changes
             virtual void ItemSetChanged(const SfxItemSet& rSet) SAL_OVERRIDE;
diff --git a/svx/inc/sdr/properties/groupproperties.hxx b/svx/inc/sdr/properties/groupproperties.hxx
index 0321106..1e842af 100644
--- a/svx/inc/sdr/properties/groupproperties.hxx
+++ b/svx/inc/sdr/properties/groupproperties.hxx
@@ -32,7 +32,7 @@ namespace sdr
         {
         protected:
             // create a new itemset
-            virtual SfxItemSet& CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
+            virtual SfxItemSet* CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
 
             // test changeability for a single item
             virtual bool AllowItemChange(const sal_uInt16 nWhich, const SfxPoolItem* pNewItem = 0) const SAL_OVERRIDE;
diff --git a/svx/inc/sdr/properties/measureproperties.hxx b/svx/inc/sdr/properties/measureproperties.hxx
index 3eeca28a..b253c30 100644
--- a/svx/inc/sdr/properties/measureproperties.hxx
+++ b/svx/inc/sdr/properties/measureproperties.hxx
@@ -32,7 +32,7 @@ namespace sdr
         {
         protected:
             // create a new itemset
-            virtual SfxItemSet& CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
+            virtual SfxItemSet* CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
 
             // react on ItemSet changes
             virtual void ItemSetChanged(const SfxItemSet& rSet) SAL_OVERRIDE;
diff --git a/svx/inc/sdr/properties/pageproperties.hxx b/svx/inc/sdr/properties/pageproperties.hxx
index e221c0c..268aed4 100644
--- a/svx/inc/sdr/properties/pageproperties.hxx
+++ b/svx/inc/sdr/properties/pageproperties.hxx
@@ -32,7 +32,7 @@ namespace sdr
         {
         protected:
             // create a new object specific itemset with object specific ranges.
-            virtual SfxItemSet& CreateObjectSpecificItemSet(SfxItemPool& pPool) SAL_OVERRIDE;
+            virtual SfxItemSet* CreateObjectSpecificItemSet(SfxItemPool& pPool) SAL_OVERRIDE;
 
             // Do the ItemChange, may do special handling
             virtual void ItemChange(const sal_uInt16 nWhich, const SfxPoolItem* pNewItem = 0) SAL_OVERRIDE;
diff --git a/svx/source/sdr/properties/attributeproperties.cxx b/svx/source/sdr/properties/attributeproperties.cxx
index 2173841..fd0a114 100644
--- a/svx/source/sdr/properties/attributeproperties.cxx
+++ b/svx/source/sdr/properties/attributeproperties.cxx
@@ -112,9 +112,9 @@ namespace sdr
         }
 
         // create a new itemset
-        SfxItemSet& AttributeProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
+        SfxItemSet* AttributeProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
         {
-            return *(new SfxItemSet(rPool,
+            return new SfxItemSet(rPool,
 
                 // ranges from SdrAttrObj
                 SDRATTR_START, SDRATTR_SHADOW_LAST,
@@ -122,7 +122,7 @@ namespace sdr
                 SDRATTR_TEXTDIRECTION, SDRATTR_TEXTDIRECTION,
 
                 // end
-                0, 0));
+                0, 0);
         }
 
         AttributeProperties::AttributeProperties(SdrObject& rObj)
@@ -421,7 +421,7 @@ namespace sdr
                                 pItemSet = pItemSet->GetParent();
                             }
 
-                            SfxItemSet* pNewSet = &CreateObjectSpecificItemSet(pNewModel->GetItemPool());
+                            SfxItemSet* pNewSet = CreateObjectSpecificItemSet(pNewModel->GetItemPool());
 
                             std::vector<const SfxItemSet*>::reverse_iterator riter;
                             for (riter = aSetList.rbegin(); riter != aSetList.rend(); ++riter)
diff --git a/svx/source/sdr/properties/captionproperties.cxx b/svx/source/sdr/properties/captionproperties.cxx
index b0900af..f828fdd 100644
--- a/svx/source/sdr/properties/captionproperties.cxx
+++ b/svx/source/sdr/properties/captionproperties.cxx
@@ -31,9 +31,9 @@ namespace sdr
     namespace properties
     {
         // create a new itemset
-        SfxItemSet& CaptionProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
+        SfxItemSet* CaptionProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
         {
-            return *(new SfxItemSet(rPool,
+            return new SfxItemSet(rPool,
 
                 // range from SdrAttrObj
                 SDRATTR_START, SDRATTR_SHADOW_LAST,
@@ -47,7 +47,7 @@ namespace sdr
                 EE_ITEMS_START, EE_ITEMS_END,
 
                 // end
-                0, 0));
+                0, 0);
         }
 
         CaptionProperties::CaptionProperties(SdrObject& rObj)
diff --git a/svx/source/sdr/properties/circleproperties.cxx b/svx/source/sdr/properties/circleproperties.cxx
index 701cce5..de68507 100644
--- a/svx/source/sdr/properties/circleproperties.cxx
+++ b/svx/source/sdr/properties/circleproperties.cxx
@@ -33,9 +33,9 @@ namespace sdr
     namespace properties
     {
         // create a new itemset
-        SfxItemSet& CircleProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
+        SfxItemSet* CircleProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
         {
-            return *(new SfxItemSet(rPool,
+            return new SfxItemSet(rPool,
 
                 // range from SdrAttrObj
                 SDRATTR_START, SDRATTR_SHADOW_LAST,
@@ -49,7 +49,7 @@ namespace sdr
                 EE_ITEMS_START, EE_ITEMS_END,
 
                 // end
-                0, 0));
+                0, 0);
         }
 
         CircleProperties::CircleProperties(SdrObject& rObj)
diff --git a/svx/source/sdr/properties/connectorproperties.cxx b/svx/source/sdr/properties/connectorproperties.cxx
index a65c245..62c8ab3 100644
--- a/svx/source/sdr/properties/connectorproperties.cxx
+++ b/svx/source/sdr/properties/connectorproperties.cxx
@@ -31,9 +31,9 @@ namespace sdr
     namespace properties
     {
         // create a new itemset
-        SfxItemSet& ConnectorProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
+        SfxItemSet* ConnectorProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
         {
-            return *(new SfxItemSet(rPool,
+            return new SfxItemSet(rPool,
 
                 // range from SdrAttrObj
                 SDRATTR_START, SDRATTR_SHADOW_LAST,
@@ -47,7 +47,7 @@ namespace sdr
                 EE_ITEMS_START, EE_ITEMS_END,
 
                 // end
-                0, 0));
+                0, 0);
         }
 
         ConnectorProperties::ConnectorProperties(SdrObject& rObj)
diff --git a/svx/source/sdr/properties/customshapeproperties.cxx b/svx/source/sdr/properties/customshapeproperties.cxx
index afb4b68..2c8b111 100644
--- a/svx/source/sdr/properties/customshapeproperties.cxx
+++ b/svx/source/sdr/properties/customshapeproperties.cxx
@@ -60,9 +60,9 @@ namespace sdr
             }
         }
 
-        SfxItemSet& CustomShapeProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
+        SfxItemSet* CustomShapeProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
         {
-            return *(new SfxItemSet(rPool,
+            return new SfxItemSet(rPool,
 
                 // ranges from SdrAttrObj
                 SDRATTR_START, SDRATTR_SHADOW_LAST,
@@ -82,7 +82,7 @@ namespace sdr
                 EE_ITEMS_START, EE_ITEMS_END,
 
                 // end
-                0, 0));
+                0, 0);
         }
 
         bool CustomShapeProperties::AllowItemChange(const sal_uInt16 nWhich, const SfxPoolItem* pNewItem ) const
diff --git a/svx/source/sdr/properties/defaultproperties.cxx b/svx/source/sdr/properties/defaultproperties.cxx
index 08ff3d3..79ca6e5 100644
--- a/svx/source/sdr/properties/defaultproperties.cxx
+++ b/svx/source/sdr/properties/defaultproperties.cxx
@@ -34,10 +34,10 @@ namespace sdr
 {
     namespace properties
     {
-        SfxItemSet& DefaultProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
+        SfxItemSet* DefaultProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
         {
             // Basic implementation; Basic object has NO attributes
-            return *(new SfxItemSet(rPool));
+            return new SfxItemSet(rPool);
         }
 
         DefaultProperties::DefaultProperties(SdrObject& rObj)
@@ -81,7 +81,7 @@ namespace sdr
         {
             if(!mpItemSet)
             {
-                ((DefaultProperties*)this)->mpItemSet = &(((DefaultProperties*)this)->CreateObjectSpecificItemSet(GetSdrObject().GetObjectItemPool()));
+                ((DefaultProperties*)this)->mpItemSet = ((DefaultProperties*)this)->CreateObjectSpecificItemSet(GetSdrObject().GetObjectItemPool());
                 ((DefaultProperties*)this)->ForceDefaultAttributes();
             }
 
diff --git a/svx/source/sdr/properties/e3dproperties.cxx b/svx/source/sdr/properties/e3dproperties.cxx
index 0dc7f00..7b337218 100644
--- a/svx/source/sdr/properties/e3dproperties.cxx
+++ b/svx/source/sdr/properties/e3dproperties.cxx
@@ -29,9 +29,9 @@ namespace sdr
     namespace properties
     {
         // create a new itemset
-        SfxItemSet& E3dProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
+        SfxItemSet* E3dProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
         {
-            return *(new SfxItemSet(rPool,
+            return new SfxItemSet(rPool,
 
                 // ranges from SdrAttrObj
                 SDRATTR_START, SDRATTR_SHADOW_LAST,
@@ -42,7 +42,7 @@ namespace sdr
                 SDRATTR_3D_FIRST, SDRATTR_3D_LAST,
 
                 // end
-                0, 0));
+                0, 0);
         }
 
         E3dProperties::E3dProperties(SdrObject& rObj)
diff --git a/svx/source/sdr/properties/emptyproperties.cxx b/svx/source/sdr/properties/emptyproperties.cxx
index a13036c..ad0a644 100644
--- a/svx/source/sdr/properties/emptyproperties.cxx
+++ b/svx/source/sdr/properties/emptyproperties.cxx
@@ -31,11 +31,11 @@ namespace sdr
     namespace properties
     {
         // create a new itemset
-        SfxItemSet& EmptyProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
+        SfxItemSet* EmptyProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
         {
             // Basic implementation; Basic object has NO attributes
             DBG_ASSERT(false, "EmptyProperties::CreateObjectSpecificItemSet() should never be called");
-            return *(new SfxItemSet(rPool));
+            return new SfxItemSet(rPool);
         }
 
         EmptyProperties::EmptyProperties(SdrObject& rObj)
@@ -71,7 +71,7 @@ namespace sdr
         {
             if(!mpEmptyItemSet)
             {
-                ((EmptyProperties*)this)->mpEmptyItemSet = &(((EmptyProperties*)this)->CreateObjectSpecificItemSet(GetSdrObject().GetObjectItemPool()));
+                ((EmptyProperties*)this)->mpEmptyItemSet = ((EmptyProperties*)this)->CreateObjectSpecificItemSet(GetSdrObject().GetObjectItemPool());
             }
 
             DBG_ASSERT(mpEmptyItemSet, "Could not create an SfxItemSet(!)");
diff --git a/svx/source/sdr/properties/graphicproperties.cxx b/svx/source/sdr/properties/graphicproperties.cxx
index 6300f5f..65c4a8f 100644
--- a/svx/source/sdr/properties/graphicproperties.cxx
+++ b/svx/source/sdr/properties/graphicproperties.cxx
@@ -32,9 +32,9 @@ namespace sdr
     namespace properties
     {
         // create a new itemset
-        SfxItemSet& GraphicProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
+        SfxItemSet* GraphicProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
         {
-            return *(new SfxItemSet(rPool,
+            return new SfxItemSet(rPool,
 
                 // range from SdrAttrObj
                 SDRATTR_START, SDRATTR_SHADOW_LAST,
@@ -48,7 +48,7 @@ namespace sdr
                 EE_ITEMS_START, EE_ITEMS_END,
 
                 // end
-                0, 0));
+                0, 0);
         }
 
         GraphicProperties::GraphicProperties(SdrObject& rObj)
diff --git a/svx/source/sdr/properties/groupproperties.cxx b/svx/source/sdr/properties/groupproperties.cxx
index f49eb5f..f2802da 100644
--- a/svx/source/sdr/properties/groupproperties.cxx
+++ b/svx/source/sdr/properties/groupproperties.cxx
@@ -33,12 +33,12 @@ namespace sdr
     namespace properties
     {
         // create a new itemset
-        SfxItemSet& GroupProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
+        SfxItemSet* GroupProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
         {
             // Groups have in principle no ItemSet. To support methods like
             // GetMergedItemSet() the local one is used. Thus, all items in the pool
             // may be used and a pool itemset is created.
-            return *(new SfxItemSet(rPool));
+            return new SfxItemSet(rPool);
         }
 
         GroupProperties::GroupProperties(SdrObject& rObj)
diff --git a/svx/source/sdr/properties/measureproperties.cxx b/svx/source/sdr/properties/measureproperties.cxx
index 033464b2..bf875c4 100644
--- a/svx/source/sdr/properties/measureproperties.cxx
+++ b/svx/source/sdr/properties/measureproperties.cxx
@@ -38,9 +38,9 @@ namespace sdr
     namespace properties
     {
         // create a new itemset
-        SfxItemSet& MeasureProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
+        SfxItemSet* MeasureProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
         {
-            return *(new SfxItemSet(rPool,
+            return new SfxItemSet(rPool,
 
                 // range from SdrAttrObj
                 SDRATTR_START, SDRATTR_SHADOW_LAST,
@@ -54,7 +54,7 @@ namespace sdr
                 EE_ITEMS_START, EE_ITEMS_END,
 
                 // end
-                0, 0));
+                0, 0);
         }
 
         MeasureProperties::MeasureProperties(SdrObject& rObj)
diff --git a/svx/source/sdr/properties/pageproperties.cxx b/svx/source/sdr/properties/pageproperties.cxx
index fd8a71d..bb09f9e 100644
--- a/svx/source/sdr/properties/pageproperties.cxx
+++ b/svx/source/sdr/properties/pageproperties.cxx
@@ -29,10 +29,10 @@ namespace sdr
     namespace properties
     {
         // create a new itemset
-        SfxItemSet& PageProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
+        SfxItemSet* PageProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
         {
             // overloaded to legally return a valid ItemSet
-            return *(new SfxItemSet(rPool));
+            return new SfxItemSet(rPool);
         }
 
         PageProperties::PageProperties(SdrObject& rObj)
@@ -60,7 +60,7 @@ namespace sdr
         {
             if(!mpEmptyItemSet)
             {
-                ((PageProperties*)this)->mpEmptyItemSet = &(((PageProperties*)this)->CreateObjectSpecificItemSet(GetSdrObject().GetObjectItemPool()));
+                ((PageProperties*)this)->mpEmptyItemSet = ((PageProperties*)this)->CreateObjectSpecificItemSet(GetSdrObject().GetObjectItemPool());
             }
 
             DBG_ASSERT(mpEmptyItemSet, "Could not create an SfxItemSet(!)");
diff --git a/svx/source/sdr/properties/textproperties.cxx b/svx/source/sdr/properties/textproperties.cxx
index bd857b6..78e8cea 100644
--- a/svx/source/sdr/properties/textproperties.cxx
+++ b/svx/source/sdr/properties/textproperties.cxx
@@ -42,9 +42,9 @@ namespace sdr
 {
     namespace properties
     {
-        SfxItemSet& TextProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
+        SfxItemSet* TextProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
         {
-            return *(new SfxItemSet(rPool,
+            return new SfxItemSet(rPool,
 
                 // range from SdrAttrObj
                 SDRATTR_START, SDRATTR_SHADOW_LAST,
@@ -55,7 +55,7 @@ namespace sdr
                 EE_ITEMS_START, EE_ITEMS_END,
 
                 // end
-                0, 0));
+                0, 0);
         }
 
         TextProperties::TextProperties(SdrObject& rObj)
diff --git a/svx/source/table/cell.cxx b/svx/source/table/cell.cxx
index 5fd38f9..a3dbc11 100644
--- a/svx/source/table/cell.cxx
+++ b/svx/source/table/cell.cxx
@@ -147,7 +147,7 @@ namespace sdr
         {
         protected:
             // create a new itemset
-            SfxItemSet& CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
+            SfxItemSet* CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
 
             const svx::ITextProvider& getTextProvider() const SAL_OVERRIDE;
 
@@ -179,9 +179,9 @@ namespace sdr
         };
 
         // create a new itemset
-        SfxItemSet& CellProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
+        SfxItemSet* CellProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
         {
-            return *(new SfxItemSet(rPool,
+            return new SfxItemSet(rPool,
 
                 // range from SdrAttrObj
                 SDRATTR_START, SDRATTR_SHADOW_LAST,
@@ -195,7 +195,7 @@ namespace sdr
                 EE_ITEMS_START, EE_ITEMS_END,
 
                 // end
-                0, 0));
+                0, 0);
         }
 
         const svx::ITextProvider& CellProperties::getTextProvider() const
diff --git a/svx/source/table/svdotable.cxx b/svx/source/table/svdotable.cxx
index fb66230..0a93026 100644
--- a/svx/source/table/svdotable.cxx
+++ b/svx/source/table/svdotable.cxx
@@ -85,7 +85,7 @@ class TableProperties : public TextProperties
 {
 protected:
     // create a new itemset
-    SfxItemSet& CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
+    SfxItemSet* CreateObjectSpecificItemSet(SfxItemPool& rPool) SAL_OVERRIDE;
 
 public:
     // basic constructor
@@ -131,9 +131,9 @@ void TableProperties::ItemChange(const sal_uInt16 nWhich, const SfxPoolItem* pNe
 }
 
 // create a new itemset
-SfxItemSet& TableProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
+SfxItemSet* TableProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
 {
-    return *(new SfxItemSet(rPool,
+    return new SfxItemSet(rPool,
 
         // range from SdrAttrObj
         SDRATTR_START, SDRATTR_SHADOW_LAST,
@@ -147,7 +147,7 @@ SfxItemSet& TableProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
         EE_ITEMS_START, EE_ITEMS_END,
 
         // end
-        0, 0));
+        0, 0);
 }
 
 class TableObjectGeoData : public SdrTextObjGeoData


More information about the Libreoffice-commits mailing list