merged tag ooo/OOO330_m14
[LibreOffice.git] / chart2 / source / inc / ModifyListenerCallBack.hxx
blob3833806d185e05b5118f9b3e378c173c6a3fe86d
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2000, 2010 Oracle and/or its affiliates.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * This file is part of OpenOffice.org.
11 * OpenOffice.org is free software: you can redistribute it and/or modify
12 * it under the terms of the GNU Lesser General Public License version 3
13 * only, as published by the Free Software Foundation.
15 * OpenOffice.org is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU Lesser General Public License version 3 for more details
19 * (a copy is included in the LICENSE file that accompanied this code).
21 * You should have received a copy of the GNU Lesser General Public License
22 * version 3 along with OpenOffice.org. If not, see
23 * <http://www.openoffice.org/license.html>
24 * for a copy of the LGPLv3 License.
26 ************************************************************************/
28 #ifndef CHART2_MODIFYLISTENERCALLBACK_HXX
29 #define CHART2_MODIFYLISTENERCALLBACK_HXX
31 // header for class Link
32 #include <tools/link.hxx>
33 #include <com/sun/star/util/XModifyBroadcaster.hpp>
34 #include <com/sun/star/util/XModifyListener.hpp>
35 #include "charttoolsdllapi.hxx"
37 namespace chart {
39 /** Use this class as a member if you want to listen on a XModifyBroadcaster
40 without becoming a XModifyListener yourself
43 class ModifyListenerCallBack_impl;
45 class OOO_DLLPUBLIC_CHARTTOOLS ModifyListenerCallBack
47 public:
48 explicit ModifyListenerCallBack( const Link& rCallBack );
50 virtual ~ModifyListenerCallBack();
52 void startListening( const ::com::sun::star::uno::Reference< ::com::sun::star::util::XModifyBroadcaster >& xBroadcaster );
53 SAL_DLLPRIVATE void stopListening();
55 private: //methods
56 SAL_DLLPRIVATE ModifyListenerCallBack();
57 SAL_DLLPRIVATE ModifyListenerCallBack( const ModifyListenerCallBack& );
59 private: //member
60 ModifyListenerCallBack_impl* pModifyListener_impl;
61 ::com::sun::star::uno::Reference<
62 ::com::sun::star::util::XModifyListener > m_xModifyListener;
65 } // namespace chart
67 #endif