update dev300-m58
[ooovba.git] / writerfilter / source / dmapper / OLEHandler.hxx
blobc56358a0de321ddf8fec75e7318d57948ff2f1b4
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: OLEHandler.hxx,v $
10 * $Revision: 1.3 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
30 #ifndef INCLUDED_OLEHANDLER_HXX
31 #define INCLUDED_OLEHANDLER_HXX
33 #ifndef INCLUDED_WRITERFILTERDLLAPI_H
34 #include <WriterFilterDllApi.hxx>
35 #endif
36 #include <resourcemodel/WW8ResourceModel.hxx>
37 #include <boost/shared_ptr.hpp>
38 #include <com/sun/star/awt/Size.hpp>
39 #include <com/sun/star/awt/Point.hpp>
41 namespace com{ namespace sun{ namespace star{
42 namespace embed{
43 class XEmbeddedObject;
45 namespace graphic{
46 class XGraphic;
48 namespace io{
49 class XInputStream;
51 namespace text{
52 class XTextDocument;
54 namespace uno{
55 class XComponentContext;
57 }}}
58 namespace writerfilter {
59 namespace dmapper
61 //class PropertyMap;
62 /** Handler for OLE objects
64 class WRITERFILTER_DLLPRIVATE OLEHandler : public Properties
66 ::rtl::OUString m_sObjectType;
67 ::rtl::OUString m_sProgId;
68 ::rtl::OUString m_sShapeId;
69 ::rtl::OUString m_sDrawAspect;
70 ::rtl::OUString m_sObjectId;
71 ::rtl::OUString m_sr_id;
73 sal_Int32 m_nDxaOrig;
74 sal_Int32 m_nDyaOrig;
76 ::com::sun::star::awt::Size m_aShapeSize;
77 ::com::sun::star::awt::Point m_aShapePosition;
79 ::com::sun::star::uno::Reference< ::com::sun::star::graphic::XGraphic > m_xReplacement;
81 ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream > m_xInputStream;
82 public:
83 OLEHandler();
84 virtual ~OLEHandler();
86 // Properties
87 virtual void attribute(Id Name, Value & val);
88 virtual void sprm(Sprm & sprm);
90 ::rtl::OUString copyOLEOStream( ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextDocument > xTextDocument );
92 ::com::sun::star::awt::Size getSize() const { return m_aShapeSize;}
93 ::com::sun::star::awt::Point getPosition() const { return m_aShapePosition;}
94 ::com::sun::star::uno::Reference< ::com::sun::star::graphic::XGraphic >
95 getReplacement() const { return m_xReplacement; }
98 typedef boost::shared_ptr< OLEHandler > OLEHandlerPtr;
101 #endif //