Stop leaking all ScPostIt instances.
[LibreOffice.git] / sc / source / core / tool / hints.cxx
blob45c9f75eeb7bdde9d770d102f8c8683b620619d0
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/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
20 #include "hints.hxx"
22 TYPEINIT1(ScPaintHint, SfxHint);
23 TYPEINIT1(ScUpdateRefHint, SfxHint);
24 TYPEINIT1(ScPointerChangedHint, SfxHint);
25 TYPEINIT1(ScLinkRefreshedHint, SfxHint);
26 TYPEINIT1(ScAutoStyleHint, SfxHint);
27 TYPEINIT1(ScDBRangeRefreshedHint, SfxHint);
28 TYPEINIT1(ScDataPilotModifiedHint, SfxHint);
30 // ScPaintHint - info what has to be repainted
32 ScPaintHint::ScPaintHint( const ScRange& rRng, sal_uInt16 nPaint ) :
33 aRange( rRng ),
34 nParts( nPaint ),
35 bPrint( sal_True )
39 ScPaintHint::~ScPaintHint()
43 // ScUpdateRefHint - update references
45 ScUpdateRefHint::ScUpdateRefHint( UpdateRefMode eMode, const ScRange& rR,
46 SCsCOL nX, SCsROW nY, SCsTAB nZ ) :
47 eUpdateRefMode( eMode ),
48 aRange( rR ),
49 nDx( nX ),
50 nDy( nY ),
51 nDz( nZ )
55 ScUpdateRefHint::~ScUpdateRefHint()
59 // ScPointerChangedHint - pointer has become invalid
61 ScPointerChangedHint::~ScPointerChangedHint()
65 // ScLinkRefreshedHint - a link has been refreshed
67 ScLinkRefreshedHint::ScLinkRefreshedHint() :
68 nLinkType( SC_LINKREFTYPE_NONE ),
69 nDdeMode( 0 )
73 ScLinkRefreshedHint::~ScLinkRefreshedHint()
77 void ScLinkRefreshedHint::SetSheetLink( const OUString& rSourceUrl )
79 nLinkType = SC_LINKREFTYPE_SHEET;
80 aUrl = rSourceUrl;
83 void ScLinkRefreshedHint::SetDdeLink(
84 const OUString& rA, const OUString& rT, const OUString& rI, sal_uInt8 nM )
86 nLinkType = SC_LINKREFTYPE_DDE;
87 aDdeAppl = rA;
88 aDdeTopic = rT;
89 aDdeItem = rI;
90 nDdeMode = nM;
93 void ScLinkRefreshedHint::SetAreaLink( const ScAddress& rPos )
95 nLinkType = SC_LINKREFTYPE_AREA;
96 aDestPos = rPos;
99 // ScAutoStyleHint - STYLE() function has been called
101 ScAutoStyleHint::ScAutoStyleHint( const ScRange& rR, const OUString& rSt1,
102 sal_uLong nT, const OUString& rSt2 ) :
103 aRange( rR ),
104 aStyle1( rSt1 ),
105 aStyle2( rSt2 ),
106 nTimeout( nT )
110 ScAutoStyleHint::~ScAutoStyleHint()
114 ScDBRangeRefreshedHint::ScDBRangeRefreshedHint( const ScImportParam& rP )
115 : aParam(rP)
118 ScDBRangeRefreshedHint::~ScDBRangeRefreshedHint()
122 ScDataPilotModifiedHint::ScDataPilotModifiedHint( const OUString& rName )
123 : maName(rName)
126 ScDataPilotModifiedHint::~ScDataPilotModifiedHint()
130 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */