Bump version to 4.1-6
[LibreOffice.git] / vbahelper / source / msforms / vbasystemaxcontrol.cxx
blob84ac5ebcbb73c41a951b7c51dc56a95adfcb0c0d
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
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 .
19 #include "vbasystemaxcontrol.hxx"
21 using namespace com::sun::star;
22 using namespace ooo::vba;
24 //----------------------------------------------------------
25 VbaSystemAXControl::VbaSystemAXControl( const uno::Reference< ov::XHelperInterface >& xParent, const uno::Reference< uno::XComponentContext >& xContext, const uno::Reference< uno::XInterface >& xControl, const uno::Reference< frame::XModel >& xModel, AbstractGeometryAttributes* pGeomHelper )
26 : SystemAXControlImpl_BASE( xParent, xContext, xControl, xModel, pGeomHelper )
27 , m_xControlInvocation( xControl, uno::UNO_QUERY_THROW )
31 //----------------------------------------------------------
32 uno::Reference< beans::XIntrospectionAccess > SAL_CALL VbaSystemAXControl::getIntrospection()
33 throw ( uno::RuntimeException )
35 return m_xControlInvocation->getIntrospection();
38 //----------------------------------------------------------
39 uno::Any SAL_CALL VbaSystemAXControl::invoke( const OUString& aFunctionName, const uno::Sequence< uno::Any >& aParams, uno::Sequence< ::sal_Int16 >& aOutParamIndex, uno::Sequence< uno::Any >& aOutParam )
40 throw ( lang::IllegalArgumentException, script::CannotConvertException, reflection::InvocationTargetException, uno::RuntimeException )
42 return m_xControlInvocation->invoke( aFunctionName, aParams, aOutParamIndex, aOutParam );
45 //----------------------------------------------------------
46 void SAL_CALL VbaSystemAXControl::setValue( const OUString& aPropertyName, const uno::Any& aValue )
47 throw ( beans::UnknownPropertyException, script::CannotConvertException, reflection::InvocationTargetException, uno::RuntimeException )
49 m_xControlInvocation->setValue( aPropertyName, aValue );
52 //----------------------------------------------------------
53 uno::Any SAL_CALL VbaSystemAXControl::getValue( const OUString& aPropertyName )
54 throw ( beans::UnknownPropertyException, uno::RuntimeException )
56 return m_xControlInvocation->getValue( aPropertyName );
59 //----------------------------------------------------------
60 ::sal_Bool SAL_CALL VbaSystemAXControl::hasMethod( const OUString& aName )
61 throw ( uno::RuntimeException )
63 return m_xControlInvocation->hasMethod( aName );
66 //----------------------------------------------------------
67 ::sal_Bool SAL_CALL VbaSystemAXControl::hasProperty( const OUString& aName )
68 throw ( uno::RuntimeException )
70 return m_xControlInvocation->hasProperty( aName );
73 //----------------------------------------------------------
74 OUString
75 VbaSystemAXControl::getServiceImplName()
77 return OUString( "VbaSystemAXControl" );
80 //----------------------------------------------------------
81 uno::Sequence< OUString >
82 VbaSystemAXControl::getServiceNames()
84 static uno::Sequence< OUString > aServiceNames;
85 if ( aServiceNames.getLength() == 0 )
87 aServiceNames.realloc( 1 );
88 aServiceNames[ 0 ] = "ooo.vba.msforms.Frame";
90 return aServiceNames;
93 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */