United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-8020371 [macosx] applets with Drag and Drop fail with IllegalArgumentException
JDK-8020371 : [macosx] applets with Drag and Drop fail with IllegalArgumentException

Details
Type:
Bug
Submit Date:
2013-07-11
Status:
Closed
Updated Date:
2013-11-19
Project Name:
JDK
Resolved Date:
2013-07-15
Component:
client-libs
OS:
os_x
Sub-Component:
java.awt
CPU:
Priority:
P2
Resolution:
Fixed
Affected Versions:
8
Fixed Versions:

Related Reports
Backport:
Backport:
Backport:
Backport:
Relates:

Sub Tasks

Description
Applets which explicitly call component.setDropTarget(new DropTarget()) fail with IllegalArgumentException.

This is a regression of the fix for JDK-8006941.

The proposed testcase:

import javax.swing.*;
import java.awt.dnd.DropTarget;

public class NewTabApplet extends JApplet {

    public void init() {
        JButton b = new JButton("Click me");
        b.setDropTarget(new DropTarget());
        this.add(b);
    }
}

Expected behavior: applet starts and shows the button.
Real behavior: applet fails with IllegalArgumentException
                                    

Comments
URL:   http://hg.openjdk.java.net/jdk8/awt/jdk/rev/d52fc9384765
User:  pchelko
Date:  2013-07-15 08:06:59 +0000

                                     
2013-07-15
URL:   http://hg.openjdk.java.net/jdk8/jdk8/jdk/rev/d52fc9384765
User:  lana
Date:  2013-07-23 18:11:27 +0000

                                     
2013-07-23
The issue could be reproducible only in applet mode, so it's hard to create a regression test.
                                     
2013-08-22



Hardware and Software, Engineered to Work Together