2010-10-27 13:11:31 +01:00
|
|
|
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
|
2012-06-21 14:30:25 +01: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 .
|
|
|
|
*/
|
2004-08-31 13:54:13 +00:00
|
|
|
|
2013-10-28 03:41:20 +01:00
|
|
|
#ifndef INCLUDED_SVX_SOURCE_INC_UNOGALTHEMEPROVIDER_HXX
|
|
|
|
#define INCLUDED_SVX_SOURCE_INC_UNOGALTHEMEPROVIDER_HXX
|
2004-08-31 13:54:13 +00:00
|
|
|
|
2014-01-14 12:27:09 -02:00
|
|
|
#include <cppuhelper/implbase3.hxx>
|
2004-08-31 13:54:13 +00:00
|
|
|
#include <com/sun/star/lang/XServiceInfo.hpp>
|
|
|
|
#include <com/sun/star/lang/XInitialization.hpp>
|
|
|
|
#include <com/sun/star/gallery/XGalleryThemeProvider.hpp>
|
|
|
|
|
|
|
|
class Gallery;
|
|
|
|
|
2013-12-30 10:38:29 +01:00
|
|
|
namespace {
|
2004-08-31 13:54:13 +00:00
|
|
|
|
2014-01-14 12:27:09 -02:00
|
|
|
class GalleryThemeProvider : public ::cppu::WeakImplHelper3< ::com::sun::star::lang::XInitialization,
|
|
|
|
::com::sun::star::gallery::XGalleryThemeProvider,
|
|
|
|
::com::sun::star::lang::XServiceInfo >
|
2004-08-31 13:54:13 +00:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
|
|
|
|
GalleryThemeProvider();
|
2014-04-01 19:18:35 +02:00
|
|
|
virtual ~GalleryThemeProvider();
|
2004-08-31 13:54:13 +00:00
|
|
|
|
|
|
|
protected:
|
|
|
|
|
|
|
|
// XServiceInfo
|
2014-03-27 18:12:18 +01:00
|
|
|
virtual OUString SAL_CALL getImplementationName() throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
|
|
|
|
virtual sal_Bool SAL_CALL supportsService( const OUString& ServiceName ) throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
|
|
|
|
virtual ::com::sun::star::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
|
2004-08-31 13:54:13 +00:00
|
|
|
|
|
|
|
// XTypeProvider
|
2014-03-27 18:12:18 +01:00
|
|
|
virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
|
|
|
|
virtual ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId( ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
|
2004-08-31 13:54:13 +00:00
|
|
|
|
|
|
|
// XElementAccess
|
2014-03-27 18:12:18 +01:00
|
|
|
virtual ::com::sun::star::uno::Type SAL_CALL getElementType() throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
|
2014-04-03 13:52:06 +02:00
|
|
|
virtual sal_Bool SAL_CALL hasElements() throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
|
2004-08-31 13:54:13 +00:00
|
|
|
|
|
|
|
// XNameAccess
|
2014-03-27 18:12:18 +01:00
|
|
|
virtual ::com::sun::star::uno::Any SAL_CALL getByName( const OUString& aName ) throw (::com::sun::star::container::NoSuchElementException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
|
|
|
|
virtual ::com::sun::star::uno::Sequence< OUString > SAL_CALL getElementNames() throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
|
2014-04-03 13:52:06 +02:00
|
|
|
virtual sal_Bool SAL_CALL hasByName( const OUString& aName ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
|
2004-08-31 13:54:13 +00:00
|
|
|
|
|
|
|
// XInitialization
|
2014-03-27 18:12:18 +01:00
|
|
|
virtual void SAL_CALL initialize( const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any >& aArguments ) throw ( ::com::sun::star::uno::Exception, ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
|
2004-08-31 13:54:13 +00:00
|
|
|
|
|
|
|
// XGalleryThemeProvider
|
2014-03-27 18:12:18 +01:00
|
|
|
virtual ::com::sun::star::uno::Reference< ::com::sun::star::gallery::XGalleryTheme > SAL_CALL insertNewByName( const OUString& ThemeName ) throw (::com::sun::star::container::ElementExistException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
|
|
|
|
virtual void SAL_CALL removeByName( const OUString& ThemeName ) throw (::com::sun::star::container::NoSuchElementException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE;
|
2004-08-31 13:54:13 +00:00
|
|
|
|
|
|
|
private:
|
|
|
|
|
|
|
|
Gallery* mpGallery;
|
2014-04-14 16:15:22 +02:00
|
|
|
bool mbHiddenThemes;
|
2004-08-31 13:54:13 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|
2010-10-27 13:11:31 +01:00
|
|
|
|
|
|
|
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|