basic/inc/basic/vbahelper.hxx | 16 --------- basic/source/basmgr/vbahelper.cxx | 19 ----------- basic/source/inc/namecont.hxx | 5 -- basic/source/uno/namecont.cxx | 64 -------------------------------------- unusedcode.easy | 2 - 5 files changed, 106 deletions(-)
New commits: commit 99ff0ab0b2f4f6b8718b4dfa1bfc2c598ac25c4c Author: Elton Chung <el...@layerjet.com> Date: Mon Mar 5 23:30:31 2012 +0800 Remove unused code from basic diff --git a/basic/inc/basic/vbahelper.hxx b/basic/inc/basic/vbahelper.hxx index 4655897..8530c95 100644 --- a/basic/inc/basic/vbahelper.hxx +++ b/basic/inc/basic/vbahelper.hxx @@ -100,22 +100,6 @@ BASIC_DLLPUBLIC void registerCurrentDirectory( // ============================================================================ -/** Returns the working directory of the application the passed document - belongs to. - - @param rxModel - A document model determining the type of the application whose working - directory is querried. - - @return - The working directory of the specified application, or an empty string - on error (e.g. if the passed document reference is empty). - */ -BASIC_DLLPUBLIC ::rtl::OUString getCurrentDirectory( - const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModel >& rxModel ); - -// ============================================================================ - } // namespace vba } // namespace basic diff --git a/basic/source/basmgr/vbahelper.cxx b/basic/source/basmgr/vbahelper.cxx index 16e7222..b711a96 100644 --- a/basic/source/basmgr/vbahelper.cxx +++ b/basic/source/basmgr/vbahelper.cxx @@ -235,25 +235,6 @@ void registerCurrentDirectory( const uno::Reference< frame::XModel >& rxModel, c // ============================================================================ -::rtl::OUString getCurrentDirectory( const uno::Reference< frame::XModel >& rxModel ) -{ - ::rtl::OUString aPath; - CurrDirPool& rPool = StaticCurrDirPool::get(); - ::osl::MutexGuard aGuard( rPool.maMutex ); - try - { - uno::Reference< frame::XModuleManager > xModuleManager( lclCreateModuleManager(), uno::UNO_SET_THROW ); - ::rtl::OUString aIdentifier = xModuleManager->identify( rxModel ); - aPath = rPool.maCurrDirs[ aIdentifier ]; - } - catch(const uno::Exception& ) - { - } - return aPath; -} - -// ============================================================================ - } // namespace vba } // namespace basic diff --git a/basic/source/inc/namecont.hxx b/basic/source/inc/namecont.hxx index 8f585b5..833fc81 100644 --- a/basic/source/inc/namecont.hxx +++ b/basic/source/inc/namecont.hxx @@ -757,11 +757,6 @@ public: ScriptExtensionIterator( void ); rtl::OUString nextBasicOrDialogLibrary( bool& rbPureDialogLib ); -private: - com::sun::star::uno::Reference< com::sun::star::deployment::XPackage > implGetScriptPackageFromPackage - ( const com::sun::star::uno::Reference< com::sun::star::deployment::XPackage > xPackage, - bool& rbPureDialogLib ); - protected: com::sun::star::uno::Reference< com::sun::star::deployment::XPackage > implGetNextUserScriptPackage( bool& rbPureDialogLib ); diff --git a/basic/source/uno/namecont.cxx b/basic/source/uno/namecont.cxx index fbc52ea..f6544b5 100644 --- a/basic/source/uno/namecont.cxx +++ b/basic/source/uno/namecont.cxx @@ -3358,70 +3358,6 @@ Reference< deployment::XPackage > ScriptSubPackageIterator::implDetectScriptPack return xScriptPackage; } -Reference< deployment::XPackage > ScriptExtensionIterator::implGetScriptPackageFromPackage - ( const Reference< deployment::XPackage > xPackage, bool& rbPureDialogLib ) -{ - rbPureDialogLib = false; - - Reference< deployment::XPackage > xScriptPackage; - if( !xPackage.is() ) - return xScriptPackage; - - // Check if parent package is registered - beans::Optional< beans::Ambiguous<sal_Bool> > option( xPackage->isRegistered - ( Reference<task::XAbortChannel>(), Reference<ucb::XCommandEnvironment>() ) ); - bool bRegistered = false; - if( option.IsPresent ) - { - beans::Ambiguous<sal_Bool> const & reg = option.Value; - if( !reg.IsAmbiguous && reg.Value ) - bRegistered = true; - } - if( bRegistered ) - { - if( xPackage->isBundle() ) - { - Sequence< Reference< deployment::XPackage > > aPkgSeq = xPackage->getBundle - ( Reference<task::XAbortChannel>(), Reference<ucb::XCommandEnvironment>() ); - sal_Int32 nPkgCount = aPkgSeq.getLength(); - const Reference< deployment::XPackage >* pSeq = aPkgSeq.getConstArray(); - for( sal_Int32 iPkg = 0 ; iPkg < nPkgCount ; ++iPkg ) - { - const Reference< deployment::XPackage > xSubPkg = pSeq[ iPkg ]; - const Reference< deployment::XPackageTypeInfo > xPackageTypeInfo = xSubPkg->getPackageType(); - rtl::OUString aMediaType = xPackageTypeInfo->getMediaType(); - if( aMediaType.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(sBasicLibMediaType)) ) - { - xScriptPackage = xSubPkg; - break; - } - else if( aMediaType.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(sDialogLibMediaType)) ) - { - rbPureDialogLib = true; - xScriptPackage = xSubPkg; - break; - } - } - } - else - { - const Reference< deployment::XPackageTypeInfo > xPackageTypeInfo = xPackage->getPackageType(); - rtl::OUString aMediaType = xPackageTypeInfo->getMediaType(); - if( aMediaType.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(sBasicLibMediaType)) ) - { - xScriptPackage = xPackage; - } - else if( aMediaType.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(sDialogLibMediaType)) ) - { - rbPureDialogLib = true; - xScriptPackage = xPackage; - } - } - } - - return xScriptPackage; -} - Reference< deployment::XPackage > ScriptExtensionIterator::implGetNextUserScriptPackage ( bool& rbPureDialogLib ) { diff --git a/unusedcode.easy b/unusedcode.easy index a628a35..baa7669 100755 --- a/unusedcode.easy +++ b/unusedcode.easy @@ -491,8 +491,6 @@ basegfx::(anonymous namespace)::impAppendInterpolate(basegfx::B3DPolygon&, baseg basegfx::tools::equal(basegfx::B2DPolyPolygon const&, basegfx::B2DPolyPolygon const&, double const&) basegfx::tools::equal(basegfx::B3DPolyPolygon const&, basegfx::B3DPolyPolygon const&, double const&) basegfx::tools::getSignedArea(basegfx::B3DPolygon const&) -basic::ScriptExtensionIterator::implGetScriptPackageFromPackage(com::sun::star::uno::Reference<com::sun::star::deployment::XPackage>, bool&) -basic::vba::getCurrentDirectory(com::sun::star::uno::Reference<com::sun::star::frame::XModel> const&) binfilter::B3dEdgeEntryBucketMemArr::Insert(binfilter::B3dEdgeEntryBucketMemArr const*, unsigned short, unsigned short, unsigned short) binfilter::B3dEdgeEntryBucketMemArr::Replace(char const*&, unsigned short) binfilter::B3dEdgeEntryBucketMemArr::Replace(char const**, unsigned short, unsigned short) _______________________________________________ Libreoffice-commits mailing list Libreoffice-commits@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits