Version 5.2.6.1, tag libreoffice-5.2.6.1
[LibreOffice.git] / offapi / com / sun / star / datatransfer / dnd / XDragSourceContext.idl
blobdd9f15b789462c7647eda21a94647f8a7aa730cd
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
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 __com_sun_star_datatransfer_dnd_XDragSourceContext_idl__
21 #define __com_sun_star_datatransfer_dnd_XDragSourceContext_idl__
23 #include <com/sun/star/lang/IllegalArgumentException.idl>
26 module com { module sun { module star { module datatransfer { module dnd {
28 published interface XDragSourceListener;
30 /** The drag source context class is responsible for managing the initiator side
31 of the Drag and Drop protocol.
33 <p>In particular, it is responsible for managing event notifications to the
34 DragSourceListener and providing the Transferable state to enable the data
35 transfer. </p>
37 <p>An instance of this class is created as a result of the method XDragSource::startDrag()
38 being successfully invoked. This instance is responsible
39 for tracking the state of the operation on behalf of the drag source and
40 dispatching state changes to the drag source listener. </p>
42 @see com::sun::star::datatransfer::dnd::XDragSourceContext
43 @see com::sun::star::datatransfer::dnd::XDragSourceListener
46 published interface XDragSourceContext: com::sun::star::uno::XInterface
48 /** Get the identifier of the currently used cursor.
50 @returns
51 The currently selected drag cursor.
54 long getCurrentCursor();
56 /** This method sets the current drag cursor.
58 <p>This method should only be called to set another cursor than the
59 default one for drag action currently selected by the user.</p>
60 <p>Invalid cursor identifiers will be ignored.</p>
62 @param cursorId
63 The identifier the drag source returned when registering the cursor.
66 void setCursor( [in] long cursorId );
68 /** This method sets the current drag image.
70 @param imageId
71 The identifier the drag source returned when registering the image (0 = none).
72 Invalid identifier will be ignored.
75 void setImage( [in] long imageId );
77 /** This method notifies the context that the
78 com::sun::star::datatransfer::DataFlavor types
79 of the transferable object have changed.
81 @see com::sun::star::datatransfer::XTransferable
84 void transferablesFlavorsChanged();
88 }; }; }; }; };
90 #endif
92 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */