1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: globals.cxx,v $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
31 // MARKER(update_precomp.py): autogen include statement, do not remove
32 #include "precompiled_idl.hxx"
34 /****************** I N C L U D E S **************************************/
35 #include <tools/shl.hxx>
37 #include <globals.hxx>
38 #include <database.hxx>
40 /****************** G L O B A L S ****************************************/
42 static IdlDll
* pApp
= NULL
;
52 if( !(*(IdlDll
**)GetAppData(SHL_IDL
)) )
54 (*(IdlDll
**)GetAppData(SHL_IDL
)) = new IdlDll();
55 // Temporaer, sonst nur wenn Compiler
56 //GetIdlApp()->pHashTable = new SvStringHashTable( 2801 );
57 //GetIdlApp()->pGlobalNames = new SvGlobalHashNames();
59 return (*(IdlDll
**)GetAppData(SHL_IDL
));
66 , pGlobalNames( NULL
)
69 pClassMgr
= new SvClassManager();
71 pClassMgr
->SV_CLASS_REGISTER( SvMetaAttribute
);
72 pClassMgr
->SV_CLASS_REGISTER( SvMetaClass
);
74 pClassMgr
->SV_CLASS_REGISTER( SvMetaSlot
);
76 pClassMgr
->SV_CLASS_REGISTER( SvMetaModule
);
78 pClassMgr
->SV_CLASS_REGISTER( SvMetaObject
);
79 pClassMgr
->SV_CLASS_REGISTER( SvMetaName
);
80 pClassMgr
->SV_CLASS_REGISTER( SvMetaExtern
);
81 pClassMgr
->SV_CLASS_REGISTER( SvMetaReference
);
83 pClassMgr
->SV_CLASS_REGISTER( SvMetaType
);
84 pClassMgr
->SV_CLASS_REGISTER( SvMetaTypeString
);
85 pClassMgr
->SV_CLASS_REGISTER( SvMetaEnumValue
);
86 pClassMgr
->SV_CLASS_REGISTER( SvMetaTypeEnum
);
87 pClassMgr
->SV_CLASS_REGISTER( SvMetaTypevoid
);
88 pClassMgr
->SV_CLASS_REGISTER( SvClassElement
);
98 /*************************************************************************
100 |* SvGlobalHashNames::SvGlobalHashNames()
103 |* Ersterstellung MM 08.08.91
104 |* Letzte Aenderung MM 08.08.91
106 *************************************************************************/
107 inline SvStringHashEntry
* INS( const ByteString
& rName
)
110 IDLAPP
->pHashTable
->Insert( rName
, &nIdx
);
111 return (SvStringHashEntry
* )IDLAPP
->pHashTable
->Get( nIdx
);
113 #define A_ENTRY( Name ) , MM_##Name( INS( #Name ) )
115 SvGlobalHashNames::SvGlobalHashNames()
116 : MM_Name( INS( "Name" ) )
117 , MM_module( INS( "module" ) )
118 , MM_interface( INS( "interface" ) )
119 , MM_in( INS( "in" ) )
120 , MM_out( INS( "out" ) )
121 , MM_inout( INS( "inout" ) )
122 , MM_String( INS( "String" ) )
123 , MM_UCHAR( INS( "UCHAR" ) )
124 , MM_USHORT( INS( "USHORT" ) )
125 , MM_uuid( INS( "uuid" ) )
126 , MM_HelpContext( INS( "HelpContext" ) )
127 , MM_HelpText( INS( "HelpText" ) )
128 , MM_void( INS( "void" ) )
129 , MM_shell( INS( "shell" ) )
130 , MM_Get( INS( "Get" ) )
131 , MM_Set( INS( "Set" ) )
132 , MM_SlotId( INS( "SlotId" ) )
133 , MM_HasCoreId( INS( "HasCoreId" ) )
134 , MM_Cachable( INS( "Cachable" ) )
135 // , MM_Volatile( INS( "Volatile" ) )
136 , MM_Toggle( INS( "Toggle" ) )
137 , MM_AutoUpdate( INS( "AutoUpdate" ) )
138 , MM_Synchron( INS( "Synchron" ) )
139 , MM_Asynchron( INS( "Asynchron" ) )
140 A_ENTRY(RecordPerSet
)
141 A_ENTRY(RecordPerItem
)
142 A_ENTRY(RecordManual
)
144 A_ENTRY(RecordAbsolute
)
176 A_ENTRY(PseudoPrefix
)
179 A_ENTRY(ToolBoxConfig
)
180 A_ENTRY(StatusBarConfig
)
186 A_ENTRY(ImageRotation
)
187 A_ENTRY(ImageReflection
)
188 A_ENTRY(IsCollection
)
196 A_ENTRY(ModulePrefix
)
197 A_ENTRY(DisableFlags
)