ooo-build r13478 - trunk/patches/vba



Author: noelpwer
Date: Tue Aug  5 17:36:53 2008
New Revision: 13478
URL: http://svn.gnome.org/viewvc/ooo-build?rev=13478&view=rev

Log:
redo xml format for codenames/vba mode and module type


Modified:
   trunk/patches/vba/vbainfo-import-export-support.diff

Modified: trunk/patches/vba/vbainfo-import-export-support.diff
==============================================================================
--- trunk/patches/vba/vbainfo-import-export-support.diff	(original)
+++ trunk/patches/vba/vbainfo-import-export-support.diff	Tue Aug  5 17:36:53 2008
@@ -412,10 +412,82 @@
  }
  
 diff --git basic/source/uno/namecont.cxx basic/source/uno/namecont.cxx
-index 5c9c44b..41e189d 100644
+index 5c9c44b..912fd80 100644
 --- basic/source/uno/namecont.cxx
 +++ basic/source/uno/namecont.cxx
-@@ -110,6 +110,27 @@ static bool GbMigrationSuppressErrors = 
+@@ -1,4 +1,5 @@
+ /*************************************************************************
++			rLib.hModuleTypeDesc = 
+  *
+  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+  * 
+@@ -75,6 +76,7 @@
+ #endif
+ #include <cppuhelper/exc_hlp.hxx>
+ #include <basic/sbmod.hxx>
++#include "sbunoobj.hxx"
+ 
+ #ifndef _COM_SUN_STAR_SCRIPT_MODULEINFO_HPP_
+ #include <com/sun/star/script/ModuleInfo.hpp>
+@@ -104,12 +106,85 @@ using namespace osl;
+ 
+ using com::sun::star::uno::Reference;
+ 
++// #TODO move this to SfxLibrary ? probably we need to to gaurantee
++// consistency 
++::xmlscript::ObjectModuleDescHash lcl_getObjModDescHash( SfxLibrary& rLib )
++{
++	uno::Sequence< ::rtl::OUString > sModuleNames = rLib.getElementNames();
++	sal_Int32 nElem = sModuleNames.getLength();
++	::xmlscript::ObjectModuleDescHash hResult;
++	for ( sal_Int32 i = 0; i < nElem; ++i )
++	{
++		ModuleInfo mInfo;
++		rtl::OUString sCodeName( sModuleNames[ i ] );
++		if ( rLib.getByName( sCodeName ) >>= mInfo )
++		{
++			::xmlscript::ObjectModuleDesc aDesc;
++			aDesc.mnModuleType = mInfo.ModuleType;
++			switch ( mInfo.ModuleType )
++			{
++				case ModuleType::Form:
++					aDesc.msObjectName = sCodeName;
++					hResult[ sCodeName ] = aDesc;
++					break;
++				case ModuleType::Document:
++				{
++					Reference< XServiceInfo > xSI( mInfo.ModuleObject, UNO_QUERY );
++					if ( xSI.is() && xSI->supportsService( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "org.openoffice.excel.Workbook" ) ) ) )
++						aDesc.msObjectName = ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "ThisWorkbook" ) ); 
++					else
++					{
++						SbUnoObjectRef pSbUnoObject = new SbUnoObject( String(), uno::makeAny( mInfo.ModuleObject ) );
++						SbxVariable* pVar = pSbUnoObject->Find( String( RTL_CONSTASCII_USTRINGPARAM("Name") ), SbxCLASS_DONTCARE );
++						if ( pVar )
++						{
++							pVar->Broadcast( SBX_HINT_DATAWANTED );
++							if ( pVar->SbxValue::GetType() == SbxSTRING )
++							{
++								aDesc.msObjectName = pVar->GetString();
++								hResult[ sCodeName ] = aDesc;
++							}
++						}
++					}
++				}
++				case ModuleType::Class:
++				case ModuleType::Normal:
++					break; // no codenames for these
++				default:
++					break; // shouldn't get here ( #TODO assertion or whatever )
++			}
++		}
++	}
++	return hResult;
++}
++
+ // #i34411: Flag for error handling during migration 
+ static bool GbMigrationSuppressErrors = false;
+ 
  //============================================================================
  // Implementation class NameContainer
  
@@ -443,7 +515,7 @@
  // Methods XElementAccess
  Type NameContainer::getElementType()
  	throw(RuntimeException)
-@@ -158,7 +179,7 @@ void NameContainer::replaceByName( const
+@@ -158,7 +233,7 @@ void NameContainer::replaceByName( const
  	throw(IllegalArgumentException, NoSuchElementException, WrappedTargetException, RuntimeException)
  {
  	Type aAnyType = aElement.getValueType();
@@ -452,7 +524,7 @@
  		throw IllegalArgumentException();
  
  	NameContainerNameMap::iterator aIt = mHashMap.find( aName );
-@@ -200,7 +221,7 @@ void NameContainer::insertByName( const 
+@@ -200,7 +275,7 @@ void NameContainer::insertByName( const 
  	throw(IllegalArgumentException, ElementExistException, WrappedTargetException, RuntimeException)
  {
  	Type aAnyType = aElement.getValueType();
@@ -461,7 +533,7 @@
  		throw IllegalArgumentException();
  
  	NameContainerNameMap::iterator aIt = mHashMap.find( aName );
-@@ -330,6 +351,30 @@ void ModifiableHelper::setModified( sal_
+@@ -330,6 +405,30 @@ void ModifiableHelper::setModified( sal_
  // Implementation class SfxLibraryContainer
  DBG_NAME( SfxLibraryContainer )
  
@@ -492,7 +564,7 @@
  // Ctor
  SfxLibraryContainer::SfxLibraryContainer( void )
  	: LibraryContainerHelper( maMutex )
-@@ -339,6 +384,7 @@ SfxLibraryContainer::SfxLibraryContainer
+@@ -339,6 +438,7 @@ SfxLibraryContainer::SfxLibraryContainer
      , mbOasis2OOoFormat( sal_False )
      , mpBasMgr( NULL )
      , mbOwnBasMgr( sal_False )
@@ -500,7 +572,7 @@
  {
      DBG_CTOR( SfxLibraryContainer, NULL );
  
-@@ -798,7 +844,7 @@ sal_Bool SfxLibraryContainer::init_Impl(
+@@ -798,7 +898,7 @@ sal_Bool SfxLibraryContainer::init_Impl(
                  OSL_ENSURE( 0, OUStringToOString( e.Message, RTL_TEXTENCODING_ASCII_US ).getStr() );
                  return sal_False;
              }
@@ -509,7 +581,7 @@
  		    sal_Int32 nLibCount = pLibArray->mnLibCount;
  		    for( sal_Int32 i = 0 ; i < nLibCount ; i++ )
  		    {
-@@ -1696,17 +1742,39 @@ void SfxLibraryContainer::implImportLibD
+@@ -1696,21 +1796,42 @@ void SfxLibraryContainer::implImportLibD
      {
  	    sal_Int32 nElementCount = rLib.aElementNames.getLength();
  	    const OUString* pElementNames = rLib.aElementNames.getConstArray();
@@ -551,7 +623,31 @@
      }
  }
  
-@@ -2283,13 +2351,29 @@ void SAL_CALL SfxLibraryContainer::loadL
+-
+ // Methods of new XLibraryStorage interface?
+ void SfxLibraryContainer::storeLibraries_Impl( const uno::Reference< embed::XStorage >& xStorage, sal_Bool bComplete )
+ {
+@@ -1819,7 +1940,18 @@ void SfxLibraryContainer::storeLibraries
+ 		rLib.bPreload = pImplLib->mbPreload;
+ 		rLib.bPasswordProtected = pImplLib->mbPasswordProtected;
+ 		rLib.aElementNames = pImplLib->getElementNames();
+-
++		// #FIXME the codenames probably should be in the LibDescriptor 
++		// ok there should be a special code name for the document ( e.g. ThisWorkbook, ThisDocument etc.) this probably should exist in LibDescriptorArray
++		// hmm there possibly could be a problem distinguising that on
++		// excel import ( because it is just another Document Module )
++		// Hmm but also vba mode should only really be relevant for Standand 
++		// Library ( and I would say no other libraries should even exist )
++		// so, leaving for the moment
++		if ( pName->equals( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("Standard") ) ) )
++		{
++			pLibArray->mbVBAMode = getVBACompatModeOn();
++			rLib.hModuleTypeDesc = lcl_getObjModDescHash( *pImplLib );
++		}
+ 		if( pImplLib->implIsModified() || bComplete )
+ 		{
+             // Can we copy the storage?
+@@ -2283,13 +2415,29 @@ void SAL_CALL SfxLibraryContainer::loadL
  			}
  
  			Any aAny = importLibraryElement( aFile, xInStream );
@@ -581,7 +677,7 @@
  				pImplLib->maNameContainer.insertByName( aElementName, aAny );
              }
  		}
-@@ -2700,6 +2784,12 @@ OUString SfxLibraryContainer::expand_url
+@@ -2700,6 +2848,12 @@ OUString SfxLibraryContainer::expand_url
      return sal_False;
  }
  
@@ -615,7 +711,7 @@
          }
      }
 diff --git basic/source/uno/scriptcont.cxx basic/source/uno/scriptcont.cxx
-index 4a46e98..0683981 100644
+index 4a46e98..1a84f9f 100644
 --- basic/source/uno/scriptcont.cxx
 +++ basic/source/uno/scriptcont.cxx
 @@ -157,7 +157,7 @@ SfxScriptLibraryContainer::SfxScriptLibr
@@ -670,7 +766,7 @@
  						aLibInfoFileURL, aStorageURL, ReadOnly)
      , mbLoadedSource( sal_False )
      , mbLoadedBinary( sal_False )
-@@ -1188,7 +1193,183 @@ bool SAL_CALL SfxScriptLibrary::isLibrar
+@@ -1188,7 +1193,193 @@ bool SAL_CALL SfxScriptLibrary::isLibrar
  {
      return SfxScriptLibrary::containsValidModule( aElement );
  }
@@ -679,7 +775,9 @@
 +// XNameAccess, codename to/from objectnames
 +class PersistedReadOnlyCodeNames : ReadOnlyCodeNames_BASE
 +{
-+    ::xmlscript::CodeNameHash mCodeNameToObjectNames;
++typedef std::hash_map< rtl::OUString, rtl::OUString, ::rtl::OUStringHash, ::std::equal_to< ::rtl::OUString > > CodeNameHash;
+ 
++    CodeNameHash mCodeNameToObjectNames;
 +public:
 +    PersistedReadOnlyCodeNames()
 +    {
@@ -700,19 +798,27 @@
 +            if ( xDocStorage.is() ) // not a 'real' document
 +            {
 +                rtl::OUString codeNameDir( RTL_CONSTASCII_USTRINGPARAM("Basic") );
-+                rtl::OUString codeNameFile( RTL_CONSTASCII_USTRINGPARAM("script-lc.xml") );
++                rtl::OUString standardDir( RTL_CONSTASCII_USTRINGPARAM("Standard") );
++                rtl::OUString codeNameFile( RTL_CONSTASCII_USTRINGPARAM("script-lb.xml") );
 +    
 +                uno::Reference< embed::XStorage > xLibrariesStor( xDocStorage->openStorageElement( codeNameDir, embed::ElementModes::READ ), UNO_QUERY_THROW );
-+                uno::Reference< io::XStream > xStream( xLibrariesStor->openStreamElement( codeNameFile, embed::ElementModes::READ ), UNO_QUERY_THROW );
++                uno::Reference< embed::XStorage > xStandardStor( xLibrariesStor->openStorageElement( standardDir, embed::ElementModes::READ ), UNO_QUERY_THROW );
++                uno::Reference< io::XStream > xStream( xStandardStor->openStreamElement( codeNameFile, embed::ElementModes::READ ), UNO_QUERY_THROW );
 +                uno::Reference< io::XInputStream > xInput( xStream->getInputStream(), UNO_QUERY_THROW );
-+                ::xmlscript::LibDescriptorArray* pLibArray = new ::xmlscript::LibDescriptorArray();
++                ::xmlscript::LibDescriptor aLib;
 +                InputSource source;
 +                source.aInputStream = xInput;
 +
 +                Reference< XParser > xParser( xMSF->createInstance( OUString( RTL_CONSTASCII_USTRINGPARAM("com.sun.star.xml.sax.Parser") ) ), UNO_QUERY_THROW );
-+                xParser->setDocumentHandler(  ::xmlscript::importLibraryCodeNames( pLibArray ) );
++                xParser->setDocumentHandler(  ::xmlscript::importLibraryCodeNames( aLib ) );
 +                xParser->parseStream( source );
-+                mCodeNameToObjectNames = pLibArray->mCodeNames;
++                
++                ::xmlscript::ObjectModuleDescHash::iterator it_end = aLib.hModuleTypeDesc.end();
++                for ( ::xmlscript::ObjectModuleDescHash::iterator it = aLib.hModuleTypeDesc.begin(); it != it_end; ++it )
++                {
++                    if ( it->second.msObjectName.getLength() > 0 )
++                        mCodeNameToObjectNames[ it->second.msObjectName ] = it->first;
++                }
 +            }
 +        }
 +        catch ( Exception& e )
@@ -828,7 +934,7 @@
 +	    return bRes;
 +	}
 +};
- 
++
 +void SfxScriptLibraryContainer::convertLibraryEntries()
 +{
 +    if ( getVBACompatModeOn() )
@@ -1372,7 +1478,7 @@
                      }
                      else
 diff --git xmlscript/inc/xmlscript/xmllib_imexp.hxx xmlscript/inc/xmlscript/xmllib_imexp.hxx
-index 9a3048f..f92b154 100644
+index 9a3048f..8d8930d 100644
 --- xmlscript/inc/xmlscript/xmllib_imexp.hxx
 +++ xmlscript/inc/xmlscript/xmllib_imexp.hxx
 @@ -34,11 +34,21 @@
@@ -1398,7 +1504,7 @@
  //==============================================================================
  // Library container export
  // HACK C++ struct to transport info. Later the container 
-@@ -53,14 +63,19 @@ struct LibDescriptor
+@@ -53,14 +63,18 @@ struct LibDescriptor
  	sal_Bool bPasswordProtected;
  	::com::sun::star::uno::Sequence< ::rtl::OUString > aElementNames;
  	sal_Bool bPreload;
@@ -1413,19 +1519,18 @@
      sal_Int32 mnLibCount;
  
 -    LibDescriptorArray( void ) { mpLibs = NULL; mnLibCount = 0; }
-+    CodeNameHash mCodeNames;
 +    bool mbVBAMode;
 +    LibDescriptorArray( void ) { mpLibs = NULL; mnLibCount = 0; mbVBAMode = false; }
      LibDescriptorArray( sal_Int32 nLibCount );
  
      ~LibDescriptorArray();
-@@ -79,6 +94,11 @@ SAL_CALL exportLibraryContainer(
+@@ -79,6 +93,11 @@ SAL_CALL exportLibraryContainer(
  SAL_CALL importLibraryContainer( LibDescriptorArray* pLibArray )
  		SAL_THROW( (::com::sun::star::uno::Exception) );
  
 +::com::sun::star::uno::Reference<
 +    ::com::sun::star::xml::sax::XDocumentHandler >
-+SAL_CALL importLibraryCodeNames( LibDescriptorArray* pLibArray )
++SAL_CALL importLibraryCodeNames( LibDescriptor& rLib )
 +		SAL_THROW( (::com::sun::star::uno::Exception) );
 +
  
@@ -1452,8 +1557,101 @@
  public:
  
      virtual Reference< xml::input::XElement > SAL_CALL startChildElement(
+diff --git xmlscript/source/xmllib_imexp/xmllib_export.cxx xmlscript/source/xmllib_imexp/xmllib_export.cxx
+index 4f6de54..9f48234 100644
+--- xmlscript/source/xmllib_imexp/xmllib_export.cxx
++++ xmlscript/source/xmllib_imexp/xmllib_export.cxx
+@@ -44,6 +44,28 @@ namespace xmlscript
+ static OUString aTrueStr ( RTL_CONSTASCII_USTRINGPARAM("true") );
+ static OUString aFalseStr( RTL_CONSTASCII_USTRINGPARAM("false") );
+ 
++rtl::OUString lcl_getModuleTypeStringForType( sal_Int32 nModuleType )
++{
++	rtl::OUString sType;
++	switch( nModuleType )
++	{
++		case script::ModuleType::Document:
++			sType = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Document" ) );
++			break;
++		case script::ModuleType::Class:
++			sType = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Class" ) );
++			break;
++		case script::ModuleType::Form:
++			sType = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Form" ) );
++			break;
++		case script::ModuleType::Normal: // no need to set a module type
++		case script::ModuleType::Unknown:
++		default:
++			break;
++	}
++	return sType;
++}
++
+ //##################################################################################################
+ 
+ 
+@@ -73,11 +95,31 @@ SAL_CALL exportLibraryContainer(
+ 	pLibsElement->addAttribute( OUString( RTL_CONSTASCII_USTRINGPARAM("xmlns:" XMLNS_XLINK_PREFIX) ),
+ 							    OUString( RTL_CONSTASCII_USTRINGPARAM(XMLNS_XLINK_URI) ) );
+ 
++    int nLibCount = pLibArray->mnLibCount;
++	if ( pLibArray->mbVBAMode )
++		pLibsElement->addAttribute( OUString( RTL_CONSTASCII_USTRINGPARAM( XMLNS_LIBRARY_PREFIX ":vbaenabled") ), aTrueStr );
+ 
+-	xOut->ignorableWhitespace( OUString() );
+ 	xOut->startElement( aLibrariesName, xAttributes );
++	xOut->ignorableWhitespace( OUString() );
+ 
+-    int nLibCount = pLibArray->mnLibCount;
++/*
++	if ( pLibArray->mbVBAMode )
++	{
++		CodeNameHash::const_iterator it_end = pLibArray->mCodeNames.end();
++		for ( CodeNameHash::const_iterator it =  pLibArray->mCodeNames.begin() ; it!=it_end; ++it )
++		{
++			OUString aCodeName( RTL_CONSTASCII_USTRINGPARAM(XMLNS_LIBRARY_PREFIX ":codename") );
++			XMLElement* pLibElement = new XMLElement( aCodeName );
++			Reference< xml::sax::XAttributeList > xLibElementAttribs;
++			xLibElementAttribs = static_cast< xml::sax::XAttributeList* >( pLibElement );
++
++			pLibElement->addAttribute( OUString( RTL_CONSTASCII_USTRINGPARAM(XMLNS_LIBRARY_PREFIX ":name") ), it->first );
++			pLibElement->addAttribute( OUString( RTL_CONSTASCII_USTRINGPARAM(XMLNS_LIBRARY_PREFIX ":objectname") ), it->second );
++			pLibElement->dump( xOut.get() );
++		
++		}
++	}
++*/
+ 	for( sal_Int32 i = 0 ; i < nLibCount ; i++ )
+ 	{
+ 		LibDescriptor& rLib = pLibArray->mpLibs[i];
+@@ -157,6 +199,7 @@ SAL_CALL exportLibrary(
+ 	if( nElementCount )
+ 	{
+ 		const OUString* pElementNames = rLib.aElementNames.getConstArray();
++		
+ 		for( sal_Int32 i = 0 ; i < nElementCount ; i++ )
+ 		{
+ 			XMLElement* pElement = new XMLElement( OUString( RTL_CONSTASCII_USTRINGPARAM(XMLNS_LIBRARY_PREFIX ":element" ) ) );
+@@ -165,7 +208,16 @@ SAL_CALL exportLibrary(
+ 
+ 			pElement->addAttribute( OUString( RTL_CONSTASCII_USTRINGPARAM(XMLNS_LIBRARY_PREFIX ":name") ),
+ 										pElementNames[i] );
+-	
++			ObjectModuleDescHash::const_iterator it = rLib.hModuleTypeDesc.find( pElementNames[i] );
++			if ( it !=  rLib.hModuleTypeDesc.end() )
++			{
++				rtl::OUString sType = lcl_getModuleTypeStringForType( it->second.mnModuleType );
++				if ( sType.getLength() )
++				{
++					pElement->addAttribute( OUString( RTL_CONSTASCII_USTRINGPARAM(XMLNS_LIBRARY_PREFIX ":moduletype") ), sType );
++					pElement->addAttribute( OUString( RTL_CONSTASCII_USTRINGPARAM(XMLNS_LIBRARY_PREFIX ":objectname") ), it->second.msObjectName );
++				}
++			}
+ 			pLibElement->addSubElement( pElement );
+ 		}
+ 	}
 diff --git xmlscript/source/xmllib_imexp/xmllib_import.cxx xmlscript/source/xmllib_imexp/xmllib_import.cxx
-index b533d37..ce31ee0 100644
+index b533d37..48fc051 100644
 --- xmlscript/source/xmllib_imexp/xmllib_import.cxx
 +++ xmlscript/source/xmllib_imexp/xmllib_import.cxx
 @@ -44,7 +44,20 @@ namespace xmlscript
@@ -1492,42 +1690,25 @@
          return new LibrariesElement( rLocalName, xAttributes, 0, this );
      }
      else if (mpLibDesc && rLocalName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("library") ))
-@@ -269,6 +289,19 @@ Reference< xml::input::XElement > Librar
-         mLibDescriptors.push_back( aDesc );
-         return new LibraryElement( rLocalName, xAttributes, this, _pImport );
-     }
-+    // CodeNames are only relevant for the container ( e.g. the document )
-+    else if (rLocalName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("codename") ))
-+    {
-+        rtl::OUString sCodeName =  xAttributes->getValueByUidName(
-+            _pImport->XMLNS_LIBRARY_UID,
-+            OUString( RTL_CONSTASCII_USTRINGPARAM("name") ) );
-+        rtl::OUString sObjectName =  xAttributes->getValueByUidName(
-+            _pImport->XMLNS_LIBRARY_UID,
-+            OUString( RTL_CONSTASCII_USTRINGPARAM("objectname") ) );
-+        if ( ( sCodeName.getLength() > 0 ) && ( sObjectName.getLength() > 0 ) )
-+                _pImport->mpLibArray->mCodeNames[ sObjectName ] = sCodeName;
-+        return new LibElementBase( rLocalName, xAttributes, this, _pImport );
-+    }
-     else
-     {
-         throw xml::sax::SAXException(
-@@ -311,7 +344,13 @@ Reference< xml::input::XElement > Librar
-             OUString( RTL_CONSTASCII_USTRINGPARAM("name") ) ) );
+@@ -312,6 +332,17 @@ Reference< xml::input::XElement > Librar
          if (aValue.getLength())
              mElements.push_back( aValue );
--
+ 
 +        ObjectModuleDesc aDesc;
++	
 +        aDesc.mnModuleType = lcl_getModuleTypeForStringType( 
 +          xAttributes->getValueByUidName(
 +            _pImport->XMLNS_LIBRARY_UID,
 +            OUString( RTL_CONSTASCII_USTRINGPARAM("moduletype") ) ) );
++        aDesc.msObjectName = xAttributes->getValueByUidName(
++            _pImport->XMLNS_LIBRARY_UID,
++            OUString( RTL_CONSTASCII_USTRINGPARAM("objectname") ) );
 +        if ( aValue.getLength() && aDesc.mnModuleType != ::com::sun::star::script::ModuleType::Unknown )
 +             mObjectDescs[ aValue ] = aDesc;
          return new LibElementBase( rLocalName, xAttributes, this, _pImport );
      }
      else
-@@ -335,6 +374,7 @@ void LibraryElement::endElement()
+@@ -335,6 +366,7 @@ void LibraryElement::endElement()
      if( !pLib )
          pLib = &static_cast< LibrariesElement* >( _pParent )->mLibDescriptors.back();
      pLib->aElementNames = aElementNames;
@@ -1535,24 +1716,23 @@
  }
  
  
-@@ -348,6 +388,16 @@ SAL_CALL importLibraryContainer( LibDesc
+@@ -348,6 +380,15 @@ SAL_CALL importLibraryContainer( LibDesc
          static_cast< xml::input::XRoot * >( new LibraryImport( pLibArray ) ) );
  }
  
 +
 +Reference< ::com::sun::star::xml::sax::XDocumentHandler >
-+SAL_CALL importLibraryCodeNames( LibDescriptorArray* pLibArray )
++SAL_CALL importLibraryCodeNames( LibDescriptor& rLib)
 +        SAL_THROW( (Exception) )
 +{
-+    return ::xmlscript::createDocumentHandler(
-+        static_cast< xml::input::XRoot * >( new LibraryImport( pLibArray ) ) );
++    return importLibrary( rLib );
 +}
 +
 +
  //##################################################################################################
  
  ::com::sun::star::uno::Reference< ::com::sun::star::xml::sax::XDocumentHandler >
-@@ -365,6 +415,7 @@ LibDescriptorArray::LibDescriptorArray( 
+@@ -365,6 +406,7 @@ LibDescriptorArray::LibDescriptorArray( 
  {
      mnLibCount = nLibCount;
      mpLibs = new LibDescriptor[ mnLibCount ];



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]