1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
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 .
20 #ifndef INCLUDED_SD_SOURCE_FILTER_PPT_PPTIN_HXX
21 #define INCLUDED_SD_SOURCE_FILTER_PPT_PPTIN_HXX
23 #include <filter/msfilter/svdfppt.hxx>
25 #include <svx/svdtypes.hxx>
31 /*************************************************************************
35 \************************************************************************/
38 class SdAnimationInfo
;
41 typedef std::shared_ptr
< Ppt97Animation
> Ppt97AnimationPtr
;
42 typedef ::std::map
< SdrObject
*, Ppt97AnimationPtr
> tAnimationMap
;
43 typedef std::vector
< std::pair
< SdrObject
*, Ppt97AnimationPtr
> > tAnimationVector
;
45 class ImplSdPPTImport
: public SdrPowerPointImport
48 SotStorage
& mrStorage
;
49 DffRecordHeader maDocHd
;
50 std::vector
<OUString
> maSlideNameList
;
52 sal_uInt32 mnFilterOptions
;
53 SdDrawDocument
* mpDoc
;
54 PresChange mePresChange
;
55 SdrLayerID mnBackgroundObjectsLayerID
;
57 tAnimationMap maAnimations
;
58 void SetHeaderFooterPageSettings( SdPage
* pPage
, const PptSlidePersistEntry
* pMasterPersist
);
59 void ImportPageEffect( SdPage
* pPage
, const bool bNewAnimationsUsed
);
61 void FillSdAnimationInfo( SdAnimationInfo
* pInfo
, PptInteractiveInfoAtom
const * pIAtom
, const OUString
& aMacroName
);
63 virtual SdrObject
* ProcessObj( SvStream
& rSt
, DffObjData
& rData
, SvxMSDffClientData
& rClientData
, ::tools::Rectangle
& rTextRect
, SdrObject
* pObj
) override
;
64 virtual SdrObject
* ApplyTextObj( PPTTextObj
* pTextObj
, SdrTextObj
* pText
, SdPageCapsule pPage
,
65 SfxStyleSheet
*, SfxStyleSheet
** ) const override
;
69 OUString
ReadSound( sal_uInt32 nSoundRef
) const;
70 OUString
ReadMedia( sal_uInt32 nMediaRef
) const;
72 ImplSdPPTImport( SdDrawDocument
* pDoc
, SotStorage
& rStorage
, SfxMedium
& rMed
, PowerPointImportParam
& );
73 virtual ~ImplSdPPTImport() override
;
76 virtual bool ReadFormControl( tools::SvRef
<SotStorage
>& rSrc1
, css::uno::Reference
< css::form::XFormComponent
> & rFormComp
) const override
;
81 PowerPointImportParam maParam
;
82 std::unique_ptr
<ImplSdPPTImport
> pFilter
;
86 SdPPTImport( SdDrawDocument
* pDoc
, SvStream
& rDocStream
, SotStorage
& rStorage
, SfxMedium
& rMed
);
92 #endif // INCLUDED_SD_SOURCE_FILTER_PPT_PPTIN_HXX
94 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */