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_WINACCESSIBILITY_SOURCE_UACCCOM_ACCCOMPONENT_H
21 #define INCLUDED_WINACCESSIBILITY_SOURCE_UACCCOM_ACCCOMPONENT_H
23 #include "resource.h" // main symbols
25 #include <com/sun/star/accessibility/XAccessible.hpp>
26 #include <com/sun/star/accessibility/XAccessibleContext.hpp>
27 #include <com/sun/star/accessibility/XAccessibleComponent.hpp>
28 #include "UNOXWrapper.h"
29 #include "AccComponentBase.h"
33 * CAccComponent implements IAccessibleComponent interface.
35 class ATL_NO_VTABLE CAccComponent
:
36 public CComObjectRoot
,
37 public CComCoClass
<CAccComponent
,&CLSID_AccComponent
>,
38 public IAccessibleComponent
,
39 public CAccComponentBase
49 BEGIN_COM_MAP(CAccComponent
)
50 COM_INTERFACE_ENTRY(IAccessibleComponent
)
51 COM_INTERFACE_ENTRY(IUNOXWrapper
)
52 COM_INTERFACE_ENTRY_FUNC_BLIND(NULL
,_SmartQI
)
55 static HRESULT WINAPI
_SmartQI(void* pv
,
56 REFIID iid
, void** ppvObject
, DWORD_PTR
)
58 return ((CAccComponent
*)pv
)->SmartQI(iid
,ppvObject
);
61 HRESULT
SmartQI(REFIID iid
, void** ppvObject
)
64 return OuterQueryInterface(iid
,ppvObject
);
71 // IAccessibleComponent
73 // Returns the location of the upper left corner of the object's bounding
74 // box relative to the parent.
75 STDMETHOD(get_locationInParent
)(long *x
, long *y
);
77 // Returns the foreground color of this object.
78 STDMETHOD(get_foreground
)(IA2Color
* foreground
);
80 // Returns the background color of this object.
81 STDMETHOD(get_background
)(IA2Color
* background
);
83 // Override of IUNOXWrapper.
84 STDMETHOD(put_XInterface
)(hyper pXInterface
);
88 #endif // INCLUDED_WINACCESSIBILITY_SOURCE_UACCCOM_ACCCOMPONENT_H
90 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */