xref: /aoo4110/main/svtools/inc/svtools/insdlg.hxx (revision b1cdbd2c)
1 /**************************************************************
2  *
3  * Licensed to the Apache Software Foundation (ASF) under one
4  * or more contributor license agreements.  See the NOTICE file
5  * distributed with this work for additional information
6  * regarding copyright ownership.  The ASF licenses this file
7  * to you under the Apache License, Version 2.0 (the
8  * "License"); you may not use this file except in compliance
9  * with the License.  You may obtain a copy of the License at
10  *
11  *   http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing,
14  * software distributed under the License is distributed on an
15  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16  * KIND, either express or implied.  See the License for the
17  * specific language governing permissions and limitations
18  * under the License.
19  *
20  *************************************************************/
21 
22 
23 #ifndef _SVTOOLS_INSDLG_HXX
24 #define _SVTOOLS_INSDLG_HXX
25 
26 #include "svtools/svtdllapi.h"
27 #include <com/sun/star/uno/Reference.h>
28 #include <com/sun/star/embed/XEmbeddedObject.hpp>
29 #include <com/sun/star/embed/XStorage.hpp>
30 #include <tools/globname.hxx>
31 #include <sot/formats.hxx>
32 
33 #ifndef _OWNCONT_HXX
34 #include <svl/ownlist.hxx>
35 #endif
36 #include <svtools/transfer.hxx>
37 
38 class SvObjectServer
39 {
40 private:
41 	SvGlobalName    aClassName;
42 	String          aHumanName;
43 
44 public:
SvObjectServer(const SvGlobalName & rClassP,const String & rHumanP)45 	SvObjectServer( const SvGlobalName & rClassP, const String & rHumanP ) :
46 		aClassName( rClassP ),
47 		aHumanName( rHumanP ) {}
48 
GetClassName() const49 	const SvGlobalName &    GetClassName() const { return aClassName; }
GetHumanName() const50 	const String &          GetHumanName() const { return aHumanName; }
51 };
52 
53 class SVT_DLLPUBLIC SvObjectServerList
54 {
55 	PRV_SV_DECL_OWNER_LIST(SvObjectServerList,SvObjectServer)
56 	const SvObjectServer *  Get( const String & rHumanName ) const;
57 	const SvObjectServer *  Get( const SvGlobalName & ) const;
58 	void                    Remove( const SvGlobalName & );
59 	void					FillInsertObjects();
60 };
61 
62 class SVT_DLLPUBLIC SvPasteObjectHelper
63 {
64 public:
65     static String GetSotFormatUIName( SotFormatStringId nId );
66     static sal_Bool GetEmbeddedName(const TransferableDataHelper& rData, String& _rName, String& _rSource, SotFormatStringId& _nFormat);
67 };
68 
69 #endif // _SVTOOLS_INSDLG_HXX
70 
71