sbunoobj.cxx (79aad27f) sbunoobj.cxx (0848378b)
1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements. See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership. The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance

--- 319 unchanged lines hidden (view full) ---

328}
329
330void implAppendExceptionMsg( ::rtl::OUStringBuffer& _inout_rBuffer, const Exception& _e, const ::rtl::OUString& _rExceptionType, sal_Int32 _nLevel )
331{
332 _inout_rBuffer.appendAscii( "\n" );
333 lcl_indent( _inout_rBuffer, _nLevel );
334 _inout_rBuffer.appendAscii( "Type: " );
335
1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements. See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership. The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance

--- 319 unchanged lines hidden (view full) ---

328}
329
330void implAppendExceptionMsg( ::rtl::OUStringBuffer& _inout_rBuffer, const Exception& _e, const ::rtl::OUString& _rExceptionType, sal_Int32 _nLevel )
331{
332 _inout_rBuffer.appendAscii( "\n" );
333 lcl_indent( _inout_rBuffer, _nLevel );
334 _inout_rBuffer.appendAscii( "Type: " );
335
336 if ( _rExceptionType.getLength() == 0 )
336 if ( _rExceptionType.isEmpty() )
337 _inout_rBuffer.appendAscii( "Unknown" );
338 else
339 _inout_rBuffer.append( _rExceptionType );
340
341 _inout_rBuffer.appendAscii( "\n" );
342 lcl_indent( _inout_rBuffer, _nLevel );
343 _inout_rBuffer.appendAscii( "Message: " );
344 _inout_rBuffer.append( _e.Message );

--- 1423 unchanged lines hidden (view full) ---

1768 {
1769 // there is a hack in the extensions/source/ole/oleobj.cxx to return the typename of the automation object, lets check if it
1770 // matches
1771 Reference< XInvocation > xInv( aToInspectObj, UNO_QUERY );
1772 if ( xInv.is() )
1773 {
1774 rtl::OUString sTypeName;
1775 xInv->getValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("$GetTypeName") ) ) >>= sTypeName;
337 _inout_rBuffer.appendAscii( "Unknown" );
338 else
339 _inout_rBuffer.append( _rExceptionType );
340
341 _inout_rBuffer.appendAscii( "\n" );
342 lcl_indent( _inout_rBuffer, _nLevel );
343 _inout_rBuffer.appendAscii( "Message: " );
344 _inout_rBuffer.append( _e.Message );

--- 1423 unchanged lines hidden (view full) ---

1768 {
1769 // there is a hack in the extensions/source/ole/oleobj.cxx to return the typename of the automation object, lets check if it
1770 // matches
1771 Reference< XInvocation > xInv( aToInspectObj, UNO_QUERY );
1772 if ( xInv.is() )
1773 {
1774 rtl::OUString sTypeName;
1775 xInv->getValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("$GetTypeName") ) ) >>= sTypeName;
1776 if ( sTypeName.getLength() == 0 || sTypeName.equals( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("IDispatch") ) ) )
1776 if ( sTypeName.isEmpty() || sTypeName.equals( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("IDispatch") ) ) )
1777 // can't check type, leave it pass
1778 result = true;
1779 else
1780 result = sTypeName.equals( rClass );
1781 }
1782 break; // finished checking automation object
1783 }
1784

--- 508 unchanged lines hidden (view full) ---

2293 {
2294 sal_uInt16 iSbx = (sal_uInt16)(i+1);
2295
2296 // ACHTUNG: Bei den Sbx-Parametern den Offset nicht vergessen!
2297 aValAny = sbxToUnoValueImpl( pParams->Get( iSbx ),
2298 bBlockConversionToSmallestType );
2299
2300 ::rtl::OUString aParamName = pNames[iSbx];
1777 // can't check type, leave it pass
1778 result = true;
1779 else
1780 result = sTypeName.equals( rClass );
1781 }
1782 break; // finished checking automation object
1783 }
1784

--- 508 unchanged lines hidden (view full) ---

2293 {
2294 sal_uInt16 iSbx = (sal_uInt16)(i+1);
2295
2296 // ACHTUNG: Bei den Sbx-Parametern den Offset nicht vergessen!
2297 aValAny = sbxToUnoValueImpl( pParams->Get( iSbx ),
2298 bBlockConversionToSmallestType );
2299
2300 ::rtl::OUString aParamName = pNames[iSbx];
2301 if( aParamName.getLength() )
2301 if( !aParamName.isEmpty() )
2302 {
2303 oleautomation::NamedArgument aNamedArgument;
2304 aNamedArgument.Name = aParamName;
2305 aNamedArgument.Value = aValAny;
2306 pAnyArgs[i] <<= aNamedArgument;
2307 }
2308 else
2309 {

--- 440 unchanged lines hidden (view full) ---

2750 if( !pRes )
2751 {
2752 ::rtl::OUString aUName( rName );
2753 if( mxUnoAccess.is() && !bNativeCOMObject )
2754 {
2755 if( mxExactName.is() )
2756 {
2757 ::rtl::OUString aUExactName = mxExactName->getExactName( aUName );
2302 {
2303 oleautomation::NamedArgument aNamedArgument;
2304 aNamedArgument.Name = aParamName;
2305 aNamedArgument.Value = aValAny;
2306 pAnyArgs[i] <<= aNamedArgument;
2307 }
2308 else
2309 {

--- 440 unchanged lines hidden (view full) ---

2750 if( !pRes )
2751 {
2752 ::rtl::OUString aUName( rName );
2753 if( mxUnoAccess.is() && !bNativeCOMObject )
2754 {
2755 if( mxExactName.is() )
2756 {
2757 ::rtl::OUString aUExactName = mxExactName->getExactName( aUName );
2758 if( aUExactName.getLength() )
2758 if( !aUExactName.isEmpty() )
2759 aUName = aUExactName;
2760 }
2761 if( mxUnoAccess->hasProperty( aUName, PropertyConcept::ALL - PropertyConcept::DANGEROUS ) )
2762 {
2763 const Property& rProp = mxUnoAccess->
2764 getProperty( aUName, PropertyConcept::ALL - PropertyConcept::DANGEROUS );
2765
2766 // #58455 Wenn die Property void sein kann, muss als Typ Variant gesetzt werden

--- 59 unchanged lines hidden (view full) ---

2826 }
2827 }
2828 }
2829 if( !pRes && mxInvocation.is() )
2830 {
2831 if( mxExactNameInvocation.is() )
2832 {
2833 ::rtl::OUString aUExactName = mxExactNameInvocation->getExactName( aUName );
2759 aUName = aUExactName;
2760 }
2761 if( mxUnoAccess->hasProperty( aUName, PropertyConcept::ALL - PropertyConcept::DANGEROUS ) )
2762 {
2763 const Property& rProp = mxUnoAccess->
2764 getProperty( aUName, PropertyConcept::ALL - PropertyConcept::DANGEROUS );
2765
2766 // #58455 Wenn die Property void sein kann, muss als Typ Variant gesetzt werden

--- 59 unchanged lines hidden (view full) ---

2826 }
2827 }
2828 }
2829 if( !pRes && mxInvocation.is() )
2830 {
2831 if( mxExactNameInvocation.is() )
2832 {
2833 ::rtl::OUString aUExactName = mxExactNameInvocation->getExactName( aUName );
2834 if( aUExactName.getLength() )
2834 if( !aUExactName.isEmpty() )
2835 aUName = aUExactName;
2836 }
2837
2838 try
2839 {
2840 if( mxInvocation->hasProperty( aUName ) )
2841 {
2842 // Property anlegen und reinbraten

--- 1930 unchanged lines hidden (view full) ---

4773
4774 SbxArray* pModIfaces = pClassData->mxIfaces;
4775 sal_uInt16 nCount = pModIfaces->Count();
4776 for( sal_uInt16 i = 0 ; i < nCount ; ++i )
4777 {
4778 SbxVariable* pVar = pModIfaces->Get( i );
4779 ::rtl::OUString aIfaceName = pVar->GetName();
4780
2835 aUName = aUExactName;
2836 }
2837
2838 try
2839 {
2840 if( mxInvocation->hasProperty( aUName ) )
2841 {
2842 // Property anlegen und reinbraten

--- 1930 unchanged lines hidden (view full) ---

4773
4774 SbxArray* pModIfaces = pClassData->mxIfaces;
4775 sal_uInt16 nCount = pModIfaces->Count();
4776 for( sal_uInt16 i = 0 ; i < nCount ; ++i )
4777 {
4778 SbxVariable* pVar = pModIfaces->Get( i );
4779 ::rtl::OUString aIfaceName = pVar->GetName();
4780
4781 if( aIfaceName.getLength() != 0 )
4781 if( !aIfaceName.isEmpty() )
4782 {
4783 ::rtl::OUString aPureIfaceName = aIfaceName;
4784 sal_Int32 indexLastDot = aIfaceName.lastIndexOf('.');
4785 if ( indexLastDot > -1 )
4786 aPureIfaceName = aIfaceName.copy( indexLastDot + 1 );
4787
4788 Reference< XInvocation > xProxy = new ModuleInvocationProxy( aPureIfaceName, pProxyClassModuleObject );
4789

--- 71 unchanged lines hidden ---
4782 {
4783 ::rtl::OUString aPureIfaceName = aIfaceName;
4784 sal_Int32 indexLastDot = aIfaceName.lastIndexOf('.');
4785 if ( indexLastDot > -1 )
4786 aPureIfaceName = aIfaceName.copy( indexLastDot + 1 );
4787
4788 Reference< XInvocation > xProxy = new ModuleInvocationProxy( aPureIfaceName, pProxyClassModuleObject );
4789

--- 71 unchanged lines hidden ---