Populating applet text components

Scott Kovatch scott.kovatch at oracle.com
Wed Nov 28 08:13:51 PST 2012


On Nov 28, 2012, at 2:48 AM, Michael Hall <mik3hall at gmail.com> wrote:

> I have just been coding an applet where I intended some slightly involved text to be pasted into a text component.
> I found out as per [1] that a 1.6 update eliminated applet paste access to the clipboard.
> In appletviewer testing I tried drag and drop and that seemed to work, so this seemed a reasonable other option.
> This morning I uploaded the applet and tried to test there. Drag and drop did not work from either Safari or Firefox.
> Does the browser provide a blocking layer that keeps the drag and drop from getting to the applet? If not is something wrong in the implementation that keeps it from working in the browsers.
> Given that paste doesn't work this would be a nice substitute option to have working. 

Drag and drop unfortunately won't work due to limitations in the NPAPI. All plugins run in their own process. What you are seeing in the applet area is actually an image of what the applet process has rendered. This also means that any event that is intended for the applet has to be serialized and sent to the plugin process. This works well for mouse, key and window activation events but no provision was made for drag-type events, so there's no way to know what was dragged onto the applet.

This will require changes from all of the browsers, so I'm not optimistic it will ever happen.

-- Scott K.

----------------------------------------
Scott Kovatch
scott.kovatch at oracle.com
Santa Clara/Pleasanton, CA



More information about the macosx-port-dev mailing list