1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
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 INCLUDED_SC_SOURCE_UI_INC_ACCESSIBLEDOCUMENTPAGEPREVIEW_HXX
21 #define INCLUDED_SC_SOURCE_UI_INC_ACCESSIBLEDOCUMENTPAGEPREVIEW_HXX
23 #include "AccessibleDocumentBase.hxx"
26 class ScNotesChildren
;
27 class ScShapeChildren
;
28 class ScAccessiblePreviewTable
;
29 class ScAccessiblePageHeader
;
31 class ScAccessibleDocumentPagePreview
32 : public ScAccessibleDocumentBase
35 //===== internal ========================================================
36 ScAccessibleDocumentPagePreview(
37 const ::com::sun::star::uno::Reference
<
38 ::com::sun::star::accessibility::XAccessible
>& rxParent
,
39 ScPreviewShell
* pViewShell
);
41 virtual ~ScAccessibleDocumentPagePreview();
43 using ScAccessibleDocumentBase::IsDefunc
;
46 using ScAccessibleContextBase::disposing
;
48 virtual void SAL_CALL
disposing() SAL_OVERRIDE
;
50 ///===== SfxListener =====================================================
52 virtual void Notify( SfxBroadcaster
& rBC
, const SfxHint
& rHint
) SAL_OVERRIDE
;
54 ///===== XAccessibleComponent ============================================
56 virtual ::com::sun::star::uno::Reference
< ::com::sun::star::accessibility::XAccessible
>
57 SAL_CALL
getAccessibleAtPoint(
58 const ::com::sun::star::awt::Point
& rPoint
)
59 throw (::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
61 virtual void SAL_CALL
grabFocus( )
62 throw (::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
64 ///===== XAccessibleContext ==============================================
66 /// Return the number of currently visible children.
67 virtual sal_Int32 SAL_CALL
getAccessibleChildCount()
68 throw (::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
70 /// Return the specified child or NULL if index is invalid.
71 virtual ::com::sun::star::uno::Reference
< ::com::sun::star::accessibility::XAccessible
> SAL_CALL
72 getAccessibleChild(sal_Int32 nIndex
)
73 throw (::com::sun::star::uno::RuntimeException
,
74 ::com::sun::star::lang::IndexOutOfBoundsException
,
75 std::exception
) SAL_OVERRIDE
;
77 /// Return the set of current states.
78 virtual ::com::sun::star::uno::Reference
<
79 ::com::sun::star::accessibility::XAccessibleStateSet
> SAL_CALL
80 getAccessibleStateSet()
81 throw (::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
83 virtual OUString SAL_CALL
getAccessibleName()
84 throw (::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
85 ///===== XServiceInfo ====================================================
87 /** Returns an identifier for the implementation of this object.
89 virtual OUString SAL_CALL
90 getImplementationName()
91 throw (::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
93 /** Returns a list of all supported services.
95 virtual ::com::sun::star::uno::Sequence
< OUString
> SAL_CALL
96 getSupportedServiceNames()
97 throw (::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
99 ///===== XTypeProvider ===================================================
101 /** Returns a implementation id.
103 virtual ::com::sun::star::uno::Sequence
<sal_Int8
> SAL_CALL
104 getImplementationId()
105 throw (::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
107 ///===== internal ========================================================
110 /// Return this object's description.
111 virtual OUString SAL_CALL
112 createAccessibleDescription()
113 throw (::com::sun::star::uno::RuntimeException
) SAL_OVERRIDE
;
115 /// Return the object's current name.
116 virtual OUString SAL_CALL
117 createAccessibleName()
118 throw (::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
120 public: // needed in ScShapeChildren
121 /// Return the object's current bounding box relative to the desktop.
122 virtual Rectangle
GetBoundingBoxOnScreen() const
123 throw (::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
126 /// Return the object's current bounding box relative to the parent object.
127 virtual Rectangle
GetBoundingBox() const
128 throw (::com::sun::star::uno::RuntimeException
, std::exception
) SAL_OVERRIDE
;
131 ScPreviewShell
* mpViewShell
;
132 ScNotesChildren
* mpNotesChildren
;
133 ScShapeChildren
* mpShapeChildren
;
134 ScAccessiblePreviewTable
* mpTable
;
135 ScAccessiblePageHeader
* mpHeader
;
136 ScAccessiblePageHeader
* mpFooter
;
139 const com::sun::star::uno::Reference
<
140 ::com::sun::star::accessibility::XAccessibleStateSet
>& rxParentStates
);
142 ScNotesChildren
* GetNotesChildren();
143 ScShapeChildren
* GetShapeChildren();
148 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */