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
9  * with the License.  You may obtain a copy of the License at
10  *
11  *   http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing,
14  * software distributed under the License is distributed on an
15  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16  * KIND, either express or implied.  See the License for the
17  * specific language governing permissions and limitations
18  * under the License.
19  *
20  *************************************************************/
21 
22 
23 
24 #ifndef _IDERDLL2_HXX
25 #define _IDERDLL2_HXX
26 
27 class StarBASIC;
28 class SvxSearchItem;
29 class Accelerator;
30 
31 #include <tools/string.hxx>
32 #include <tools/gen.hxx>
33 #include <tools/link.hxx>
34 
35 #include <bastypes.hxx>
36 #include <bastype2.hxx>
37 
38 #define INVPOSITION	0x7fff
39 
40 class BasicIDEData
41 {
42 private:
43 	Accelerator*	pAccelerator;
44 	SvxSearchItem*	pSearchItem;
45 
46 	LibInfos		aLibInfos;
47 
48     BasicEntryDescriptor    m_aLastEntryDesc;
49 
50 	Point			aObjCatPos;
51 	Size			aObjCatSize;
52 
53 	String			aAddLibPath;
54 	String			aAddLibFilter;
55 
56 	sal_uInt16			nBasicDialogCount;
57 
58 	sal_Bool			OLD_bRelMacroRecording;
59 	sal_Bool			bChoosingMacro;
60 	sal_Bool			bShellInCriticalSection;
61 
62 protected:
63     DECL_LINK( GlobalBasicBreakHdl, StarBASIC * );
64 
65 public:
66 							BasicIDEData();
67 							~BasicIDEData();
68 
GetLibInfos()69 	LibInfos&				GetLibInfos() { return aLibInfos; }
70 
GetLastEntryDescriptor()71     BasicEntryDescriptor&   GetLastEntryDescriptor()    { return m_aLastEntryDesc; }
SetLastEntryDescriptor(BasicEntryDescriptor & rDesc)72     void                    SetLastEntryDescriptor( BasicEntryDescriptor& rDesc ) { m_aLastEntryDesc = rDesc; }
73 
ChoosingMacro()74 	sal_Bool&					ChoosingMacro() 			{ return bChoosingMacro; }
ShellInCriticalSection()75 	sal_Bool&					ShellInCriticalSection()	{ return bShellInCriticalSection; }
76 
GetBasicDialogCount() const77 	sal_uInt16					GetBasicDialogCount() const { return nBasicDialogCount; }
IncBasicDialogCount()78 	void					IncBasicDialogCount() 		{ nBasicDialogCount++; }
DecBasicDialogCount()79 	void					DecBasicDialogCount()		{ nBasicDialogCount--; }
80 
81 	SvxSearchItem&			GetSearchItem() const;
82 	void					SetSearchItem( const SvxSearchItem& rItem );
83 
SetObjectCatalogPos(const Point & rPnt)84 	void					SetObjectCatalogPos( const Point& rPnt )
85 								{ aObjCatPos = rPnt; }
GetObjectCatalogPos() const86 	const Point&			GetObjectCatalogPos() const
87 								{ return aObjCatPos; }
88 
SetObjectCatalogSize(const Size & rSize)89 	void					SetObjectCatalogSize( const Size& rSize )
90 								{ aObjCatSize = rSize; }
GetObjectCatalogSize() const91 	const Size&				GetObjectCatalogSize() const
92 								{ return aObjCatSize; }
93 
GetAddLibPath() const94 	const String&			GetAddLibPath() const	{ return aAddLibPath; }
SetAddLibPath(const String & rPath)95 	void					SetAddLibPath( const String& rPath ) { aAddLibPath = rPath; }
96 
GetAddLibFilter() const97 	const String&			GetAddLibFilter() const	{ return aAddLibFilter; }
SetAddLibFilter(const String & rFilter)98 	void					SetAddLibFilter( const String& rFilter )  { aAddLibFilter = rFilter; }
99 };
100 
101 
102 #endif //_IDERDLL2_HXX
103