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_TOOLKIT_HELPER_ACCESSIBLEFACTORY_HXX
21 #define INCLUDED_TOOLKIT_HELPER_ACCESSIBLEFACTORY_HXX
23 #include <com/sun/star/uno/Reference.hxx>
24 #include <salhelper/simplereferenceobject.hxx>
26 namespace com
{ namespace sun
{ namespace star
{ namespace accessibility
{
28 class XAccessibleContext
;
32 class VCLXRadioButton
;
34 class VCLXFixedHyperlink
;
49 /** a function which is able to create a factory for the standard Accessible/Context
50 components needed for standard toolkit controls
52 The returned pointer denotes an instance of the IAccessibleFactory, which has been acquired
53 <em>once</em>. The caller is responsible for holding this reference as long as it needs the
54 factory, and release it afterwards.
56 typedef void* (* GetStandardAccComponentFactory
)( );
59 //= IAccessibleFactory
61 class IAccessibleFactory
: public virtual salhelper::SimpleReferenceObject
64 /** creates an accessible context for a button window
66 virtual css::uno::Reference
< css::accessibility::XAccessibleContext
>
67 createAccessibleContext( VCLXButton
* _pXWindow
) = 0;
69 /** creates an accessible context for a checkbox window
71 virtual css::uno::Reference
< css::accessibility::XAccessibleContext
>
72 createAccessibleContext( VCLXCheckBox
* _pXWindow
) = 0;
74 /** creates an accessible context for a radio button window
76 virtual css::uno::Reference
< css::accessibility::XAccessibleContext
>
77 createAccessibleContext( VCLXRadioButton
* _pXWindow
) = 0;
79 /** creates an accessible context for a listbox window
81 virtual css::uno::Reference
< css::accessibility::XAccessibleContext
>
82 createAccessibleContext( VCLXListBox
* _pXWindow
) = 0;
84 /** creates an accessible context for a fixed hyperlink window
86 virtual css::uno::Reference
< css::accessibility::XAccessibleContext
>
87 createAccessibleContext( VCLXFixedHyperlink
* _pXWindow
) = 0;
89 /** creates an accessible context for a fixed text window
91 virtual css::uno::Reference
< css::accessibility::XAccessibleContext
>
92 createAccessibleContext( VCLXFixedText
* _pXWindow
) = 0;
94 /** creates an accessible context for a scrollbar window
96 virtual css::uno::Reference
< css::accessibility::XAccessibleContext
>
97 createAccessibleContext( VCLXScrollBar
* _pXWindow
) = 0;
99 /** creates an accessible context for an edit window
101 virtual css::uno::Reference
< css::accessibility::XAccessibleContext
>
102 createAccessibleContext( VCLXEdit
* _pXWindow
) = 0;
104 /** creates an accessible context for a combo box window
106 virtual css::uno::Reference
< css::accessibility::XAccessibleContext
>
107 createAccessibleContext( VCLXComboBox
* _pXWindow
) = 0;
109 /** creates an accessible context for a toolbox window
111 virtual css::uno::Reference
< css::accessibility::XAccessibleContext
>
112 createAccessibleContext( VCLXToolBox
* _pXWindow
) = 0;
114 /** creates an accessible context for a headerbar window
116 virtual css::uno::Reference
< css::accessibility::XAccessibleContext
>
117 createAccessibleContext( VCLXHeaderBar
* _pXWindow
) = 0;
119 /** creates an accessible context for a generic window
121 virtual css::uno::Reference
< css::accessibility::XAccessibleContext
>
122 createAccessibleContext( VCLXWindow
* _pXWindow
) = 0;
124 /** creates an accessible component for the given menu
126 virtual css::uno::Reference
< css::accessibility::XAccessible
>
127 createAccessible( Menu
* _pMenu
, bool _bIsMenuBar
) = 0;
130 virtual ~IAccessibleFactory() override
{}
134 } // namespace toolkit
137 #endif // INCLUDED_TOOLKIT_HELPER_ACCESSIBLEFACTORY_HXX
139 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */