xref: /aoo42x/main/sw/inc/drawdoc.hxx (revision 26ea3662)
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 #ifndef _DRAWDOC_HXX
24 #define _DRAWDOC_HXX
25 
26 #ifndef _FM_FMMODEL_HXX
27 #include <svx/fmmodel.hxx>
28 #endif
29 
30 class SwDoc;
31 class SwDocShell;
32 
33 //==================================================================
34 
35 class SwDrawModel : public FmFormModel
36 {
37 	SwDoc* pDoc;
38 public:
39 	SwDrawModel( SwDoc* pDoc );
40 	~SwDrawModel();
41 
GetDoc() const42 	const SwDoc& GetDoc() const	{ return *pDoc; }
GetDoc()43 		  SwDoc& GetDoc()      	{ return *pDoc; }
44 
45 	virtual SdrPage* AllocPage(FASTBOOL bMasterPage);
46 
47 	// fuers "load on demand" von Grafiken im DrawingLayer
48 	virtual SvStream* GetDocumentStream( SdrDocumentStreamInfo& rInfo ) const;
49 
50 	// fuers Speicher von Rechtecken als Control-Ersatz fuker Versionen < 5.0
51 	virtual SdrLayerID GetControlExportLayerId( const SdrObject & ) const;
52 
53 protected:
54     // --> OD 2006-03-01 #b6382898#
55     // overload of <SdrModel::createUnoModel()> is needed to provide corresponding uno model.
56     virtual ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > createUnoModel();
57     // <--
58 };
59 
60 
61 #endif
62