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 _ACCFRMOBJ_HXX 28 #define _ACCFRMOBJ_HXX 29 30 #include <sal/types.h> 31 32 class SwAccessibleMap; 33 class SwFrm; 34 class SdrObject; 35 class Window; 36 class SwRect; 37 38 namespace sw { namespace access { 39 40 class SwAccessibleChild 41 { 42 public: 43 SwAccessibleChild(); 44 explicit SwAccessibleChild( const SdrObject* pDrawObj ); 45 explicit SwAccessibleChild( const SwFrm* pFrm ); 46 explicit SwAccessibleChild( Window* pWindow ); 47 SwAccessibleChild( const SwFrm* pFrm, 48 const SdrObject* pDrawObj, 49 Window* pWindow ); 50 51 SwAccessibleChild( const SwAccessibleChild& r ); 52 SwAccessibleChild& operator=( const SwAccessibleChild& r ); 53 54 SwAccessibleChild& operator=( const SdrObject* pDrawObj ); 55 SwAccessibleChild& operator=( const SwFrm* pFrm ); 56 SwAccessibleChild& operator=( Window* pWindow ); 57 58 bool operator==( const SwAccessibleChild& r ) const; 59 60 bool IsValid() const; 61 62 const SwFrm* GetSwFrm() const; 63 const SdrObject* GetDrawObject() const; 64 Window* GetWindow() const; 65 66 const SwFrm* GetParent( const sal_Bool bInPagePreview ) const; 67 68 bool IsAccessible( sal_Bool bPagePreview ) const; 69 bool IsBoundAsChar() const; 70 71 bool IsVisibleChildrenOnly() const; 72 SwRect GetBox( const SwAccessibleMap& rAccMap ) const; 73 SwRect GetBounds( const SwAccessibleMap& rAccMap ) const; 74 75 /** indicating, if accessible child is included even, if the corresponding 76 object is not visible. 77 78 @author OD 79 */ 80 bool AlwaysIncludeAsChild() const; 81 82 private: 83 const SwFrm* mpFrm; 84 const SdrObject* mpDrawObj; 85 Window* mpWindow; 86 87 void Init( const SdrObject* pDrawObj ); 88 void Init( const SwFrm* pFrm ); 89 void Init( Window* pWindow ); 90 }; 91 92 93 } } // eof of namespace sw::access 94 95 #endif 96