update credits
[LibreOffice.git] / sw / inc / dlelstnr.hxx
blob8ce12ebc54f034e98d4daf51ef1866cfa2b323ae
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 #ifndef _DLELSTNR_HXX_
21 #define _DLELSTNR_HXX_
23 #include <cppuhelper/weak.hxx>
24 #include <com/sun/star/linguistic2/XDictionaryListEventListener.hpp>
25 #include <com/sun/star/linguistic2/XLinguServiceEventListener.hpp>
26 #include <com/sun/star/frame/XTerminateListener.hpp>
27 #include <com/sun/star/frame/XDesktop2.hpp>
28 #include <cppuhelper/implbase2.hxx> // helper for implementations
31 namespace com { namespace sun { namespace star {
32 namespace linguistic2 {
33 class XDictionaryList;
34 class XLinguServiceManager2;
35 class XProofreadingIterator;
37 namespace frame {
38 class XTerminateListener;
40 } } }
42 ///////////////////////////////////////////////////////////////////////////
43 // SwLinguServiceEventListener
44 // is a EventListener that triggers spellchecking
45 // and hyphenation when relevant changes (to the
46 // dictionaries of the dictionary list, or properties) were made.
49 class SwLinguServiceEventListener :
50 public cppu::WeakImplHelper2
52 com::sun::star::linguistic2::XLinguServiceEventListener,
53 com::sun::star::frame::XTerminateListener
56 com::sun::star::uno::Reference<
57 com::sun::star::frame::XDesktop2 > xDesktop;
58 com::sun::star::uno::Reference<
59 com::sun::star::linguistic2::XLinguServiceManager2 > xLngSvcMgr;
60 com::sun::star::uno::Reference<
61 com::sun::star::linguistic2::XProofreadingIterator > xGCIterator;
63 /// disallow use of copy-constructor and assignment operator
64 SwLinguServiceEventListener(const SwLinguServiceEventListener &);
65 SwLinguServiceEventListener & operator = (const SwLinguServiceEventListener &);
67 public:
68 SwLinguServiceEventListener();
69 virtual ~SwLinguServiceEventListener();
71 /// XEventListener
72 virtual void SAL_CALL disposing( const ::com::sun::star::lang::EventObject& rEventObj ) throw(::com::sun::star::uno::RuntimeException);
74 /// XDictionaryListEventListener
75 virtual void SAL_CALL processDictionaryListEvent( const ::com::sun::star::linguistic2::DictionaryListEvent& rDicListEvent) throw( ::com::sun::star::uno::RuntimeException );
77 /// XLinguServiceEventListener
78 virtual void SAL_CALL processLinguServiceEvent( const ::com::sun::star::linguistic2::LinguServiceEvent& rLngSvcEvent ) throw(::com::sun::star::uno::RuntimeException);
80 /// XTerminateListener
81 virtual void SAL_CALL queryTermination( const ::com::sun::star::lang::EventObject& rEventObj ) throw(::com::sun::star::frame::TerminationVetoException, ::com::sun::star::uno::RuntimeException);
82 virtual void SAL_CALL notifyTermination( const ::com::sun::star::lang::EventObject& rEventObj ) throw(::com::sun::star::uno::RuntimeException);
86 #endif
88 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */