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 .
21 #ifndef _SC_ACCESSIBLEPREVIEWCELL_HXX
22 #define _SC_ACCESSIBLEPREVIEWCELL_HXX
24 #include "AccessibleCellBase.hxx"
28 namespace accessibility
30 class AccessibleTextHelper
;
33 class ScAccessiblePreviewCell
: public ScAccessibleCellBase
36 //===== internal ========================================================
37 ScAccessiblePreviewCell(
38 const ::com::sun::star::uno::Reference
<
39 ::com::sun::star::accessibility::XAccessible
>& rxParent
,
40 ScPreviewShell
* pViewShell
, /* const */ ScAddress
& rCellAddress
, sal_Int32 nIndex
);
43 virtual ~ScAccessiblePreviewCell();
45 using ScAccessibleCellBase::IsDefunc
;
48 using ScAccessibleCellBase::disposing
;
49 virtual void SAL_CALL
disposing();
51 ///===== SfxListener =====================================================
53 virtual void Notify( SfxBroadcaster
& rBC
, const SfxHint
& rHint
);
55 //===== XAccessibleComponent ============================================
57 virtual ::com::sun::star::uno::Reference
< ::com::sun::star::accessibility::XAccessible
> SAL_CALL
58 getAccessibleAtPoint( const ::com::sun::star::awt::Point
& aPoint
)
59 throw (::com::sun::star::uno::RuntimeException
);
60 virtual void SAL_CALL
grabFocus() throw (::com::sun::star::uno::RuntimeException
);
62 //===== XAccessibleContext ==============================================
64 // overloaded to calculate this on demand
65 virtual sal_Int32 SAL_CALL
getAccessibleChildCount() throw (::com::sun::star::uno::RuntimeException
);
66 virtual ::com::sun::star::uno::Reference
< ::com::sun::star::accessibility::XAccessible
> SAL_CALL
67 getAccessibleChild( sal_Int32 i
)
68 throw (::com::sun::star::lang::IndexOutOfBoundsException
,
69 ::com::sun::star::uno::RuntimeException
);
71 virtual ::com::sun::star::uno::Reference
< ::com::sun::star::accessibility::XAccessibleStateSet
> SAL_CALL
72 getAccessibleStateSet() throw (::com::sun::star::uno::RuntimeException
);
74 //===== XServiceInfo ====================================================
76 virtual OUString SAL_CALL
getImplementationName()
77 throw(::com::sun::star::uno::RuntimeException
);
78 virtual ::com::sun::star::uno::Sequence
< OUString
> SAL_CALL
getSupportedServiceNames()
79 throw(::com::sun::star::uno::RuntimeException
);
81 ///===== XTypeProvider ===================================================
83 /** Returns a implementation id.
85 virtual ::com::sun::star::uno::Sequence
<sal_Int8
> SAL_CALL
86 getImplementationId(void)
87 throw (::com::sun::star::uno::RuntimeException
);
90 virtual Rectangle
GetBoundingBoxOnScreen(void) const throw(::com::sun::star::uno::RuntimeException
);
91 virtual Rectangle
GetBoundingBox(void) const throw (::com::sun::star::uno::RuntimeException
);
94 ScPreviewShell
* mpViewShell
;
96 accessibility::AccessibleTextHelper
* mpTextHelper
;
99 const com::sun::star::uno::Reference
<
100 ::com::sun::star::accessibility::XAccessibleStateSet
>& rxParentStates
);
101 virtual sal_Bool
IsEditable(
102 const com::sun::star::uno::Reference
<
103 ::com::sun::star::accessibility::XAccessibleStateSet
>& rxParentStates
);
105 const com::sun::star::uno::Reference
<
106 ::com::sun::star::accessibility::XAccessibleStateSet
>& rxParentStates
);
108 void CreateTextHelper();
114 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */