Version 6.1.0.2, tag libreoffice-6.1.0.2
[LibreOffice.git] / sc / inc / scopetools.hxx
blobc246fa9171b8bef25f3c7fbb08651fb3c9ec36a4
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/.
8 */
10 #ifndef INCLUDED_SC_INC_SCOPETOOLS_HXX
11 #define INCLUDED_SC_INC_SCOPETOOLS_HXX
13 #include "scdllapi.h"
14 #include <vcl/vclptr.hxx>
16 class ScDocument;
17 namespace vcl { class Window; }
19 namespace sc {
21 /**
22 * Temporarily switch on/off auto calculation mode.
24 class SC_DLLPUBLIC AutoCalcSwitch
26 ScDocument& mrDoc;
27 bool mbOldValue;
28 public:
29 AutoCalcSwitch(ScDocument& rDoc, bool bAutoCalc);
30 ~AutoCalcSwitch();
33 class SC_DLLPUBLIC ExpandRefsSwitch
35 ScDocument& mrDoc;
36 bool mbOldValue;
37 public:
38 ExpandRefsSwitch(ScDocument& rDoc, bool bExpandRefs);
39 ~ExpandRefsSwitch();
42 class SC_DLLPUBLIC UndoSwitch
44 ScDocument& mrDoc;
45 bool mbOldValue;
46 public:
47 UndoSwitch(ScDocument& rDoc, bool bUndo);
48 ~UndoSwitch();
51 class SC_DLLPUBLIC IdleSwitch
53 ScDocument& mrDoc;
54 bool mbOldValue;
55 public:
56 IdleSwitch(ScDocument& rDoc, bool bEnableIdle);
57 ~IdleSwitch();
60 class WaitPointerSwitch
62 VclPtr<vcl::Window> mpFrameWin;
63 public:
64 WaitPointerSwitch(vcl::Window* pWin);
65 ~WaitPointerSwitch();
70 #endif
72 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */