diff options
-rw-r--r-- | sc/source/ui/inc/docsh.hxx | 6 | ||||
-rw-r--r-- | sc/source/ui/inc/servobj.hxx | 3 | ||||
-rw-r--r-- | sd/source/ui/func/fuprlout.cxx | 5 | ||||
-rw-r--r-- | sd/source/ui/view/drviews3.cxx | 7 | ||||
-rw-r--r-- | sd/source/ui/view/drviews9.cxx | 10 | ||||
-rw-r--r-- | sd/source/ui/view/sdview.cxx | 5 | ||||
-rw-r--r-- | sd/source/ui/view/sdview2.cxx | 9 | ||||
-rw-r--r-- | sd/source/ui/view/viewshel.cxx | 5 | ||||
-rw-r--r-- | sot/Package_inc.mk | 1 | ||||
-rw-r--r-- | sot/inc/sot/factory.hxx | 1 | ||||
-rw-r--r-- | sot/inc/sot/object.hxx | 6 | ||||
-rw-r--r-- | sot/inc/sot/sotref.hxx | 63 | ||||
-rw-r--r-- | sot/inc/sot/storage.hxx | 8 | ||||
-rw-r--r-- | sot/source/base/factory.cxx | 29 | ||||
-rw-r--r-- | sot/source/base/object.cxx | 13 | ||||
-rw-r--r-- | starmath/inc/document.hxx | 1 | ||||
-rw-r--r-- | starmath/qa/cppunit/test_nodetotextvisitors.cxx | 4 | ||||
-rw-r--r-- | starmath/qa/cppunit/test_starmath.cxx | 4 | ||||
-rw-r--r-- | sw/qa/core/filters-test.cxx | 4 | ||||
-rw-r--r-- | sw/qa/core/macros-test.cxx | 4 | ||||
-rw-r--r-- | sw/qa/core/swdoc-test.cxx | 4 | ||||
-rwxr-xr-x | unusedcode.easy | 1 |
22 files changed, 18 insertions, 175 deletions
diff --git a/sc/source/ui/inc/docsh.hxx b/sc/source/ui/inc/docsh.hxx index 1efff933c57f..2e57e7471a30 100644 --- a/sc/source/ui/inc/docsh.hxx +++ b/sc/source/ui/inc/docsh.hxx @@ -48,8 +48,6 @@ #include <boost/unordered_map.hpp> #include <cppuhelper/implbase1.hxx> -#include <sot/sotref.hxx> - class ScEditEngineDefaulter; class SfxStyleSheetBasePool; class SfxStyleSheetHint; @@ -448,8 +446,8 @@ public: void UpdateAcceptChangesDialog(); -SO2_DECL_REF(ScDocShell) -SO2_IMPL_REF(ScDocShell) +SV_DECL_REF(ScDocShell) +SV_IMPL_REF(ScDocShell) /** Create before modifications of the document and then destroy. diff --git a/sc/source/ui/inc/servobj.hxx b/sc/source/ui/inc/servobj.hxx index b0bb345de3e9..4e205db255ef 100644 --- a/sc/source/ui/inc/servobj.hxx +++ b/sc/source/ui/inc/servobj.hxx @@ -71,9 +71,6 @@ public: void EndListeningAll(); }; -//SO2_DECL_REF( ScServerObject ) - - #endif /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sd/source/ui/func/fuprlout.cxx b/sd/source/ui/func/fuprlout.cxx index 5641f1a12574..2d94c3561953 100644 --- a/sd/source/ui/func/fuprlout.cxx +++ b/sd/source/ui/func/fuprlout.cxx @@ -55,11 +55,6 @@ namespace sd { -#ifndef SO2_DECL_SVSTORAGE_DEFINED -#define SO2_DECL_SVSTORAGE_DEFINED -SO2_DECL_REF(SvStorage) -#endif - TYPEINIT1( FuPresentationLayout, FuPoor ); #define DOCUMENT_TOKEN (sal_Unicode('#')) diff --git a/sd/source/ui/view/drviews3.cxx b/sd/source/ui/view/drviews3.cxx index 5b0fc2e0d2e6..17fd4e79e155 100644 --- a/sd/source/ui/view/drviews3.cxx +++ b/sd/source/ui/view/drviews3.cxx @@ -99,13 +99,6 @@ using ::com::sun::star::frame::XController; namespace sd { -#ifndef SO2_DECL_SVINPLACEOBJECT_DEFINED -#define SO2_DECL_SVINPLACEOBJECT_DEFINED -SO2_DECL_REF(SvInPlaceObject) -#endif - - - /************************************************************************* |* |* SfxRequests fuer Controller bearbeiten diff --git a/sd/source/ui/view/drviews9.cxx b/sd/source/ui/view/drviews9.cxx index 8763aa8c47fc..59eba374e579 100644 --- a/sd/source/ui/view/drviews9.cxx +++ b/sd/source/ui/view/drviews9.cxx @@ -68,16 +68,6 @@ namespace sd { -#ifndef SO2_DECL_SVINPLACEOBJECT_DEFINED -#define SO2_DECL_SVINPLACEOBJECT_DEFINED -SO2_DECL_REF(SvInPlaceObject) -#endif -#ifndef SO2_DECL_SVSTORAGE_DEFINED -#define SO2_DECL_SVSTORAGE_DEFINED -SO2_DECL_REF(SvStorage) -#endif - - /************************************************************************* |* |* SfxRequests fuer Gallery bearbeiten diff --git a/sd/source/ui/view/sdview.cxx b/sd/source/ui/view/sdview.cxx index e43d1756a7be..0912a8a808bb 100644 --- a/sd/source/ui/view/sdview.cxx +++ b/sd/source/ui/view/sdview.cxx @@ -91,11 +91,6 @@ using namespace com::sun::star; using namespace com::sun::star::uno; namespace sd { -#ifndef SO2_DECL_SVINPLACEOBJECT_DEFINED -#define SO2_DECL_SVINPLACEOBJECT_DEFINED -SO2_DECL_REF(SvInPlaceObject) -#endif - TYPEINIT1(View, FmFormView); /************************************************************************* diff --git a/sd/source/ui/view/sdview2.cxx b/sd/source/ui/view/sdview2.cxx index 20a1474ff618..e664c01473e2 100644 --- a/sd/source/ui/view/sdview2.cxx +++ b/sd/source/ui/view/sdview2.cxx @@ -68,15 +68,6 @@ namespace sd { -#ifndef SO2_DECL_SVINPLACEOBJECT_DEFINED -#define SO2_DECL_SVINPLACEOBJECT_DEFINED -SO2_DECL_REF(SvInPlaceObject) -#endif -#ifndef SO2_DECL_SVSTORAGE_DEFINED -#define SO2_DECL_SVSTORAGE_DEFINED -SO2_DECL_REF(SvStorage) -#endif - using namespace ::com::sun::star; // ------------------------ diff --git a/sd/source/ui/view/viewshel.cxx b/sd/source/ui/view/viewshel.cxx index bcf57130f930..7c56eb5da919 100644 --- a/sd/source/ui/view/viewshel.cxx +++ b/sd/source/ui/view/viewshel.cxx @@ -84,11 +84,6 @@ #include "Window.hxx" #include "fupoor.hxx" -#ifndef SO2_DECL_SVINPLACEOBJECT_DEFINED -#define SO2_DECL_SVINPLACEOBJECT_DEFINED -SO2_DECL_REF(SvInPlaceObject) -#endif - namespace sd { namespace ui { namespace table { extern SfxShell* CreateTableObjectBar( ViewShell& rShell, ::sd::View* pView ); } } } diff --git a/sot/Package_inc.mk b/sot/Package_inc.mk index 371ab98ebbb9..4a0ff1613a07 100644 --- a/sot/Package_inc.mk +++ b/sot/Package_inc.mk @@ -26,7 +26,6 @@ $(eval $(call gb_Package_add_file,sot_inc,inc/sot/formats.hxx,sot/formats.hxx)) $(eval $(call gb_Package_add_file,sot_inc,inc/sot/object.hxx,sot/object.hxx)) $(eval $(call gb_Package_add_file,sot_inc,inc/sot/sotdata.hxx,sot/sotdata.hxx)) $(eval $(call gb_Package_add_file,sot_inc,inc/sot/sotdllapi.h,sot/sotdllapi.h)) -$(eval $(call gb_Package_add_file,sot_inc,inc/sot/sotref.hxx,sot/sotref.hxx)) $(eval $(call gb_Package_add_file,sot_inc,inc/sot/stg.hxx,sot/stg.hxx)) $(eval $(call gb_Package_add_file,sot_inc,inc/sot/storage.hxx,sot/storage.hxx)) $(eval $(call gb_Package_add_file,sot_inc,inc/sot/storinfo.hxx,sot/storinfo.hxx)) diff --git a/sot/inc/sot/factory.hxx b/sot/inc/sot/factory.hxx index b62c97f072fc..726b24382756 100644 --- a/sot/inc/sot/factory.hxx +++ b/sot/inc/sot/factory.hxx @@ -57,7 +57,6 @@ public: void PutSuperClass( const SotFactory * ); virtual void * CreateInstance( SotObject ** ppObj = NULL ) const; - void * CastAndAddRef( SotObject * ) const; sal_Bool Is( const SotFactory * pSuperClass ) const; const SotFactory * GetSuper( sal_uInt16 nPos ) const diff --git a/sot/inc/sot/object.hxx b/sot/inc/sot/object.hxx index 81d3d3739dee..b1b9316afcd3 100644 --- a/sot/inc/sot/object.hxx +++ b/sot/inc/sot/object.hxx @@ -20,9 +20,9 @@ #ifndef _SOT_OBJECT_HXX #define _SOT_OBJECT_HXX -#include <sot/sotref.hxx> #include <sot/sotdata.hxx> #include <tools/globname.hxx> +#include <tools/ref.hxx> #include "sot/sotdllapi.h" /************************************************************************* @@ -287,8 +287,6 @@ public: sal_Bool Owner() const { return bOwner; } - void* CastAndAddRef( const SotFactory * pFact ); - sal_uInt16 GetOwnerLockCount() const { return nOwnerLockCount; } void OwnerLock( sal_Bool bLock ); @@ -302,7 +300,7 @@ private: }; //==================class SotObjectRef====================================== -SV_IMPL_REF(SotObject) +SV_DECL_IMPL_REF(SotObject) #endif // _IFACE_HXX diff --git a/sot/inc/sot/sotref.hxx b/sot/inc/sot/sotref.hxx deleted file mode 100644 index 4465909c3659..000000000000 --- a/sot/inc/sot/sotref.hxx +++ /dev/null @@ -1,63 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -/* - * This file is part of the LibreOffice project. - * - * This Source Code Form is subject to the terms of the Mozilla Public - * License, v. 2.0. If a copy of the MPL was not distributed with this - * file, You can obtain one at http://mozilla.org/MPL/2.0/. - * - * This file incorporates work covered by the following license notice: - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed - * with this work for additional information regarding copyright - * ownership. The ASF licenses this file to you under the Apache - * License, Version 2.0 (the "License"); you may not use this file - * except in compliance with the License. You may obtain a copy of - * the License at http://www.apache.org/licenses/LICENSE-2.0 . - */ - -#ifndef _SOT_SOTREF_HXX -#define _SOT_SOTREF_HXX - -#include <tools/ref.hxx> - -//======================================================================== -#ifndef SVT_DECL_SOTOBJECT_DEFINED -#define SVT_DECL_SOTOBJECT_DEFINED -class SotObject; -class SotObjectRef -{ - PRV_SV_DECL_REF(SotObject) -}; -#endif - -//======================================================================== -#define SO2_DECL_REF(ClassName) \ -class ClassName; \ -class ClassName##Ref \ -{ \ - PRV_SV_DECL_REF(ClassName) \ - inline ClassName##Ref( const SotObjectRef & ); \ - inline ClassName##Ref( SotObject * pObjP ); \ -}; - -#define SO2_IMPL_REF(ClassName) \ -SV_IMPL_REF(ClassName) \ -inline ClassName##Ref::ClassName##Ref( const SotObjectRef & r ) \ -{ \ - pObj = (ClassName *)ClassName::ClassFactory()->CastAndAddRef( &r ); \ -} \ -inline ClassName##Ref::ClassName##Ref( SotObject * pObjP ) \ -{ \ - pObj = (ClassName *)ClassName::ClassFactory()->CastAndAddRef( pObjP );\ -} - - -#define SO2_DECL_IMPL_REF(ClassName) \ - SO2_DECL_REF(ClassName) \ - SO2_IMPL_REF(ClassName) - -#endif // _SO2REF_HXX - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sot/inc/sot/storage.hxx b/sot/inc/sot/storage.hxx index 3a01028df107..abe1d831fa08 100644 --- a/sot/inc/sot/storage.hxx +++ b/sot/inc/sot/storage.hxx @@ -80,9 +80,9 @@ public: #ifndef SOT_DECL_SOTSTORAGESTREAM_DEFINED #define SOT_DECL_SOTSTORAGESTREAM_DEFINED -SO2_DECL_REF(SotStorageStream) +SV_DECL_REF(SotStorageStream) #endif -SO2_IMPL_REF(SotStorageStream) +SV_IMPL_REF(SotStorageStream) namespace ucbhelper { @@ -210,9 +210,9 @@ public: #ifndef SOT_DECL_SOTSTORAGE_DEFINED #define SOT_DECL_SOTSTORAGE_DEFINED -SO2_DECL_REF(SotStorage) +SV_DECL_REF(SotStorage) #endif -SO2_IMPL_REF(SotStorage) +SV_IMPL_REF(SotStorage) #define SvStorage SotStorage #define SvStorageRef SotStorageRef diff --git a/sot/source/base/factory.cxx b/sot/source/base/factory.cxx index 783568308912..28c285027cd7 100644 --- a/sot/source/base/factory.cxx +++ b/sot/source/base/factory.cxx @@ -195,35 +195,6 @@ void * SotFactory::CreateInstance( SotObject ** ppObj ) const return pCreateFunc( ppObj ); } -//========================================================================= -void * SotFactory::CastAndAddRef -( - SotObject * pObj /* Das Objekt von dem der Typ gepr"uft wird. */ -) const -/* [Beschreibung] - - Ist eine Optimierung, damit die Ref-Klassen k"urzer implementiert - werden k"onnen. pObj wird auf den Typ der Factory gecastet. - In c++ (wenn es immer erlaubt w"are) w"urde der void * wie im - Beispiel gebildet. - Factory der Klasse SvPersist. - void * p = (void *)(SvPersist *)pObj; - - [R"uckgabewert] - - void *, NULL, pObj war NULL oder das Objekt war nicht vom Typ - der Factory. - Ansonsten wird pObj zuerst auf den Typ der Factory - gecastet und dann auf void *. - - [Querverweise] - - <SotObject::CastAndAddRef> -*/ -{ - return pObj ? pObj->CastAndAddRef( this ) : NULL; -} - /************************************************************************* |* SotFactory::Is() |* diff --git a/sot/source/base/object.cxx b/sot/source/base/object.cxx index 3bf6d92bda14..b69d2602d356 100644 --- a/sot/source/base/object.cxx +++ b/sot/source/base/object.cxx @@ -72,19 +72,6 @@ IUnknown * SotObject::GetInterface( const SvGlobalName & ) return NULL; } -/************************************************************************* -|* SotObject::CastAndAddRef() -|* -|* Beschreibung -*************************************************************************/ -void* SotObject::CastAndAddRef( const SotFactory * pFact ) -{ - void * pCast = Cast( pFact ); - if( pCast ) - AddRef(); - return pCast; -} - //========================================================================= void SotObject::OwnerLock ( diff --git a/starmath/inc/document.hxx b/starmath/inc/document.hxx index 638801371f19..b5a561d0f85a 100644 --- a/starmath/inc/document.hxx +++ b/starmath/inc/document.hxx @@ -26,7 +26,6 @@ #include <rtl/strbuf.hxx> #include <sfx2/docfac.hxx> #include <sfx2/objsh.hxx> -#include <sot/sotref.hxx> #include <sot/storage.hxx> #include <svl/lstner.hxx> #include <vcl/jobset.hxx> diff --git a/starmath/qa/cppunit/test_nodetotextvisitors.cxx b/starmath/qa/cppunit/test_nodetotextvisitors.cxx index 375b73300b2c..49d9d888f5f2 100644 --- a/starmath/qa/cppunit/test_nodetotextvisitors.cxx +++ b/starmath/qa/cppunit/test_nodetotextvisitors.cxx @@ -65,8 +65,8 @@ struct assertion_traits<String> }; } -SO2_DECL_REF(SmDocShell) -SO2_IMPL_REF(SmDocShell) +SV_DECL_REF(SmDocShell) +SV_IMPL_REF(SmDocShell) class TestOutputDevice : public OutputDevice { diff --git a/starmath/qa/cppunit/test_starmath.cxx b/starmath/qa/cppunit/test_starmath.cxx index 3e39f5d42123..3ebbd61f39a6 100644 --- a/starmath/qa/cppunit/test_starmath.cxx +++ b/starmath/qa/cppunit/test_starmath.cxx @@ -55,8 +55,8 @@ #include <sfx2/zoomitem.hxx> -SO2_DECL_REF(SmDocShell) -SO2_IMPL_REF(SmDocShell) +SV_DECL_REF(SmDocShell) +SV_IMPL_REF(SmDocShell) using namespace ::com::sun::star; diff --git a/sw/qa/core/filters-test.cxx b/sw/qa/core/filters-test.cxx index ed2e3efd336e..9905b2350181 100644 --- a/sw/qa/core/filters-test.cxx +++ b/sw/qa/core/filters-test.cxx @@ -50,8 +50,8 @@ #include "shellres.hxx" #include "docufld.hxx" -SO2_DECL_REF(SwDocShell) -SO2_IMPL_REF(SwDocShell) +SV_DECL_REF(SwDocShell) +SV_IMPL_REF(SwDocShell) using namespace ::com::sun::star; diff --git a/sw/qa/core/macros-test.cxx b/sw/qa/core/macros-test.cxx index 3f9262eb486c..7d7197776554 100644 --- a/sw/qa/core/macros-test.cxx +++ b/sw/qa/core/macros-test.cxx @@ -50,8 +50,8 @@ #include "docsh.hxx" -SO2_DECL_REF(SwDocShell) -SO2_IMPL_REF(SwDocShell) +SV_DECL_REF(SwDocShell) +SV_IMPL_REF(SwDocShell) using namespace ::com::sun::star; using namespace ::com::sun::star::uno; diff --git a/sw/qa/core/swdoc-test.cxx b/sw/qa/core/swdoc-test.cxx index 2f1bf8668824..de9828e84bfb 100644 --- a/sw/qa/core/swdoc-test.cxx +++ b/sw/qa/core/swdoc-test.cxx @@ -67,8 +67,8 @@ #include "modeltoviewhelper.hxx" #include "scriptinfo.hxx" -SO2_DECL_REF(SwDocShell) -SO2_IMPL_REF(SwDocShell) +SV_DECL_REF(SwDocShell) +SV_IMPL_REF(SwDocShell) using namespace ::com::sun::star; diff --git a/unusedcode.easy b/unusedcode.easy index bedbdf7b2c6b..ee7ea3ef2d3e 100755 --- a/unusedcode.easy +++ b/unusedcode.easy @@ -13,7 +13,6 @@ ScVbaFormat<ooo::vba::excel::XRange>::setNumberFormat(com::sun::star::lang::Loca ScVbaFormat<ooo::vba::excel::XStyle>::getAddIndent() ScVbaFormat<ooo::vba::excel::XStyle>::setAddIndent(com::sun::star::uno::Any const&) ScVbaFormat<ooo::vba::excel::XStyle>::setNumberFormat(com::sun::star::lang::Locale, rtl::OUString const&) -SotFactory::CastAndAddRef(SotObject*) const String::String(unsigned short) SvListView::GetModel() const SvTreeList::GetChildIterators(SvTreeListEntry const*) const |