update emoji autocorrect entries from po-files
[LibreOffice.git] / sw / inc / SwUndoField.hxx
blob2a8a6b4540d99d18e610bf00d6a77456dcb6d779
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
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/.
9 * This file incorporates work covered by the following license notice:
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 .
19 #ifndef INCLUDED_SW_INC_SWUNDOFIELD_HXX
20 #define INCLUDED_SW_INC_SWUNDOFIELD_HXX
22 #include <undobj.hxx>
24 #include <com/sun/star/uno/Any.h>
26 class SwDoc;
27 class SwField;
28 class SwMsgPoolItem;
30 class SwUndoField : public SwUndo
32 sal_uLong nNodeIndex;
33 sal_Int32 nOffset;
35 protected:
36 SwDoc * pDoc;
37 SwPosition GetPosition();
39 public:
40 SwUndoField(const SwPosition & rPos, SwUndoId nId = UNDO_FIELD );
41 virtual ~SwUndoField();
44 class SwUndoFieldFromDoc : public SwUndoField
46 SwField * pOldField, * pNewField;
47 SwMsgPoolItem * pHint;
48 bool bUpdate;
50 void DoImpl();
52 public:
53 SwUndoFieldFromDoc(const SwPosition & rPos, const SwField & aOldField,
54 const SwField & aNewField,
55 SwMsgPoolItem * pHint, bool bUpdate,
56 SwUndoId nId = UNDO_FIELD );
58 virtual ~SwUndoFieldFromDoc();
60 virtual void UndoImpl( ::sw::UndoRedoContext & ) SAL_OVERRIDE;
61 virtual void RedoImpl( ::sw::UndoRedoContext & ) SAL_OVERRIDE;
62 virtual void RepeatImpl( ::sw::RepeatContext & ) SAL_OVERRIDE;
65 class SwUndoFieldFromAPI : public SwUndoField
67 com::sun::star::uno::Any aOldVal, aNewVal;
68 sal_uInt16 nWhich;
70 void DoImpl();
72 public:
73 SwUndoFieldFromAPI(const SwPosition & rPos,
74 const com::sun::star::uno::Any & rOldVal,
75 const com::sun::star::uno::Any & rNewVal,
76 sal_uInt16 nWhich);
77 virtual ~SwUndoFieldFromAPI();
79 virtual void UndoImpl( ::sw::UndoRedoContext & ) SAL_OVERRIDE;
80 virtual void RedoImpl( ::sw::UndoRedoContext & ) SAL_OVERRIDE;
81 virtual void RepeatImpl( ::sw::RepeatContext & ) SAL_OVERRIDE;
84 #endif // INCLUDED_SW_INC_SWUNDOFIELD_HXX
86 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */