1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: hints.hxx,v $
10 * $Revision: 1.5.32.2 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
35 #include "address.hxx"
36 #include <svtools/hint.hxx>
38 // ---------------------------------------------------------------------------
40 class ScPaintHint
: public SfxHint
44 BOOL bPrint
; // Flag, ob auch Druck/Vorschau betroffen ist
46 ScPaintHint(); // disabled
50 ScPaintHint( const ScRange
& rRng
, USHORT nPaint
= PAINT_ALL
);
53 void SetPrintFlag(BOOL bSet
) { bPrint
= bSet
; }
55 const ScRange
& GetRange() const { return aRange
; }
56 SCCOL
GetStartCol() const { return aRange
.aStart
.Col(); }
57 SCROW
GetStartRow() const { return aRange
.aStart
.Row(); }
58 SCTAB
GetStartTab() const { return aRange
.aStart
.Tab(); }
59 SCCOL
GetEndCol() const { return aRange
.aEnd
.Col(); }
60 SCROW
GetEndRow() const { return aRange
.aEnd
.Row(); }
61 SCTAB
GetEndTab() const { return aRange
.aEnd
.Tab(); }
62 USHORT
GetParts() const { return nParts
; }
63 BOOL
GetPrintFlag() const { return bPrint
; }
67 class ScUpdateRefHint
: public SfxHint
69 UpdateRefMode eUpdateRefMode
;
78 ScUpdateRefHint( UpdateRefMode eMode
, const ScRange
& rR
,
79 SCsCOL nX
, SCsROW nY
, SCsTAB nZ
);
82 UpdateRefMode
GetMode() const { return eUpdateRefMode
; }
83 const ScRange
& GetRange() const { return aRange
; }
84 SCsCOL
GetDx() const { return nDx
; }
85 SCsROW
GetDy() const { return nDy
; }
86 SCsTAB
GetDz() const { return nDz
; }
90 #define SC_POINTERCHANGED_NUMFMT 1
92 class ScPointerChangedHint
: public SfxHint
99 //UNUSED2008-05 ScPointerChangedHint( USHORT nF );
100 ~ScPointerChangedHint();
102 USHORT
GetFlags() const { return nFlags
; }
106 //! move ScLinkRefreshedHint to a different file?
108 #define SC_LINKREFTYPE_NONE 0
109 #define SC_LINKREFTYPE_SHEET 1
110 #define SC_LINKREFTYPE_AREA 2
111 #define SC_LINKREFTYPE_DDE 3
113 class ScLinkRefreshedHint
: public SfxHint
115 USHORT nLinkType
; // SC_LINKREFTYPE_...
116 String aUrl
; // used for sheet links
117 String aDdeAppl
; // used for dde links:
121 ScAddress aDestPos
; // used to identify area links
122 //! also use source data for area links?
126 ScLinkRefreshedHint();
127 ~ScLinkRefreshedHint();
129 void SetSheetLink( const String
& rSourceUrl
);
130 void SetDdeLink( const String
& rA
, const String
& rT
, const String
& rI
, BYTE nM
);
131 void SetAreaLink( const ScAddress
& rPos
);
133 USHORT
GetLinkType() const { return nLinkType
; }
134 const String
& GetUrl() const { return aUrl
; }
135 const String
& GetDdeAppl() const { return aDdeAppl
; }
136 const String
& GetDdeTopic() const { return aDdeTopic
; }
137 const String
& GetDdeItem() const { return aDdeItem
; }
138 BYTE
GetDdeMode() const { return nDdeMode
; }
139 const ScAddress
& GetDestPos() const { return aDestPos
; }
143 //! move ScAutoStyleHint to a different file?
145 class ScAutoStyleHint
: public SfxHint
154 ScAutoStyleHint( const ScRange
& rR
, const String
& rSt1
,
155 ULONG nT
, const String
& rSt2
);
158 const ScRange
& GetRange() const { return aRange
; }
159 const String
& GetStyle1() const { return aStyle1
; }
160 UINT32
GetTimeout() const { return nTimeout
; }
161 const String
& GetStyle2() const { return aStyle2
; }
164 class ScDBRangeRefreshedHint
: public SfxHint
166 ScImportParam aParam
;
170 ScDBRangeRefreshedHint( const ScImportParam
& rP
);
171 ~ScDBRangeRefreshedHint();
173 const ScImportParam
& GetImportParam() const { return aParam
; }