summaryrefslogtreecommitdiff
path: root/basic/source/classes
diff options
context:
space:
mode:
authorJens-Heiner Rechtien <hr@openoffice.org>2007-08-03 08:55:16 +0000
committerJens-Heiner Rechtien <hr@openoffice.org>2007-08-03 08:55:16 +0000
commitd88593af59d9126cdbcd6c0a5b06fb9c673dc6f9 (patch)
tree54465fc634ff49a32b9d2e89ff05d398af97d180 /basic/source/classes
parentb8e099fb653ad8a685004738e2fb4e949fcbbb85 (diff)
INTEGRATION: CWS ab34 (1.36.50); FILE MERGED
2007/07/24 13:47:27 ab 1.36.50.3: RESYNC: (1.36-1.37); FILE MERGED 2007/06/20 10:48:58 ab 1.36.50.2: #i75428# Search MSO Macro Runtime lib and disable search for vba mode 2007/03/12 12:12:36 ab 1.36.50.1: #i73457# Prevent sub from beeing set as param 0 for return type void
Diffstat (limited to 'basic/source/classes')
-rw-r--r--basic/source/classes/sbxmod.cxx28
1 files changed, 25 insertions, 3 deletions
diff --git a/basic/source/classes/sbxmod.cxx b/basic/source/classes/sbxmod.cxx
index 4d7356c73182..4464b4e7eb99 100644
--- a/basic/source/classes/sbxmod.cxx
+++ b/basic/source/classes/sbxmod.cxx
@@ -4,9 +4,9 @@
*
* $RCSfile: sbxmod.cxx,v $
*
- * $Revision: 1.37 $
+ * $Revision: 1.38 $
*
- * last change: $Author: hr $ $Date: 2007-06-27 14:19:36 $
+ * last change: $Author: hr $ $Date: 2007-08-03 09:55:16 $
*
* The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1.
@@ -690,6 +690,8 @@ void ClearUnoObjectsInRTL_Impl( StarBASIC* pBasic )
USHORT SbModule::Run( SbMethod* pMeth )
{
static USHORT nMaxCallLevel = 0;
+ static String aMSOMacroRuntimeLibName = String::CreateFromAscii( "Launcher" );
+ static String aMSOMacroRuntimeAppSymbol = String::CreateFromAscii( "Application" );
USHORT nRes = 0;
BOOL bDelInst = BOOL( pINST == NULL );
@@ -701,6 +703,25 @@ USHORT SbModule::Run( SbMethod* pMeth )
pINST = new SbiInstance( (StarBASIC*) GetParent() );
+ // Launcher problem
+ SbxVariable* pMSOMacroRuntimeLibVar = Find( aMSOMacroRuntimeLibName, SbxCLASS_OBJECT );
+ if( pMSOMacroRuntimeLibVar )
+ {
+ StarBASIC* pMSOMacroRuntimeLib = PTR_CAST(StarBASIC,pMSOMacroRuntimeLibVar);
+ if( pMSOMacroRuntimeLib )
+ {
+ USHORT nGblFlag = pMSOMacroRuntimeLib->GetFlags() & SBX_GBLSEARCH;
+ pMSOMacroRuntimeLib->ResetFlag( SBX_GBLSEARCH );
+ SbxVariable* pAppSymbol = pMSOMacroRuntimeLib->Find( aMSOMacroRuntimeAppSymbol, SbxCLASS_METHOD );
+ pMSOMacroRuntimeLib->SetFlag( nGblFlag );
+ if( pAppSymbol )
+ {
+ pMSOMacroRuntimeLib->SetFlag( SBX_EXTSEARCH ); // Could have been disabled before
+ GetSbData()->pMSOMacroRuntimLib = pMSOMacroRuntimeLib;
+ }
+ }
+ }
+
// Error-Stack loeschen
SbErrorStack*& rErrStack = GetSbData()->pErrStack;
delete rErrStack;
@@ -2047,7 +2068,8 @@ void SbMethod::Broadcast( ULONG nHintId )
if( mpPar.Is() )
{
// this, als Element 0 eintragen, aber den Parent nicht umsetzen!
- mpPar->PutDirect( pThisCopy, 0 );
+ if( GetType() != SbxVOID )
+ mpPar->PutDirect( pThisCopy, 0 );
SetParameters( NULL );
}