Bump version to 4.3-4
[LibreOffice.git] / sc / inc / refhint.hxx
bloba61e4b689c9f1fc7573c4539fdfac163f7a62b2d
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_REFHINT_HXX
11 #define INCLUDED_SC_INC_REFHINT_HXX
13 #include "address.hxx"
14 #include "simplehintids.hxx"
16 namespace sc {
18 class RefHint : public SfxSimpleHint
20 public:
21 enum Type {
22 Moved,
23 ColumnReordered,
24 RowReordered,
25 StartListening,
26 StopListening
29 private:
30 Type meType;
32 RefHint(); // disabled
34 protected:
35 RefHint( Type eType );
37 public:
38 virtual ~RefHint() = 0;
40 Type getType() const;
43 class RefMovedHint : public RefHint
45 ScRange maRange;
46 ScAddress maMoveDelta;
48 public:
50 RefMovedHint( const ScRange& rRange, const ScAddress& rMove );
51 virtual ~RefMovedHint();
53 /**
54 * Get the source range from which the references have moved.
56 const ScRange& getRange() const;
58 /**
59 * Get the movement vector.
61 const ScAddress& getDelta() const;
64 class RefColReorderHint : public RefHint
66 const sc::ColRowReorderMapType& mrColMap;
67 SCTAB mnTab;
68 SCROW mnRow1;
69 SCROW mnRow2;
71 public:
72 RefColReorderHint( const sc::ColRowReorderMapType& rColMap, SCTAB nTab, SCROW nRow1, SCROW nRow2 );
73 virtual ~RefColReorderHint();
75 const sc::ColRowReorderMapType& getColMap() const;
77 SCTAB getTab() const;
78 SCROW getStartRow() const;
79 SCROW getEndRow() const;
82 class RefRowReorderHint : public RefHint
84 const sc::ColRowReorderMapType& mrRowMap;
85 SCTAB mnTab;
86 SCCOL mnCol1;
87 SCCOL mnCol2;
89 public:
90 RefRowReorderHint( const sc::ColRowReorderMapType& rRowMap, SCTAB nTab, SCCOL nCol1, SCCOL nCol2 );
91 virtual ~RefRowReorderHint();
93 const sc::ColRowReorderMapType& getRowMap() const;
95 SCTAB getTab() const;
96 SCCOL getStartColumn() const;
97 SCCOL getEndColumn() const;
100 class RefStartListeningHint : public RefHint
102 public:
103 RefStartListeningHint();
104 virtual ~RefStartListeningHint();
107 class RefStopListeningHint : public RefHint
109 public:
110 RefStopListeningHint();
111 virtual ~RefStopListeningHint();
116 #endif
118 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */