LibreOffice Module sc (master) 1
undomanager.hxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; fill-column: 100 -*- */
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#pragma once
10
12
13class SfxViewShell;
14class ScSimpleUndo;
15
17{
18public:
20
25 bool IsViewUndoActionIndependent(const SfxViewShell* pView, sal_uInt16& rOffset) const;
26
28 using SdrUndoManager::UndoWithContext;
29 using SdrUndoManager::RedoWithContext;
30
31private:
32 static std::optional<ScRange> getAffectedRangeFromUndo(const SfxUndoAction*);
33 static const ScSimpleUndo* getScSimpleUndo(const SfxUndoAction*);
34};
35
37{
38public:
39 void SetUndoOffset(size_t nUndoOffset) { m_nUndoOffset = nUndoOffset; }
40
41 size_t GetUndoOffset() override { return m_nUndoOffset; }
42
43private:
44 size_t m_nUndoOffset = 0;
45};
46
47/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */
size_t GetUndoOffset() override
Definition: undomanager.hxx:41
void SetUndoOffset(size_t nUndoOffset)
Definition: undomanager.hxx:39
#define SC_DLLPUBLIC
Definition: scdllapi.h:27