diff options
author | David Tardon <dtardon@redhat.com> | 2011-04-15 12:04:41 +0200 |
---|---|---|
committer | David Tardon <dtardon@redhat.com> | 2011-04-15 12:46:03 +0200 |
commit | 1d358f105d42ed0bc68cd024c4da0b0395bf72bc (patch) | |
tree | b43c8ccd4d77929d8940e2671f2fc345c7a120d7 /chart2/source/model | |
parent | c849643c980c7bb4ed25d79310e6bf6a05ed0714 (diff) |
remove unused files
Diffstat (limited to 'chart2/source/model')
-rw-r--r-- | chart2/source/model/main/LayoutContainer.cxx | 141 | ||||
-rw-r--r-- | chart2/source/model/main/LayoutContainer.hxx | 93 |
2 files changed, 0 insertions, 234 deletions
diff --git a/chart2/source/model/main/LayoutContainer.cxx b/chart2/source/model/main/LayoutContainer.cxx deleted file mode 100644 index 937232ae6ce2..000000000000 --- a/chart2/source/model/main/LayoutContainer.cxx +++ /dev/null @@ -1,141 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * <http://www.openoffice.org/license.html> - * for a copy of the LGPLv3 License. - * - ************************************************************************/ - -// MARKER(update_precomp.py): autogen include statement, do not remove -#include "precompiled_chart2.hxx" -#include "LayoutContainer.hxx" -#include "macros.hxx" -#include "ContainerHelper.hxx" - -#include <algorithm> - -using namespace ::com::sun::star; - -namespace -{ - -static const ::rtl::OUString lcl_aServiceName( - RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.comp.layout.LayoutContainer" )); -} // anonymous namespace - -namespace chart -{ - -LayoutContainer::LayoutContainer() -{} - -LayoutContainer::~LayoutContainer() -{} - -// ____ XLayoutContainer ____ -void SAL_CALL LayoutContainer::addConstrainedElementByIdentifier( - const ::rtl::OUString& aIdentifier, - const layout::Constraint& Constraint ) - throw (layout::IllegalConstraintException, - lang::IllegalArgumentException, - uno::RuntimeException) -{ - addElementByIdentifier( aIdentifier ); - m_aConstraints[ aIdentifier ] = Constraint; -} - -void SAL_CALL LayoutContainer::addElementByIdentifier( const ::rtl::OUString& aIdentifier ) - throw (lang::IllegalArgumentException, - uno::RuntimeException) -{ - if( ::std::find( m_aLayoutElements.begin(), - m_aLayoutElements.end(), - aIdentifier ) != m_aLayoutElements.end()) - throw lang::IllegalArgumentException(); - - m_aLayoutElements.push_back( aIdentifier ); -} - -void SAL_CALL LayoutContainer::removeElementByIdentifier( const ::rtl::OUString& aIdentifier ) - throw (container::NoSuchElementException, - uno::RuntimeException) -{ - tLayoutElements::iterator aIt( - ::std::find( m_aLayoutElements.begin(), - m_aLayoutElements.end(), - aIdentifier )); - - if( aIt == m_aLayoutElements.end()) - throw container::NoSuchElementException(); - - m_aLayoutElements.erase( aIt ); - m_aConstraints.erase( aIdentifier ); -} - -void SAL_CALL LayoutContainer::setConstraintByIdentifier( - const ::rtl::OUString& aIdentifier, - const layout::Constraint& Constraint ) - throw (container::NoSuchElementException, - uno::RuntimeException) -{ - if( ::std::find( m_aLayoutElements.begin(), - m_aLayoutElements.end(), - aIdentifier ) == m_aLayoutElements.end()) - throw container::NoSuchElementException(); - - m_aConstraints[ aIdentifier ] = Constraint; -} - -layout::Constraint SAL_CALL LayoutContainer::getConstraintByIdentifier( const ::rtl::OUString& aIdentifier ) - throw (container::NoSuchElementException, - uno::RuntimeException) -{ - tConstraintsMap::const_iterator aIt( m_aConstraints.find( aIdentifier )); - if( aIt == m_aConstraints.end()) - throw container::NoSuchElementException(); - - return (*aIt).second; -} - -uno::Sequence< ::rtl::OUString > SAL_CALL LayoutContainer::getElementIdentifiers() - throw (uno::RuntimeException) -{ - return ContainerHelper::ContainerToSequence( m_aLayoutElements ); -} - -uno::Sequence< ::rtl::OUString > LayoutContainer::getSupportedServiceNames_Static() -{ - uno::Sequence< ::rtl::OUString > aServices( 1 ); - - aServices[ 0 ] = C2U( "com.sun.star.layout.LayoutContainer" ); - return aServices; -} - -// -------------------------------------------------------------------------------- - -// implement XServiceInfo methods basing upon getSupportedServiceNames_Static -APPHELPER_XSERVICEINFO_IMPL( LayoutContainer, lcl_aServiceName ); - -} // namespace chart - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/chart2/source/model/main/LayoutContainer.hxx b/chart2/source/model/main/LayoutContainer.hxx deleted file mode 100644 index c5c32c0079c7..000000000000 --- a/chart2/source/model/main/LayoutContainer.hxx +++ /dev/null @@ -1,93 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * <http://www.openoffice.org/license.html> - * for a copy of the LGPLv3 License. - * - ************************************************************************/ -#ifndef CHART_LAYOUTCONTAINER_HXX -#define CHART_LAYOUTCONTAINER_HXX - -#include <cppuhelper/implbase2.hxx> -#include <com/sun/star/lang/XServiceInfo.hpp> -#include <com/sun/star/layout/XLayoutContainer.hpp> - -#include "ServiceMacros.hxx" - -#include <vector> -#include <map> - -namespace chart -{ - -class LayoutContainer : public - ::cppu::WeakImplHelper2< - ::com::sun::star::lang::XServiceInfo, - ::com::sun::star::layout::XLayoutContainer > -{ -public: - LayoutContainer(); - virtual ~LayoutContainer(); - - /// XServiceInfo declarations - APPHELPER_XSERVICEINFO_DECL() - -protected: - // ____ XLayoutContainer ____ - virtual void SAL_CALL addConstrainedElementByIdentifier( const ::rtl::OUString& aIdentifier, const ::com::sun::star::layout::Constraint& Constraint ) - throw (::com::sun::star::layout::IllegalConstraintException, - ::com::sun::star::lang::IllegalArgumentException, - ::com::sun::star::uno::RuntimeException); - virtual void SAL_CALL addElementByIdentifier( const ::rtl::OUString& aIdentifier ) - throw (::com::sun::star::lang::IllegalArgumentException, - ::com::sun::star::uno::RuntimeException); - virtual void SAL_CALL removeElementByIdentifier( const ::rtl::OUString& aIdentifier ) - throw (::com::sun::star::container::NoSuchElementException, - ::com::sun::star::uno::RuntimeException); - virtual void SAL_CALL setConstraintByIdentifier( const ::rtl::OUString& aIdentifier, const ::com::sun::star::layout::Constraint& Constraint ) - throw (::com::sun::star::container::NoSuchElementException, - ::com::sun::star::uno::RuntimeException); - virtual ::com::sun::star::layout::Constraint SAL_CALL getConstraintByIdentifier( const ::rtl::OUString& aIdentifier ) - throw (::com::sun::star::container::NoSuchElementException, - ::com::sun::star::uno::RuntimeException); - virtual ::com::sun::star::uno::Sequence< - ::rtl::OUString > SAL_CALL getElementIdentifiers() - throw (::com::sun::star::uno::RuntimeException); - -private: - typedef ::std::vector< ::rtl::OUString > tLayoutElements; - - typedef ::std::map< - ::rtl::OUString, - ::com::sun::star::layout::Constraint > tConstraintsMap; - - tLayoutElements m_aLayoutElements; - tConstraintsMap m_aConstraints; -}; - -} // namespace chart - -// CHART_LAYOUTCONTAINER_HXX -#endif - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |