LibreOffice Module sd (master) 1
undopage.hxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 *
9 * This file incorporates work covered by the following license notice:
10 *
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 */
19
20#pragma once
21
22#include <tools/gen.hxx>
23#include <vcl/prntypes.hxx>
24
25#include <sdundo.hxx>
26
27class SdDrawDocument;
28class SdPage;
29
30/************************************************************************/
31
33{
35
37 sal_Int32 mnOldLeft;
38 sal_Int32 mnOldRight;
39 sal_Int32 mnOldUpper;
40 sal_Int32 mnOldLower;
42 sal_uInt16 mnOldPaperBin;
44
46 sal_Int32 mnNewLeft;
47 sal_Int32 mnNewRight;
48 sal_Int32 mnNewUpper;
49 sal_Int32 mnNewLower;
52 sal_uInt16 mnNewPaperBin;
54
55public:
57 SdPage* pThePage,
58 const Size& rOldSz,
59 sal_Int32 nOldLft,
60 sal_Int32 nOldRgt,
61 sal_Int32 nOldUpr,
62 sal_Int32 nOldLwr,
63 Orientation eOldOrient,
64 sal_uInt16 nOPaperBin,
65 bool bOFullSize,
66
67 const Size& rNewSz,
68 sal_Int32 nNewLft,
69 sal_Int32 nNewRgt,
70 sal_Int32 nNewUpr,
71 sal_Int32 nNewLwr,
72 bool bNewScl,
73 Orientation eNewOrient,
74 sal_uInt16 nNPaperBin,
75 bool bNFullSize
76 ) :
77 SdUndoAction(pDoc),
78 mpPage (pThePage),
79 maOldSize (rOldSz),
80 mnOldLeft (nOldLft),
81 mnOldRight (nOldRgt),
82 mnOldUpper (nOldUpr),
83 mnOldLower (nOldLwr),
84 meOldOrientation(eOldOrient),
85 mnOldPaperBin (nOPaperBin),
86 mbOldFullSize (bOFullSize),
87
88 maNewSize (rNewSz),
89 mnNewLeft (nNewLft),
90 mnNewRight (nNewRgt),
91 mnNewUpper (nNewUpr),
92 mnNewLower (nNewLwr),
93 mbNewScale (bNewScl),
94 meNewOrientation(eNewOrient),
95 mnNewPaperBin (nNPaperBin),
96 mbNewFullSize (bNFullSize)
97
98 {}
99 virtual ~SdPageFormatUndoAction() override;
100
101 virtual void Undo() override;
102 virtual void Redo() override;
103};
104
105/************************************************************************/
106
108{
110
111 sal_Int32 mnOldLeft;
112 sal_Int32 mnOldRight;
113 sal_Int32 mnNewLeft;
114 sal_Int32 mnNewRight;
115
116public:
118 sal_Int32 nOldLft, sal_Int32 nOldRgt,
119 sal_Int32 nNewLft, sal_Int32 nNewRgt ) :
120 SdUndoAction(pDoc),
121 mpPage (pThePage),
122 mnOldLeft (nOldLft),
123 mnOldRight (nOldRgt),
124 mnNewLeft (nNewLft),
125 mnNewRight (nNewRgt)
126 {}
127 virtual ~SdPageLRUndoAction() override;
128
129 virtual void Undo() override;
130 virtual void Redo() override;
131};
132
133/************************************************************************/
134
136{
138
139 sal_Int32 mnOldUpper;
140 sal_Int32 mnOldLower;
141 sal_Int32 mnNewUpper;
142 sal_Int32 mnNewLower;
143
144public:
146 sal_Int32 nOldUpr, sal_Int32 nOldLwr,
147 sal_Int32 nNewUpr, sal_Int32 nNewLwr ) :
148 SdUndoAction(pDoc),
149 mpPage (pThePage),
150 mnOldUpper (nOldUpr),
151 mnOldLower (nOldLwr),
152 mnNewUpper (nNewUpr),
153 mnNewLower (nNewLwr)
154 {}
155 virtual ~SdPageULUndoAction() override;
156
157 virtual void Undo() override;
158 virtual void Redo() override;
159};
160
161/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
virtual void Undo() override
Definition: undopage.cxx:28
virtual ~SdPageFormatUndoAction() override
Definition: undopage.cxx:24
Orientation meNewOrientation
Definition: undopage.hxx:51
SdPageFormatUndoAction(SdDrawDocument *pDoc, SdPage *pThePage, const Size &rOldSz, sal_Int32 nOldLft, sal_Int32 nOldRgt, sal_Int32 nOldUpr, sal_Int32 nOldLwr, Orientation eOldOrient, sal_uInt16 nOPaperBin, bool bOFullSize, const Size &rNewSz, sal_Int32 nNewLft, sal_Int32 nNewRgt, sal_Int32 nNewUpr, sal_Int32 nNewLwr, bool bNewScl, Orientation eNewOrient, sal_uInt16 nNPaperBin, bool bNFullSize)
Definition: undopage.hxx:56
virtual void Redo() override
Definition: undopage.cxx:46
Orientation meOldOrientation
Definition: undopage.hxx:41
sal_uInt16 mnOldPaperBin
Definition: undopage.hxx:42
sal_uInt16 mnNewPaperBin
Definition: undopage.hxx:52
sal_Int32 mnOldRight
Definition: undopage.hxx:112
sal_Int32 mnNewLeft
Definition: undopage.hxx:113
SdPageLRUndoAction(SdDrawDocument *pDoc, SdPage *pThePage, sal_Int32 nOldLft, sal_Int32 nOldRgt, sal_Int32 nNewLft, sal_Int32 nNewRgt)
Definition: undopage.hxx:117
virtual void Redo() override
Definition: undopage.cxx:74
virtual void Undo() override
Definition: undopage.cxx:68
sal_Int32 mnOldLeft
Definition: undopage.hxx:111
virtual ~SdPageLRUndoAction() override
Definition: undopage.cxx:64
sal_Int32 mnNewRight
Definition: undopage.hxx:114
sal_Int32 mnOldLower
Definition: undopage.hxx:140
SdPageULUndoAction(SdDrawDocument *pDoc, SdPage *pThePage, sal_Int32 nOldUpr, sal_Int32 nOldLwr, sal_Int32 nNewUpr, sal_Int32 nNewLwr)
Definition: undopage.hxx:145
virtual void Redo() override
UL-Redo()
Definition: undopage.cxx:93
sal_Int32 mnNewLower
Definition: undopage.hxx:142
sal_Int32 mnOldUpper
Definition: undopage.hxx:139
virtual ~SdPageULUndoAction() override
Definition: undopage.cxx:80
sal_Int32 mnNewUpper
Definition: undopage.hxx:141
virtual void Undo() override
Definition: undopage.cxx:84
Orientation