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 .
21 module com
{ module sun
{ module star
{ module datatransfer
{ module dnd
{
23 published
interface XDropTargetListener
;
25 /** This interface is implemented by a view or window that supports drop
28 <p>Differently to Java, the association between view and interface is fixed
29 and cannot be changed. Otherwise, the AWT messaging would have to be
30 implemented for any window supporting Drag and Drop operations, which would
31 be a performance issue.</p>
34 published
interface XDropTarget
: com
::sun
::star
::uno
::XInterface
36 /** Add a DropTargetListener.
38 <p>The listener will be queried for the XAutoscroll interface
39 to see if it supports autoscrolling.</p>
42 The listener to add to the notification list.
45 void addDropTargetListener
( [in] XDropTargetListener dtl
);
47 /** Remove a drop target listener.
50 The listener to remove from notification list.
53 void removeDropTargetListener
( [in] XDropTargetListener dtl
);
55 /** Indicates either a drop target object is active or not.
58 A boolean indicating whether or not this drop target object is
59 currently active, that is ready to accept drops.
64 /** Sets the drop target object active or inactive.
67 A value of `TRUE` sets the drop target object active.
68 <p>A value of `FALSE` sets the drop target object inactive.
71 void setActive
( [in] boolean active
);
73 /** Determine the actions supported by a drop target.
76 The current action or actions supported by this drop target.
78 <p>By default this will include all drag and drop actions.</p>
80 @see com::sun::star::datatransfer::dnd::DNDConstants
83 byte getDefaultActions
();
85 /** Sets the default acceptable actions for this drop target.
87 <p>This method is a way to reduce the number of Drag and Drop events
88 by blocking events for actions not supported by this target.</p>
89 <p>By default the listener will receive notifications for all actions.</p>
94 @see com::sun::star::datatransfer::dnd::DNDConstants
96 void setDefaultActions
( [in] byte actions
);
102 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */