xref: /trunk/main/toolkit/inc/toolkit/helper/accessiblefactory.hxx (revision 914d351e5f5b84e4342a86d6ab8d4aca7308b9bd)
1*50e6b072SAndrew Rist /**************************************************************
2cdf0e10cSrcweir  *
3*50e6b072SAndrew Rist  * Licensed to the Apache Software Foundation (ASF) under one
4*50e6b072SAndrew Rist  * or more contributor license agreements.  See the NOTICE file
5*50e6b072SAndrew Rist  * distributed with this work for additional information
6*50e6b072SAndrew Rist  * regarding copyright ownership.  The ASF licenses this file
7*50e6b072SAndrew Rist  * to you under the Apache License, Version 2.0 (the
8*50e6b072SAndrew Rist  * "License"); you may not use this file except in compliance
9*50e6b072SAndrew Rist  * with the License.  You may obtain a copy of the License at
10cdf0e10cSrcweir  *
11*50e6b072SAndrew Rist  *   http://www.apache.org/licenses/LICENSE-2.0
12cdf0e10cSrcweir  *
13*50e6b072SAndrew Rist  * Unless required by applicable law or agreed to in writing,
14*50e6b072SAndrew Rist  * software distributed under the License is distributed on an
15*50e6b072SAndrew Rist  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16*50e6b072SAndrew Rist  * KIND, either express or implied.  See the License for the
17*50e6b072SAndrew Rist  * specific language governing permissions and limitations
18*50e6b072SAndrew Rist  * under the License.
19cdf0e10cSrcweir  *
20*50e6b072SAndrew Rist  *************************************************************/
21*50e6b072SAndrew Rist 
22*50e6b072SAndrew Rist 
23cdf0e10cSrcweir 
24cdf0e10cSrcweir #ifndef TOOLKIT_HELPER_ACCESSIBLE_FACTORY_HXX
25cdf0e10cSrcweir #define TOOLKIT_HELPER_ACCESSIBLE_FACTORY_HXX
26cdf0e10cSrcweir 
27cdf0e10cSrcweir #ifndef _COM_SUN_STAR_UNO_REFERENCE_HXX
28cdf0e10cSrcweir #include <com/sun/star/uno/Reference.hxx>
29cdf0e10cSrcweir #endif
30cdf0e10cSrcweir 
31cdf0e10cSrcweir #ifndef _RTL_REF_HXX
32cdf0e10cSrcweir #include <rtl/ref.hxx>
33cdf0e10cSrcweir #endif
34cdf0e10cSrcweir 
35cdf0e10cSrcweir namespace com { namespace sun { namespace star { namespace accessibility {
36cdf0e10cSrcweir     class XAccessible;
37cdf0e10cSrcweir     class XAccessibleContext;
38cdf0e10cSrcweir } } } }
39cdf0e10cSrcweir class VCLXButton;
40cdf0e10cSrcweir class VCLXCheckBox;
41cdf0e10cSrcweir class VCLXRadioButton;
42cdf0e10cSrcweir class VCLXListBox;
43cdf0e10cSrcweir class VCLXFixedHyperlink;
44cdf0e10cSrcweir class VCLXFixedText;
45cdf0e10cSrcweir class VCLXScrollBar;
46cdf0e10cSrcweir class VCLXEdit;
47cdf0e10cSrcweir class VCLXComboBox;
48cdf0e10cSrcweir class VCLXToolBox;
49cdf0e10cSrcweir class VCLXWindow;
50cdf0e10cSrcweir class Menu;
51cdf0e10cSrcweir 
52cdf0e10cSrcweir //........................................................................
53cdf0e10cSrcweir namespace toolkit
54cdf0e10cSrcweir {
55cdf0e10cSrcweir //........................................................................
56cdf0e10cSrcweir 
57cdf0e10cSrcweir     /** a function which is able to create a factory for the standard Accessible/Context
58cdf0e10cSrcweir         components needed for standard toolkit controls
59cdf0e10cSrcweir 
60cdf0e10cSrcweir         The returned pointer denotes an instance of the IAccessibleFactory, which has been acquired
61cdf0e10cSrcweir         <em>once</em>. The caller is responsible for holding this reference as long as it needs the
62cdf0e10cSrcweir         factory, and release it afterwards.
63cdf0e10cSrcweir     */
64cdf0e10cSrcweir     typedef void* (SAL_CALL * GetStandardAccComponentFactory)( );
65cdf0e10cSrcweir 
66cdf0e10cSrcweir     //================================================================
67cdf0e10cSrcweir     //= IAccessibleFactory
68cdf0e10cSrcweir     //================================================================
69cdf0e10cSrcweir     class IAccessibleFactory : public ::rtl::IReference
70cdf0e10cSrcweir     {
71cdf0e10cSrcweir     public:
72cdf0e10cSrcweir         /** creates an accessible context for a button window
73cdf0e10cSrcweir         */
74cdf0e10cSrcweir         virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleContext >
75cdf0e10cSrcweir             createAccessibleContext( VCLXButton* _pXWindow ) = 0;
76cdf0e10cSrcweir 
77cdf0e10cSrcweir         /** creates an accessible context for a checkbox window
78cdf0e10cSrcweir         */
79cdf0e10cSrcweir         virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleContext >
80cdf0e10cSrcweir             createAccessibleContext( VCLXCheckBox* _pXWindow ) = 0;
81cdf0e10cSrcweir 
82cdf0e10cSrcweir         /** creates an accessible context for a radio button window
83cdf0e10cSrcweir         */
84cdf0e10cSrcweir         virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleContext >
85cdf0e10cSrcweir             createAccessibleContext( VCLXRadioButton* _pXWindow ) = 0;
86cdf0e10cSrcweir 
87cdf0e10cSrcweir         /** creates an accessible context for a listbox window
88cdf0e10cSrcweir         */
89cdf0e10cSrcweir         virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleContext >
90cdf0e10cSrcweir             createAccessibleContext( VCLXListBox* _pXWindow ) = 0;
91cdf0e10cSrcweir 
92cdf0e10cSrcweir         /** creates an accessible context for a fixed hyperlink window
93cdf0e10cSrcweir         */
94cdf0e10cSrcweir         virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleContext >
95cdf0e10cSrcweir             createAccessibleContext( VCLXFixedHyperlink* _pXWindow ) = 0;
96cdf0e10cSrcweir 
97cdf0e10cSrcweir         /** creates an accessible context for a fixed text window
98cdf0e10cSrcweir         */
99cdf0e10cSrcweir         virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleContext >
100cdf0e10cSrcweir             createAccessibleContext( VCLXFixedText* _pXWindow ) = 0;
101cdf0e10cSrcweir 
102cdf0e10cSrcweir         /** creates an accessible context for a scrollbar window
103cdf0e10cSrcweir         */
104cdf0e10cSrcweir         virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleContext >
105cdf0e10cSrcweir             createAccessibleContext( VCLXScrollBar* _pXWindow ) = 0;
106cdf0e10cSrcweir 
107cdf0e10cSrcweir         /** creates an accessible context for a edit window
108cdf0e10cSrcweir         */
109cdf0e10cSrcweir         virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleContext >
110cdf0e10cSrcweir             createAccessibleContext( VCLXEdit* _pXWindow ) = 0;
111cdf0e10cSrcweir 
112cdf0e10cSrcweir         /** creates an accessible context for a combo box window
113cdf0e10cSrcweir         */
114cdf0e10cSrcweir         virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleContext >
115cdf0e10cSrcweir             createAccessibleContext( VCLXComboBox* _pXWindow ) = 0;
116cdf0e10cSrcweir 
117cdf0e10cSrcweir         /** creates an accessible context for a toolbox window
118cdf0e10cSrcweir         */
119cdf0e10cSrcweir         virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleContext >
120cdf0e10cSrcweir             createAccessibleContext( VCLXToolBox* _pXWindow ) = 0;
121cdf0e10cSrcweir 
122cdf0e10cSrcweir         /** creates an accessible context for a generic window
123cdf0e10cSrcweir         */
124cdf0e10cSrcweir         virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessibleContext >
125cdf0e10cSrcweir             createAccessibleContext( VCLXWindow* _pXWindow ) = 0;
126cdf0e10cSrcweir 
127cdf0e10cSrcweir         /** creates an accessible component for the given menu
128cdf0e10cSrcweir         */
129cdf0e10cSrcweir         virtual ::com::sun::star::uno::Reference< ::com::sun::star::accessibility::XAccessible >
130cdf0e10cSrcweir             createAccessible( Menu* _pMenu, sal_Bool _bIsMenuBar ) = 0;
131cdf0e10cSrcweir     };
132cdf0e10cSrcweir 
133cdf0e10cSrcweir //........................................................................
134cdf0e10cSrcweir }   // namespace toolkit
135cdf0e10cSrcweir //........................................................................
136cdf0e10cSrcweir 
137cdf0e10cSrcweir #endif // TOOLKIT_HELPER_ACCESSIBLE_FACTORY_HXX
138