1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
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_XDropTarget_idl__
21 #define __com_sun_star_datatransfer_dnd_XDropTarget_idl__
23 #include
<com
/sun
/star
/datatransfer
/XTransferable.idl
>
24 #include
<com
/sun
/star
/uno
/XInterface.idl
>
27 module com
{ module sun
{ module star
{ module datatransfer
{ module dnd
{
29 published
interface XDropTargetListener
;
31 /** This interface is implemented by a view or window that supports drop
34 <p>Differently to Java, the association between view and interface is fixed
35 and cannot be changed. Otherwise, the AWT messaging would have to be
36 implemented for any window supporting Drag and Drop operations, which would
37 be a performance issue.</p>
40 published
interface XDropTarget
: com
::sun
::star
::uno
::XInterface
42 /** Add a DropTargetListener.
44 <p>The listener will be queried for the XAutoscroll interface
45 to see if it supports autoscrolling.</p>
48 The listener to add to the notification list.
51 void addDropTargetListener
( [in] XDropTargetListener dtl
);
53 /** Remove a drop target listener.
56 The listener to remove from notification list.
59 void removeDropTargetListener
( [in] XDropTargetListener dtl
);
61 /** Indicates either a drop target object is active or not.
64 A boolean indicating whether or not this drop target object is
65 currently active, that is ready to accept drops.
70 /** Sets the drop target object active or inactive.
73 A value of `TRUE` sets the drop target object active.
74 <p>A value of `FALSE` sets the drop target object inactive.
77 void setActive
( [in] boolean active
);
79 /** Determine the actions supported by a drop target.
82 The current action or actions supported by this drop target.
84 <p>By default this will include all drag and drop actions.</p>
86 @see com::sun::star::datatransfer::dnd::DNDConstants
89 byte getDefaultActions
();
91 /** Sets the default acceptable actions for this drop target.
93 <p>This method is a way to reduce the number of Drag and Drop events
94 by blocking events for actions not supported by this target.</p>
95 <p>By default the listener will receive notifications for all actions.</p>
100 @see com::sun::star::datatransfer::dnd::DNDConstants
102 void setDefaultActions
( [in] byte actions
);
110 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */