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_SW_SOURCE_CORE_ACCESS_ACCHYPERLINK_HXX
21 #define INCLUDED_SW_SOURCE_CORE_ACCESS_ACCHYPERLINK_HXX
23 #include <com/sun/star/accessibility/XAccessibleHyperlink.hpp>
24 #include <rtl/ref.hxx>
25 #include <cppuhelper/implbase.hxx>
26 #include <svl/listener.hxx>
28 class SwFormatINetFormat
;
29 class SwAccessibleParagraph
;
32 class SwAccessibleHyperlink
33 : public ::cppu::WeakImplHelper
<css::accessibility::XAccessibleHyperlink
>
36 friend class SwAccessibleParagraph
;
37 friend class SwAccessibleHyperTextData
;
38 SwFormatINetFormat
* m_pHyperlink
;
39 ::rtl::Reference
< SwAccessibleParagraph
> m_xParagraph
;
40 sal_Int32 m_nStartIndex
;
41 sal_Int32 m_nEndIndex
;
43 SwAccessibleHyperlink(const SwTextAttr
&,
44 SwAccessibleParagraph
&,
45 sal_Int32 nStt
, sal_Int32 nEnd
);
46 virtual ~SwAccessibleHyperlink() override
;
48 const SwFormatINetFormat
* GetTextAttr() const;
51 virtual void Notify(SfxHint
const& rHint
) override
;
55 virtual sal_Int32 SAL_CALL
getAccessibleActionCount() override
;
56 virtual sal_Bool SAL_CALL
doAccessibleAction( sal_Int32 nIndex
) override
;
57 virtual OUString SAL_CALL
getAccessibleActionDescription(
58 sal_Int32 nIndex
) override
;
59 virtual css::uno::Reference
<
60 css::accessibility::XAccessibleKeyBinding
> SAL_CALL
61 getAccessibleActionKeyBinding( sal_Int32 nIndex
) override
;
63 // XAccessibleHyperlink
64 virtual css::uno::Any SAL_CALL
getAccessibleActionAnchor(
65 sal_Int32 nIndex
) override
;
66 virtual css::uno::Any SAL_CALL
getAccessibleActionObject(
67 sal_Int32 nIndex
) override
;
68 virtual sal_Int32 SAL_CALL
getStartIndex() override
;
69 virtual sal_Int32 SAL_CALL
getEndIndex() override
;
70 virtual sal_Bool SAL_CALL
isValid( ) override
;
75 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */