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_ENUMVARIANT_H
21 #define INCLUDED_WINACCESSIBILITY_SOURCE_UACCCOM_ENUMVARIANT_H
23 #include "resource.h" // main symbols
24 #include <com/sun/star/accessibility/XAccessible.hpp>
25 #include <com/sun/star/accessibility/XAccessibleSelection.hpp>
26 #include <AccObjectManagerAgent.hxx>
29 #pragma clang diagnostic push
30 #pragma clang diagnostic ignored "-Wnon-virtual-dtor"
34 #pragma clang diagnostic pop
38 * CEnumVariant implements IEnumVARIANT interface.
40 class ATL_NO_VTABLE CEnumVariant
:
41 public CComObjectRootEx
<CComMultiThreadModel
>,
42 public CComCoClass
<CEnumVariant
, &CLSID_EnumVariant
>,
43 public IDispatchImpl
<IEnumVariant
, &IID_IEnumVariant
, &LIBID_UACCCOMLib
>
49 m_pXAccessibleSelection(NULL
)
51 m_lCurrent
= m_lLBound
;
54 virtual ~CEnumVariant() {};
58 DECLARE_PROTECT_FINAL_CONSTRUCT()
60 BEGIN_COM_MAP(CEnumVariant
)
61 COM_INTERFACE_ENTRY(IEnumVariant
)
62 COM_INTERFACE_ENTRY(IEnumVARIANT
)
68 STDMETHOD(ClearEnumeration
)();
73 HRESULT STDMETHODCALLTYPE
Next(ULONG cElements
,VARIANT __RPC_FAR
*pvar
,ULONG __RPC_FAR
*pcElementFetched
);
76 HRESULT STDMETHODCALLTYPE
Skip(ULONG cElements
);
79 HRESULT STDMETHODCALLTYPE
Reset( void);
82 HRESULT STDMETHODCALLTYPE
Clone(IEnumVARIANT __RPC_FAR
*__RPC_FAR
*ppenum
);
87 HRESULT STDMETHODCALLTYPE
PutSelection(hyper pXSelection
);
90 static HRESULT STDMETHODCALLTYPE
Create(CEnumVariant __RPC_FAR
*__RPC_FAR
*ppenum
);
93 long GetCountOfElements();
99 css::accessibility::XAccessible
* pUNOInterface
;
100 css::uno::Reference
<css::accessibility::XAccessibleSelection
>
101 m_pXAccessibleSelection
;
104 #endif // INCLUDED_WINACCESSIBILITY_SOURCE_UACCCOM_ENUMVARIANT_H
106 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */