1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
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/.
24 * Temporarily switch on/off auto calculation mode.
26 class SC_DLLPUBLIC AutoCalcSwitch
31 AutoCalcSwitch(AutoCalcSwitch
const&) = delete;
32 AutoCalcSwitch(AutoCalcSwitch
&&) = delete;
33 AutoCalcSwitch
& operator=(AutoCalcSwitch
const&) = delete;
34 AutoCalcSwitch
& operator=(AutoCalcSwitch
&&) = delete;
37 AutoCalcSwitch(ScDocument
& rDoc
, bool bAutoCalc
);
41 class ExpandRefsSwitch
47 ExpandRefsSwitch(ScDocument
& rDoc
, bool bExpandRefs
);
51 class SC_DLLPUBLIC UndoSwitch
57 UndoSwitch(ScDocument
& rDoc
, bool bUndo
);
67 IdleSwitch(ScDocument
& rDoc
, bool bEnableIdle
);
71 /// Wrapper for ScDocument::DelayFormulaGrouping()
72 class DelayFormulaGroupingSwitch
75 bool const mbOldValue
;
78 DelayFormulaGroupingSwitch(ScDocument
& rDoc
, bool delay
);
79 ~DelayFormulaGroupingSwitch() COVERITY_NOEXCEPT_FALSE
;
83 /// Wrapper for ScDocument::EnableDelayStartListeningFormulaCells()
84 class DelayStartListeningFormulaCells
87 bool const mbOldValue
;
90 DelayStartListeningFormulaCells(ScColumn
& column
, bool delay
);
91 DelayStartListeningFormulaCells(ScColumn
& column
);
92 DelayStartListeningFormulaCells(const DelayStartListeningFormulaCells
&) = delete;
93 ~DelayStartListeningFormulaCells();
97 /// Wrapper for ScDocument::EnableDelayDeletingBroadcasters()
98 class DelayDeletingBroadcasters
101 const bool mOldValue
;
104 DelayDeletingBroadcasters(ScDocument
& doc
);
105 ~DelayDeletingBroadcasters();
109 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */