| 接口 | 描述 |
|---|---|
| Autoscroll |
在DND操作可能是用户可能希望下降的运营主体在一个滚动的GUI控件,当前对用户不可见区域。
|
| DragGestureListener |
用于接收拖曳手势事件的侦听器接口。
|
| DragSourceListener |
的
DragSourceListener进行拖放操作来跟踪用户的手势国家创始人的事件接口,并提供相应的“拖”反馈给用户在拖放操作。
|
| DragSourceMotionListener |
在拖动操作期间接收鼠标运动事件的侦听器接口。
|
| DropTargetListener |
的
DropTargetListener接口由
DropTarget类用于提供对DND操作涉及课题
DropTarget通知回调接口。
|
| 类 | 描述 |
|---|---|
| DnDConstants |
此类包含表示要执行的拖放操作的操作类型的常量值。
|
| DragGestureEvent |
一个
DragGestureEvent传递给
DragGestureListener的draggesturerecognized()方法当一个特定的
DragGestureRecognizer检测到发生在
Component是跟踪具有平台依赖拖启动手势。
|
| DragGestureRecognizer |
的
DragGestureRecognizer是一个可以与一个特定的
Component为了识别依赖于平台的拖启动手势相关平台依赖的听众的规范抽象基类。
|
| DragSource |
的
DragSource负责拖放操作开始的实体,并可用于多种方案:1每JVM默认实例的JVM的一生。
|
| DragSourceAdapter |
用于接收拖动源事件的抽象适配器类。
|
| DragSourceContext |
的
DragSourceContext类负责管理引发一侧的拖放协议。
|
| DragSourceDragEvent |
的
DragSourceDragEvent从
DragSourceContextPeer交付,通过
DragSourceContext,到
DragSourceListener,
DragSourceContext和与其相关的
DragSource注册。
|
| DragSourceDropEvent |
的
DragSourceDropEvent从
DragSourceContextPeer交付,通过
DragSourceContext,到那
DragSourceContext和与其相关的
DragSource
DragSourceListeners
dragDropEnd注册的方法。
|
| DragSourceEvent |
这类是
DragSourceDragEvent和
DragSourceDropEvent基类。
|
| DropTarget |
这是一个
DropTarget
Component相关时,
Component希望接受拖放操作期间下降。
|
| DropTarget.DropTargetAutoScroller |
这个保护嵌套类实现自动滚动
|
| DropTargetAdapter |
用于接收拖放目标事件的抽象适配器类。
|
| DropTargetContext |
一个
DropTargetContext创建与拖放操作时恰逢一个
DropTarget相关
Component可见几何体相关的逻辑光标。
|
| DropTargetDragEvent |
的
DropTargetDragEvent通过其dragenter()和dragover()方法传递到
DropTargetListener。
|
| DropTargetDropEvent |
的
DropTargetDropEvent通过
DropTargetListener drop()方法交付。
|
| DropTargetEvent |
的
DropTargetEvent是
DropTargetDragEvent和
DropTargetDropEvent基类。
|
| MouseDragGestureRecognizer |
这个抽象类定义了一个基于
DragGestureRecognizer鼠标手势
DragGestureRecognizer。
|
| 异常 | 描述 |
|---|---|
| InvalidDnDOperationException |
被各种方法在java.awt.dnd包这是例外。
|
此包定义的类和接口,需要在java执行拖放操作。它定义了拖动源和拖放目标的类,以及将被拖动的数据传输的事件。此软件包还提供了一种方法,用于在拖放操作期间给用户提供视觉反馈给用户。
一个典型的拖放操作可以分解成以下状态(不完全按顺序):
DragSource应运而生,一些表现元素相关(Component)在GUI,启动阻力和一些潜在的Transferable数据下降。DropTarget(S)来/不存在,在GUI演示相关的元素(组件),具有潜在的消费Transferable数据类型。DragGestureRecognizer从DragSource并以Component跟踪和识别任何拖在Component用户启动手势有关。Component,该注册DragGestureRecognizer检测,并通知其DragGestureListener的。注:虽然这个API一致是指刺激拖放操作是由人类用户的身体姿态,这并不排除编程驱动DND操作给出一个DragSource适当的实现。此包包含鼠标手势识别装置的抽象类MouseDragGestureRecognizer。抽象类可以由平台提供支持的其他输入设备或特定的Component类语义。
DragGestureListener使DragSource启动阻力和代表用户的删除操作,也许动画GUI光标和/或绘制的项目Image(S),是行动的主体。Component(S)与相关DropTarget GUI(S)的DragSource接收通知,以便提供“过度”的反馈效应拖累,和DropTarget(S)收到通知,为了提供“基于操作的反馈作用下“拖(S)支持和数据型(S)参与。手势本身移动光标在图形用户界面的逻辑层次,交叉的GUI组件的几何(S),可能会导致逻辑“拖”光标进入路口,随后离开Component(S)和相关的DropTarget(S)。
的DragSource对象体现“结束”反馈给用户拖动,在典型的动画与逻辑相关的GUI Cursor光标。
DropTarget对象清单”拖向用户反馈下”,在典型的情况下,通过渲染动画到相关的GUI Component(S)GUI光标下。
的反馈效应的确定,和最终的成功或失败的数据传输,应该一个发生,参数化如下:
DragSource和DropTarget支持:复制、移动或引用(链接)。DragSource和数据类型的可理解的DropTarget集提供的数据类型集的交集。DragSource和DropTarget接收通知,包括导致型谈判和转移,通过Transferable对象相关的信息DragSource。 Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2014, Oracle and/or its affiliates. All rights reserved.