Drag & Drop functionality for JAVA GUI components

Class for Drag & Drop functionality
ダウンロード: 1K
更新 2015/10/13

ライセンスの表示

obj = dndcontrol(javaobj) creates a dndcontrol object for the specified Java object, such as 'javax.swing.JTextArea' or 'javax.swing.JList'. Two callback functions are available: obj.DropFileFcn and obj.DropStringFcn, that listen to drop actions of respectively system files or plain text.

The Drag & Drop control class relies on a Java class "MLDropTarget.class" that need to be visible on the Java classpath. To initialize, call the static method dndcontrol.initJava(). The Java class can be adjusted and recompiled if desired.
A demonstration is available from the static method dndcontrol.demo().

Example:
dndcontrol.initJava();
dndcontrol.demo();

Written by: Maarten van der Seijs, 2015.

引用

Maarten van der Seijs (2024). Drag & Drop functionality for JAVA GUI components (https://www.mathworks.com/matlabcentral/fileexchange/53511-drag-drop-functionality-for-java-gui-components), MATLAB Central File Exchange. 取得済み .

MATLAB リリースの互換性
作成: R2009b
すべてのリリースと互換性あり
プラットフォームの互換性
Windows macOS Linux
カテゴリ
Help Center および MATLAB AnswersMigrate GUIDE Apps についてさらに検索
タグ タグを追加
謝辞

ヒントを得たファイル: UICOMPONENT - expands uicontrol to all Java classes

ヒントを与えたファイル: DropListener, MATLAB version of ImageJ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
バージョン 公開済み リリース ノート
1.0.0.0