LibreOffice Module sw (master) 1
SwUndoPageDesc.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#ifndef INCLUDED_SW_SOURCE_CORE_INC_SWUNDOPAGEDESC_HXX
21#define INCLUDED_SW_SOURCE_CORE_INC_SWUNDOPAGEDESC_HXX
22
23#include <undobj.hxx>
24#include <pagedesc.hxx>
25
26class SwDoc;
27
28class SwUndoPageDesc final : public SwUndo
29{
33
34 // To avoid duplication of (header/footer)content nodes for simple page desc changes
35 void ExchangeContentNodes( SwPageDesc& rSource, SwPageDesc &rDest );
36
37public:
38 SwUndoPageDesc(const SwPageDesc & aOld, const SwPageDesc & aNew,
39 SwDoc * pDoc);
40 virtual ~SwUndoPageDesc() override;
41
42 virtual void UndoImpl( ::sw::UndoRedoContext & ) override;
43 virtual void RedoImpl( ::sw::UndoRedoContext & ) override;
44
45 virtual SwRewriter GetRewriter() const override;
46};
47
48class SwUndoPageDescCreate final : public SwUndo
49{
53
54 void DoImpl();
55
56public:
57 SwUndoPageDescCreate(const SwPageDesc * pNew, SwDoc * pDoc);
58 virtual ~SwUndoPageDescCreate() override;
59
60 virtual void UndoImpl( ::sw::UndoRedoContext & ) override;
61 virtual void RedoImpl( ::sw::UndoRedoContext & ) override;
62 virtual void RepeatImpl( ::sw::RepeatContext & ) override;
63
64 virtual SwRewriter GetRewriter() const override;
65};
66
67class SwUndoPageDescDelete final : public SwUndo
68{
71
72 void DoImpl();
73
74public:
75 SwUndoPageDescDelete(const SwPageDesc & aOld, SwDoc * pDoc);
76 virtual ~SwUndoPageDescDelete() override;
77
78 virtual void UndoImpl( ::sw::UndoRedoContext & ) override;
79 virtual void RedoImpl( ::sw::UndoRedoContext & ) override;
80 virtual void RepeatImpl( ::sw::RepeatContext & ) override;
81
82 virtual SwRewriter GetRewriter() const override;
83};
84#endif // _SW_UNDO_PAGE_DESC_CHANGE_HXX
85
86/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
Definition: doc.hxx:194
const SwPageDesc * m_pDesc
virtual void UndoImpl(::sw::UndoRedoContext &) override
virtual ~SwUndoPageDescCreate() override
SwUndoPageDescCreate(const SwPageDesc *pNew, SwDoc *pDoc)
virtual SwRewriter GetRewriter() const override
Returns the rewriter for this object.
virtual void RepeatImpl(::sw::RepeatContext &) override
virtual void RedoImpl(::sw::UndoRedoContext &) override
virtual ~SwUndoPageDescDelete() override
virtual void UndoImpl(::sw::UndoRedoContext &) override
virtual void RepeatImpl(::sw::RepeatContext &) override
SwUndoPageDescDelete(const SwPageDesc &aOld, SwDoc *pDoc)
virtual SwRewriter GetRewriter() const override
Returns the rewriter for this object.
virtual void RedoImpl(::sw::UndoRedoContext &) override
void ExchangeContentNodes(SwPageDesc &rSource, SwPageDesc &rDest)
SwPageDescExt m_aNew
virtual ~SwUndoPageDesc() override
SwPageDescExt m_aOld
virtual SwRewriter GetRewriter() const override
Returns the rewriter for this object.
SwUndoPageDesc(const SwPageDesc &aOld, const SwPageDesc &aNew, SwDoc *pDoc)
virtual void RedoImpl(::sw::UndoRedoContext &) override
virtual void UndoImpl(::sw::UndoRedoContext &) override