summaryrefslogtreecommitdiff
path: root/basic
diff options
context:
space:
mode:
authorElton Chung <elton@layerjet.com>2012-03-05 23:30:31 +0800
committerTor Lillqvist <tlillqvist@suse.com>2012-03-05 18:54:28 +0200
commit99ff0ab0b2f4f6b8718b4dfa1bfc2c598ac25c4c (patch)
treee44c329077e363927052694de5ad89106ec7fa9d /basic
parent8907a41bf8370446a1cc46c72b2841e5e3588806 (diff)
Remove unused code from basic
Diffstat (limited to 'basic')
-rw-r--r--basic/inc/basic/vbahelper.hxx16
-rw-r--r--basic/source/basmgr/vbahelper.cxx19
-rw-r--r--basic/source/inc/namecont.hxx5
-rw-r--r--basic/source/uno/namecont.cxx64
4 files changed, 0 insertions, 104 deletions
diff --git a/basic/inc/basic/vbahelper.hxx b/basic/inc/basic/vbahelper.hxx
index 4655897e400d..8530c954adff 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 16e7222c28d1..b711a9669a60 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 8f585b502502..833fc8105006 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 fbc52eaf176e..f6544b566eeb 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 )
{