2010-10-12 15:59:00 +02:00
|
|
|
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
2012-11-30 12:23:25 +00:00
|
|
|
/*
|
|
|
|
* This file is part of the LibreOffice project.
|
|
|
|
*
|
|
|
|
* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
|
|
|
*
|
|
|
|
* This file incorporates work covered by the following license notice:
|
|
|
|
*
|
|
|
|
* Licensed to the Apache Software Foundation (ASF) under one or more
|
|
|
|
* contributor license agreements. See the NOTICE file distributed
|
|
|
|
* with this work for additional information regarding copyright
|
|
|
|
* ownership. The ASF licenses this file to you under the Apache
|
|
|
|
* License, Version 2.0 (the "License"); you may not use this file
|
|
|
|
* except in compliance with the License. You may obtain a copy of
|
|
|
|
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
|
|
|
|
*/
|
2009-02-13 13:03:24 +00:00
|
|
|
#include <ooo/vba/excel/XDialog.hpp>
|
2007-04-25 15:06:21 +00:00
|
|
|
#include "vbadialogs.hxx"
|
|
|
|
#include "vbadialog.hxx"
|
|
|
|
|
2009-02-13 13:03:24 +00:00
|
|
|
using namespace ::ooo::vba;
|
2007-04-25 15:06:21 +00:00
|
|
|
using namespace ::com::sun::star;
|
|
|
|
|
|
|
|
uno::Any
|
2014-02-25 21:31:58 +01:00
|
|
|
ScVbaDialogs::Item( const uno::Any &aItem ) throw (uno::RuntimeException, std::exception)
|
2007-04-25 15:06:21 +00:00
|
|
|
{
|
2007-08-30 09:04:53 +00:00
|
|
|
sal_Int32 nIndex = 0;
|
2007-04-25 15:06:21 +00:00
|
|
|
aItem >>= nIndex;
|
2009-09-18 15:24:22 +00:00
|
|
|
uno::Reference< excel::XDialog > aDialog( new ScVbaDialog( uno::Reference< XHelperInterface >( Application(),uno::UNO_QUERY_THROW ), mxContext, m_xModel, nIndex ) );
|
2007-04-25 15:06:21 +00:00
|
|
|
return uno::Any( aDialog );
|
|
|
|
}
|
2009-09-18 15:24:22 +00:00
|
|
|
|
2013-04-07 12:06:47 +02:00
|
|
|
OUString
|
2007-12-07 09:50:42 +00:00
|
|
|
ScVbaDialogs::getServiceImplName()
|
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
return OUString("ScVbaDialogs");
|
2007-12-07 09:50:42 +00:00
|
|
|
}
|
|
|
|
|
2013-04-07 12:06:47 +02:00
|
|
|
uno::Sequence< OUString >
|
2007-12-07 09:50:42 +00:00
|
|
|
ScVbaDialogs::getServiceNames()
|
|
|
|
{
|
2013-04-07 12:06:47 +02:00
|
|
|
static uno::Sequence< OUString > aServiceNames;
|
2007-12-07 09:50:42 +00:00
|
|
|
if ( aServiceNames.getLength() == 0 )
|
|
|
|
{
|
|
|
|
aServiceNames.realloc( 1 );
|
2013-11-04 11:22:26 +02:00
|
|
|
aServiceNames[ 0 ] = "ooo.vba.excel.Dialogs";
|
2007-12-07 09:50:42 +00:00
|
|
|
}
|
|
|
|
return aServiceNames;
|
|
|
|
}
|
|
|
|
|
2010-10-12 15:59:00 +02:00
|
|
|
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|