Branch data Line data Source code
1 : : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 : : /*************************************************************************
3 : : *
4 : : * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 : : *
6 : : * Copyright 2000, 2010 Oracle and/or its affiliates.
7 : : *
8 : : * OpenOffice.org - a multi-platform office productivity suite
9 : : *
10 : : * This file is part of OpenOffice.org.
11 : : *
12 : : * OpenOffice.org is free software: you can redistribute it and/or modify
13 : : * it under the terms of the GNU Lesser General Public License version 3
14 : : * only, as published by the Free Software Foundation.
15 : : *
16 : : * OpenOffice.org is distributed in the hope that it will be useful,
17 : : * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 : : * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 : : * GNU Lesser General Public License version 3 for more details
20 : : * (a copy is included in the LICENSE file that accompanied this code).
21 : : *
22 : : * You should have received a copy of the GNU Lesser General Public License
23 : : * version 3 along with OpenOffice.org. If not, see
24 : : * <http://www.openoffice.org/license.html>
25 : : * for a copy of the LGPLv3 License.
26 : : *
27 : : ************************************************************************/
28 : :
29 : : #ifndef _SVX_XMLEXCHG_HXX_
30 : : #define _SVX_XMLEXCHG_HXX_
31 : :
32 : : #include <svtools/transfer.hxx>
33 : : #include "svx/svxdllapi.h"
34 : :
35 : : namespace com {
36 : : namespace sun {
37 : : namespace star {
38 : : namespace beans {
39 : : class SAL_NO_VTABLE XPropertySet;
40 : : }
41 : : }
42 : : }
43 : : }
44 : :
45 : : //........................................................................
46 : : namespace svx
47 : : {
48 : : //........................................................................
49 : :
50 : :
51 : : //====================================================================
52 : : //= OXFormsDescriptor
53 : : //====================================================================
54 : :
55 [ # # ]: 0 : struct SVX_DLLPUBLIC OXFormsDescriptor {
56 : :
57 : : String szName;
58 : : String szServiceName;
59 : : ::com::sun::star::uno::Reference
60 : : < ::com::sun::star::beans::XPropertySet >
61 : : xPropSet;
62 : :
63 [ # # ]: 0 : inline OXFormsDescriptor( void ) {}
64 [ # # ][ # # ]: 0 : inline OXFormsDescriptor( const OXFormsDescriptor &rhs ) { *this=rhs; }
65 : 0 : inline OXFormsDescriptor &operator = ( const OXFormsDescriptor &rhs ) {
66 : 0 : szName = rhs.szName;
67 : 0 : szServiceName = rhs.szServiceName;
68 : 0 : xPropSet = rhs.xPropSet;
69 : 0 : return (*this);
70 : : }
71 : : };
72 : :
73 : : //====================================================================
74 : : //= OXFormsTransferable
75 : : //====================================================================
76 [ # # ][ # # ]: 0 : class SVX_DLLPUBLIC OXFormsTransferable : public TransferableHelper {
77 : :
78 : : protected:
79 : :
80 : : // TransferableHelper overridables
81 : : virtual void AddSupportedFormats();
82 : : virtual sal_Bool GetData( const ::com::sun::star::datatransfer::DataFlavor& rFlavor );
83 : :
84 : : OXFormsDescriptor m_aDescriptor;
85 : :
86 : : public:
87 : :
88 : : /** construct the transferable
89 : : */
90 : : OXFormsTransferable( const OXFormsDescriptor &rhs );
91 : :
92 : : /** extracts an xform descriptor from the transferable given
93 : : */
94 : : static const OXFormsDescriptor &extractDescriptor( const TransferableDataHelper& _rData );
95 : : };
96 : :
97 : :
98 : : //........................................................................
99 : : } // namespace svx
100 : : //........................................................................
101 : :
102 : : #endif // _SVX_XMLEXCHG_HXX_
103 : :
104 : : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|