update dev300-m58
[ooovba.git] / sd / source / ui / inc / AccessibleOutlineEditSource.hxx
blobce4ba45f5bb7d067f93b13ff706dfff272335ec4
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: AccessibleOutlineEditSource.hxx,v $
10 * $Revision: 1.8 $
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 ************************************************************************/
31 #ifndef SD_ACCESSIBILITY_ACCESSIBLE_OUTLINE_EDITSOURCE_HXX
32 #define SD_ACCESSIBILITY_ACCESSIBLE_OUTLINE_EDITSOURCE_HXX
34 #include <memory>
35 #include <vcl/svapp.hxx>
36 #include <svtools/brdcst.hxx>
37 #include <svtools/lstner.hxx>
38 #include <svx/unoedsrc.hxx>
39 #include <svx/editdata.hxx>
40 #include <svx/unoforou.hxx>
41 #include <svx/unoviwou.hxx>
43 class OutlinerView;
44 class SdrOutliner;
45 class SdrView;
46 class Window;
48 namespace accessibility
50 /** Implementation of the SvxEditSource interface in the SdOutlineView
52 This class connects the SdOutlineView and its EditEngine
53 outliner with the AccessibleTextHelper, which provides all
54 necessary functionality to make the outliner text accessible
56 @see SvxEditSource
57 @see SvxViewForwarder
59 class AccessibleOutlineEditSource : public SvxEditSource, public SvxViewForwarder, public SfxBroadcaster, public SfxListener
61 public:
62 /// Create an SvxEditSource interface for the given Outliner
63 AccessibleOutlineEditSource(
64 SdrOutliner& rOutliner,
65 SdrView& rView,
66 OutlinerView& rOutlView,
67 const ::Window& rViewWindow );
68 virtual ~AccessibleOutlineEditSource();
70 /// This method is disabled and always returns NULL
71 virtual SvxEditSource* Clone() const;
72 virtual SvxTextForwarder* GetTextForwarder();
73 virtual SvxViewForwarder* GetViewForwarder();
74 virtual SvxEditViewForwarder* GetEditViewForwarder( sal_Bool bCreate = sal_False );
75 virtual void UpdateData();
76 virtual SfxBroadcaster& GetBroadcaster() const;
78 // the view forwarder
79 virtual BOOL IsValid() const;
80 virtual Rectangle GetVisArea() const;
81 virtual Point LogicToPixel( const Point& rPoint, const MapMode& rMapMode ) const;
82 virtual Point PixelToLogic( const Point& rPoint, const MapMode& rMapMode ) const;
84 // SfxListener
85 virtual void Notify( SfxBroadcaster& rBC, const SfxHint& rHint );
87 private:
89 // declared, but not defined
90 AccessibleOutlineEditSource( const AccessibleOutlineEditSource& );
91 AccessibleOutlineEditSource& operator=( const AccessibleOutlineEditSource& );
93 DECL_LINK( NotifyHdl, EENotify* );
95 SdrView& mrView;
96 const ::Window& mrWindow;
97 SdrOutliner* mpOutliner;
98 OutlinerView* mpOutlinerView;
100 SvxOutlinerForwarder mTextForwarder;
101 SvxDrawOutlinerViewForwarder mViewForwarder;
105 } // end of namespace accessibility
107 #endif