xref: /aoo41x/main/sd/source/ui/inc/unmodpg.hxx (revision 67e470da)
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 _SD_UNMODPG_HXX
25 #define _SD_UNMODPG_HXX
26 
27 #include "sdundo.hxx"
28 #include "pres.hxx"
29 
30 class SdDrawDocument;
31 class SdPage;
32 
33 class ModifyPageUndoAction : public SdUndoAction
34 {
35 	SdPage*         mpPage;
36 	String          maOldName;
37 	String          maNewName;
38 	AutoLayout      meOldAutoLayout;
39 	AutoLayout      meNewAutoLayout;
40 	sal_Bool            mbOldBckgrndVisible;
41 	sal_Bool            mbNewBckgrndVisible;
42 	sal_Bool            mbOldBckgrndObjsVisible;
43 	sal_Bool            mbNewBckgrndObjsVisible;
44 
45 	String          maComment;
46 
47 public:
48 	TYPEINFO();
49 	ModifyPageUndoAction(
50 		SdDrawDocument*			pTheDoc,
51 		SdPage*					pThePage,
52 		String					aTheNewName,
53 		AutoLayout				eTheNewAutoLayout,
54 		sal_Bool					bTheNewBckgrndVisible,
55 		sal_Bool					bTheNewBckgrndObjsVisible);
56 
57 	virtual ~ModifyPageUndoAction();
58 	virtual void Undo();
59 	virtual void Redo();
60 
61 	virtual String GetComment() const;
62 };
63 
64 // --------------------------------------------------------------------
65 
66 class RenameLayoutTemplateUndoAction : public SdUndoAction
67 {
68 public:
69 	RenameLayoutTemplateUndoAction( SdDrawDocument* pDocument, const String& rOldLayoutName, const String& rNewLayoutName );
70 
71 	virtual void Undo();
72 	virtual void Redo();
73 
74 	virtual String GetComment() const;
75 
76 private:
77 	String maOldName;
78 	String maNewName;
79 	const String maComment;
80 };
81 
82 #endif      // _SD_UNMODPG_HXX
83 
84