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 _ACCPAGE_HXX 28 #define _ACCPAGE_HXX 29 30 #ifndef _ACCCONTEXT_HXX 31 #include "acccontext.hxx" 32 #endif 33 34 35 /** 36 * accessibility implementation for the page (SwPageFrm) 37 * The page is _only_ visible in the page preview. For the regular 38 * document view, it doesn't make sense to add this additional element 39 * into the hierarchy. For the page preview, however, the page is the 40 * important. 41 */ 42 class SwAccessiblePage : public SwAccessibleContext 43 { 44 sal_Bool bIsSelected; // protected by base class mutex 45 46 sal_Bool IsSelected(); 47 48 using SwAccessibleFrame::GetBounds; 49 50 protected: 51 52 // return the bounding box for the page in page preview mode 53 SwRect GetBounds( /* const SwFrm *pFrm =0 */ ); 54 55 // Set states for getAccessibleStateSet. 56 // This drived class additionaly sets 57 // FOCUSABLE(1) and FOCUSED(+) 58 virtual void GetStates( ::utl::AccessibleStateSetHelper& rStateSet ); 59 60 virtual void _InvalidateCursorPos(); 61 virtual void _InvalidateFocus(); 62 63 virtual ~SwAccessiblePage(); 64 65 public: 66 // convenience constructor to avoid typecast; 67 // may only be called with SwPageFrm argument 68 SwAccessiblePage( SwAccessibleMap* pInitMap, const SwFrm* pFrame ); 69 70 71 72 // 73 // XAccessibleContext methods that need to be overridden 74 // 75 76 virtual ::rtl::OUString SAL_CALL getAccessibleDescription (void) 77 throw (::com::sun::star::uno::RuntimeException); 78 79 // 80 // XServiceInfo 81 // 82 83 virtual ::rtl::OUString SAL_CALL getImplementationName (void) 84 throw (::com::sun::star::uno::RuntimeException); 85 virtual sal_Bool SAL_CALL supportsService ( 86 const ::rtl::OUString& sServiceName) 87 throw (::com::sun::star::uno::RuntimeException); 88 virtual ::com::sun::star::uno::Sequence< ::rtl::OUString> SAL_CALL 89 getSupportedServiceNames (void) 90 throw (::com::sun::star::uno::RuntimeException); 91 92 //===== XTypeProvider ==================================================== 93 virtual ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId( ) throw(::com::sun::star::uno::RuntimeException); 94 95 virtual sal_Bool HasCursor(); // required by map to remember that object 96 }; 97 98 #endif 99 100