diff options
author | Daniel Rentz <dr@openoffice.org> | 2010-04-16 17:28:52 +0200 |
---|---|---|
committer | Daniel Rentz <dr@openoffice.org> | 2010-04-16 17:28:52 +0200 |
commit | 45cc8f5bd1f3f7bb3cb4e63088f280dc8e8b93fc (patch) | |
tree | c08499c115b95d8a3c5b676668e0df2679f50fe2 /basic/source | |
parent | 130bbc98813c32460dc354dfa712de620cedecff (diff) |
npower13_objectmodules: uppercase UNO constants
Diffstat (limited to 'basic/source')
-rw-r--r-- | basic/source/basmgr/basmgr.cxx | 1 | ||||
-rw-r--r-- | basic/source/classes/sb.cxx | 14 | ||||
-rw-r--r-- | basic/source/classes/sbxmod.cxx | 5 | ||||
-rw-r--r-- | basic/source/comp/codegen.cxx | 7 | ||||
-rw-r--r-- | basic/source/comp/parser.cxx | 5 |
5 files changed, 17 insertions, 15 deletions
diff --git a/basic/source/basmgr/basmgr.cxx b/basic/source/basmgr/basmgr.cxx index ac7812fd6c66..1caa22980f1b 100644 --- a/basic/source/basmgr/basmgr.cxx +++ b/basic/source/basmgr/basmgr.cxx @@ -67,7 +67,6 @@ #include <com/sun/star/script/XStarBasicLibraryInfo.hpp> #include <com/sun/star/script/XLibraryContainerPassword.hpp> #include <com/sun/star/script/ModuleInfo.hpp> -#include <com/sun/star/script/ModuleType.hpp> #include <com/sun/star/script/XVBAModuleInfo.hpp> #include <com/sun/star/script/XVBACompat.hpp> diff --git a/basic/source/classes/sb.cxx b/basic/source/classes/sb.cxx index 7f7ac8784742..233b181757f0 100644 --- a/basic/source/classes/sb.cxx +++ b/basic/source/classes/sb.cxx @@ -490,7 +490,7 @@ SbClassModuleObject::SbClassModuleObject( SbModule* pClassModule ) } } } - SetModuleType( com::sun::star::script::ModuleType::Class ); + SetModuleType( ModuleType::CLASS ); } SbClassModuleObject::~SbClassModuleObject() @@ -790,7 +790,7 @@ SbModule* StarBASIC::MakeModule( const String& rName, const String& rSrc ) SbModule* StarBASIC::MakeModule32( const String& rName, const ::rtl::OUString& rSrc ) { ModuleInfo mInfo; - mInfo.ModuleType = ModuleType::Normal; + mInfo.ModuleType = ModuleType::NORMAL; return MakeModule32( rName, mInfo, rSrc ); } SbModule* StarBASIC::MakeModule32( const String& rName, const ModuleInfo& mInfo, const rtl::OUString& rSrc ) @@ -800,17 +800,17 @@ SbModule* StarBASIC::MakeModule32( const String& rName, const ModuleInfo& mInfo, SbModule* p = NULL; switch ( mInfo.ModuleType ) { - case ModuleType::Document: + case ModuleType::DOCUMENT: // In theory we should be able to create Object modules // in ordinary basic ( in vba mode thought these are create // by the application/basic and not by the user ) p = new SbObjModule( rName, mInfo, isVBAEnabled() ); break; - case ModuleType::Class: + case ModuleType::CLASS: p = new SbModule( rName, isVBAEnabled() ); - p->SetModuleType( com::sun::star::script::ModuleType::Class ); + p->SetModuleType( ModuleType::CLASS ); break; - case ModuleType::Form: + case ModuleType::FORM: p = new SbUserFormModule( rName, mInfo, isVBAEnabled() ); break; default: @@ -995,7 +995,7 @@ SbxVariable* StarBASIC::Find( const String& rName, SbxClassType t ) // Only variables qualified by the Module Name e.g. Sheet1.foo // should work for Documant && Class type Modules INT32 nType = p->GetModuleType(); - if ( nType == com::sun::star::script::ModuleType::Document || nType == com::sun::star::script::ModuleType::Form ) + if ( nType == ModuleType::DOCUMENT || nType == ModuleType::FORM ) continue; // otherwise check if the element is available diff --git a/basic/source/classes/sbxmod.cxx b/basic/source/classes/sbxmod.cxx index ab655c88ce10..93705d05460e 100644 --- a/basic/source/classes/sbxmod.cxx +++ b/basic/source/classes/sbxmod.cxx @@ -54,6 +54,7 @@ #include <vos/mutex.hxx> #include <basic/sbobjmod.hxx> #include <com/sun/star/lang/XServiceInfo.hpp> +#include <com/sun/star/script/ModuleType.hpp> // for the bsearch @@ -165,7 +166,7 @@ SbModule::SbModule( const String& rName, BOOL bVBACompat ) { SetName( rName ); SetFlag( SBX_EXTSEARCH | SBX_GBLSEARCH ); - SetModuleType( com::sun::star::script::ModuleType::Normal ); + SetModuleType( script::ModuleType::NORMAL ); } SbModule::~SbModule() @@ -1503,7 +1504,7 @@ SbObjModule::SbObjModule( const String& rName, const com::sun::star::script::Mod : SbModule( rName, bIsVbaCompatible ) { SetModuleType( mInfo.ModuleType ); - if ( mInfo.ModuleType == script::ModuleType::Form ) + if ( mInfo.ModuleType == script::ModuleType::FORM ) { SetClassName( rtl::OUString::createFromAscii( "Form" ) ); } diff --git a/basic/source/comp/codegen.cxx b/basic/source/comp/codegen.cxx index 1cf38f171e8b..46f829b382e8 100644 --- a/basic/source/comp/codegen.cxx +++ b/basic/source/comp/codegen.cxx @@ -32,6 +32,7 @@ #include "sbcomp.hxx" #include "image.hxx" #include <limits> +#include <com/sun/star/script/ModuleType.hpp> // nInc ist die Inkrementgroesse der Puffer @@ -129,7 +130,7 @@ void SbiCodeGen::Save() p->SetFlag( SBIMG_EXPLICIT ); int nIfaceCount = 0; - if( rMod.mnType == com::sun::star::script::ModuleType::Class ) + if( rMod.mnType == com::sun::star::script::ModuleType::CLASS ) { OSL_TRACE("COdeGen::save() classmodule processing"); rMod.bIsProxyModule = true; @@ -156,8 +157,8 @@ void SbiCodeGen::Save() { pCLASSFAC->RemoveClassModule( &rMod ); // Only a ClassModule can revert to Normal - if ( rMod.mnType == com::sun::star::script::ModuleType::Class ) - rMod.mnType = com::sun::star::script::ModuleType::Normal; + if ( rMod.mnType == com::sun::star::script::ModuleType::CLASS ) + rMod.mnType = com::sun::star::script::ModuleType::NORMAL; rMod.bIsProxyModule = false; } if( pParser->bText ) diff --git a/basic/source/comp/parser.cxx b/basic/source/comp/parser.cxx index 9fbd1035fa5f..8770dc8539f0 100644 --- a/basic/source/comp/parser.cxx +++ b/basic/source/comp/parser.cxx @@ -29,6 +29,7 @@ #include "precompiled_basic.hxx" #include <basic/sbx.hxx> #include "sbcomp.hxx" +#include <com/sun/star/script/ModuleType.hpp> struct SbiParseStack { // "Stack" fuer Statement-Blocks SbiParseStack* pNext; // Chain @@ -140,7 +141,7 @@ SbiParser::SbiParser( StarBASIC* pb, SbModule* pm ) bNewGblDefs = bSingleLineIf = bExplicit = FALSE; - bClassModule = ( pm->GetModuleType() == com::sun::star::script::ModuleType::Class ); + bClassModule = ( pm->GetModuleType() == com::sun::star::script::ModuleType::CLASS ); OSL_TRACE("Parser - %s, bClassModule %d", rtl::OUStringToOString( pm->GetName(), RTL_TEXTENCODING_UTF8 ).getStr(), bClassModule ); pPool = &aPublics; for( short i = 0; i < 26; i++ ) @@ -756,7 +757,7 @@ void SbiParser::Option() case CLASSMODULE: bClassModule = TRUE; - aGen.GetModule().SetModuleType( com::sun::star::script::ModuleType::Class ); + aGen.GetModule().SetModuleType( com::sun::star::script::ModuleType::CLASS ); break; case VBASUPPORT: if( Next() == NUMBER ) |