2001-08-14 10:54:46 +00:00
|
|
|
/*************************************************************************
|
|
|
|
*
|
2008-04-10 20:26:49 +00:00
|
|
|
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
2001-08-14 10:54:46 +00:00
|
|
|
*
|
2010-02-12 15:01:35 +01:00
|
|
|
* Copyright 2000, 2010 Oracle and/or its affiliates.
|
2001-08-14 10:54:46 +00:00
|
|
|
*
|
2008-04-10 20:26:49 +00:00
|
|
|
* OpenOffice.org - a multi-platform office productivity suite
|
2001-08-14 10:54:46 +00:00
|
|
|
*
|
2008-04-10 20:26:49 +00:00
|
|
|
* This file is part of OpenOffice.org.
|
2001-08-14 10:54:46 +00:00
|
|
|
*
|
2008-04-10 20:26:49 +00:00
|
|
|
* 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.
|
2001-08-14 10:54:46 +00:00
|
|
|
*
|
2008-04-10 20:26:49 +00:00
|
|
|
* 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).
|
2001-08-14 10:54:46 +00:00
|
|
|
*
|
2008-04-10 20:26:49 +00:00
|
|
|
* 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.
|
2001-08-14 10:54:46 +00:00
|
|
|
*
|
|
|
|
************************************************************************/
|
2006-09-17 09:17:18 +00:00
|
|
|
|
|
|
|
// MARKER(update_precomp.py): autogen include statement, do not remove
|
|
|
|
#include "precompiled_xmloff.hxx"
|
2001-08-14 10:54:46 +00:00
|
|
|
#include "XMLChartPropertyContext.hxx"
|
|
|
|
#include "PropertyMap.hxx"
|
|
|
|
|
|
|
|
#include "XMLSymbolImageContext.hxx"
|
2007-10-22 15:33:36 +00:00
|
|
|
#include "XMLLabelSeparatorContext.hxx"
|
2001-08-14 10:54:46 +00:00
|
|
|
|
|
|
|
TYPEINIT1( XMLChartPropertyContext, SvXMLImportContext );
|
|
|
|
|
|
|
|
using namespace ::com::sun::star;
|
|
|
|
|
|
|
|
XMLChartPropertyContext::XMLChartPropertyContext(
|
|
|
|
SvXMLImport& rImport,
|
|
|
|
sal_uInt16 nPrfx,
|
|
|
|
const ::rtl::OUString& rLName,
|
|
|
|
const uno::Reference< xml::sax::XAttributeList > & xAttrList,
|
2004-07-13 07:04:24 +00:00
|
|
|
sal_uInt32 nFamily,
|
2001-08-14 10:54:46 +00:00
|
|
|
::std::vector< XMLPropertyState >& rProps,
|
|
|
|
const UniReference< SvXMLImportPropertyMapper >& rMapper ) :
|
2004-07-13 07:04:24 +00:00
|
|
|
SvXMLPropertySetContext( rImport, nPrfx, rLName, xAttrList, nFamily, rProps, rMapper )
|
2001-08-14 10:54:46 +00:00
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
XMLChartPropertyContext::~XMLChartPropertyContext()
|
|
|
|
{}
|
|
|
|
|
|
|
|
SvXMLImportContext* XMLChartPropertyContext::CreateChildContext(
|
|
|
|
sal_uInt16 nPrefix,
|
|
|
|
const ::rtl::OUString& rLocalName,
|
|
|
|
const uno::Reference< xml::sax::XAttributeList > & xAttrList,
|
|
|
|
::std::vector< XMLPropertyState > &rProperties,
|
|
|
|
const XMLPropertyState& rProp )
|
|
|
|
{
|
|
|
|
SvXMLImportContext *pContext = 0;
|
|
|
|
|
2006-06-19 17:02:31 +00:00
|
|
|
switch( mxMapper->getPropertySetMapper()->GetEntryContextId( rProp.mnIndex ) )
|
2001-08-14 10:54:46 +00:00
|
|
|
{
|
|
|
|
case XML_SCH_CONTEXT_SPECIAL_SYMBOL_IMAGE:
|
|
|
|
pContext = new XMLSymbolImageContext( GetImport(), nPrefix, rLocalName, rProp, rProperties );
|
|
|
|
break;
|
2007-10-22 15:33:36 +00:00
|
|
|
case XML_SCH_CONTEXT_SPECIAL_LABEL_SEPARATOR:
|
|
|
|
pContext = new XMLLabelSeparatorContext( GetImport(), nPrefix, rLocalName, rProp, rProperties );
|
|
|
|
break;
|
2001-08-14 10:54:46 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
// default / no context yet: create child context by base class
|
|
|
|
if( !pContext )
|
|
|
|
{
|
|
|
|
pContext = SvXMLPropertySetContext::CreateChildContext(
|
|
|
|
nPrefix, rLocalName, xAttrList, rProperties, rProp );
|
|
|
|
}
|
|
|
|
|
|
|
|
return pContext;
|
|
|
|
}
|