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 
24 #ifndef _TARGETDROPCONTEXT_HXX_
25 #define _TARGETDROPCONTEXT_HXX_
26 
27 #include <cppuhelper/implbase1.hxx>
28 #include <com/sun/star/datatransfer/dnd/XDropTargetDropContext.hpp>
29 
30 #include "target.hxx"
31 
32 using namespace ::com::sun::star::datatransfer::dnd;
33 using namespace ::cppu;
34 using namespace ::com::sun::star::uno;
35 using namespace ::com::sun::star::lang;
36 
37 class TargetDropContext: public WeakImplHelper1<XDropTargetDropContext>
38 {
39 	// calls to the functions of XDropTargetDropContext are delegated
40 	// to non-interface functions of m_pDropTarget
41 	DropTarget* m_pDropTarget;
42 
43 	TargetDropContext();
44 	TargetDropContext( const TargetDropContext&);
45 	TargetDropContext &operator= ( const TargetDropContext&);
46 public:
47 	TargetDropContext( DropTarget* pTarget);
48 	~TargetDropContext();
49 
50 
51 	// XDropTargetDragContext
52     virtual void SAL_CALL acceptDrop( sal_Int8 dropOperation )
53 		throw( RuntimeException);
54     virtual void SAL_CALL rejectDrop(  )
55 		throw( RuntimeException);
56 
57 
58 /*	virtual Sequence< DataFlavor > SAL_CALL getCurrentDataFlavors(  )
59 		throw( RuntimeException);
60     virtual sal_Bool SAL_CALL isDataFlavorSupported( const DataFlavor& df )
61 		throw( RuntimeException);
62 */
63 
64 	// XDropTargetDropContext (inherits XDropTargetDragContext)
65     virtual void SAL_CALL dropComplete( sal_Bool success )
66 		throw(  RuntimeException);
67 };
68 #endif
69