1 /************************************************************************* 2 * 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * Copyright 2000, 2010 Oracle and/or its affiliates. 6 * 7 * OpenOffice.org - a multi-platform office productivity suite 8 * 9 * This file is part of OpenOffice.org. 10 * 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. 14 * 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). 20 * 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. 25 * 26 ************************************************************************/ 27 #ifndef _ACCTEXTFRAME_HXX 28 #define _ACCTEXTFRAME_HXX 29 #include "accframebase.hxx" 30 31 class SwFlyFrm; 32 namespace utl { class AccessibleRelationSetHelper; } 33 namespace com { namespace star { 34 namespace accessibility { struct AccessibleRelation; } 35 } } 36 37 class SwAccessibleTextFrame : public SwAccessibleFrameBase 38 { 39 private: 40 // --> OD 2009-07-14 #i73249# 41 ::rtl::OUString msTitle; 42 ::rtl::OUString msDesc; 43 // <-- 44 45 protected: 46 47 virtual ~SwAccessibleTextFrame(); 48 49 virtual void Modify( const SfxPoolItem* pOld, const SfxPoolItem *pNew); 50 51 public: 52 53 SwAccessibleTextFrame( SwAccessibleMap* pInitMap, const SwFlyFrm* pFlyFrm ); 54 55 //===== XAccessibleContext ============================================== 56 57 // --> OD 2009-07-14 #i73249# 58 /// Return the object's current name. 59 virtual ::rtl::OUString SAL_CALL 60 getAccessibleName (void) 61 throw (::com::sun::star::uno::RuntimeException); 62 // <-- 63 /// Return this object's description. 64 virtual ::rtl::OUString SAL_CALL 65 getAccessibleDescription (void) 66 throw (com::sun::star::uno::RuntimeException); 67 68 //===== XServiceInfo ==================================================== 69 70 /** Returns an identifier for the implementation of this object. 71 */ 72 virtual ::rtl::OUString SAL_CALL 73 getImplementationName (void) 74 throw (::com::sun::star::uno::RuntimeException); 75 76 /** Return whether the specified service is supported by this class. 77 */ 78 virtual sal_Bool SAL_CALL 79 supportsService (const ::rtl::OUString& sServiceName) 80 throw (::com::sun::star::uno::RuntimeException); 81 82 /** Returns a list of all supported services. In this case that is just 83 the AccessibleContext service. 84 */ 85 virtual ::com::sun::star::uno::Sequence< ::rtl::OUString> SAL_CALL 86 getSupportedServiceNames (void) 87 throw (::com::sun::star::uno::RuntimeException); 88 89 //====== XTypeProvider ==================================================== 90 virtual ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId( ) throw(::com::sun::star::uno::RuntimeException); 91 92 93 //===== XAccessibleContext::getAccessibleRelationSet ==================== 94 95 // text frame may have accessible relations to their 96 // predocesor/successor frames 97 98 private: 99 // helper methods for getAccessibleRelationSet: 100 SwFlyFrm* getFlyFrm() const; 101 102 com::sun::star::accessibility::AccessibleRelation makeRelation( 103 sal_Int16 nType, const SwFlyFrm* pFrm ); 104 105 public: 106 107 virtual ::com::sun::star::uno::Reference< 108 ::com::sun::star::accessibility::XAccessibleRelationSet> SAL_CALL 109 getAccessibleRelationSet (void) 110 throw (::com::sun::star::uno::RuntimeException); 111 }; 112 113 114 #endif 115