LiveConnect nyi (applet to JS communication does not work)

Bug #282762 reported by Matthias Klose
6
Affects Status Importance Assigned to Milestone
OpenJDK
Fix Released
Medium
cacao-oj6 (Ubuntu)
Fix Released
Medium
Unassigned
Intrepid
Fix Released
Medium
Unassigned
openjdk-6 (Ubuntu)
Fix Released
Medium
Unassigned
Intrepid
Fix Released
Medium
Unassigned

Bug Description

separate report for the second half of bug #207064

JS to Applet communication work but applet to JS communication does not work. You can verify this with the apple liveconnect test at http://developer.apple.com/internet/safari/samples/ColorBlockApplet.html
You'll see the color change when you click on the buttons but when you double click the applet there is no alert message.

Revision history for this message
In , Matthias Klose (doko) wrote :

JS to Applet communication work but applet to JS communication does not work. You can verify this with the apple liveconnect test at http://developer.apple.com/internet/safari/samples/ColorBlockApplet.html
You'll see the color change when you click on the buttons but when you double click the applet there is no alert message.

Changed in openjdk-6:
importance: Undecided → Medium
status: New → Confirmed
Changed in openjdk:
status: Unknown → Confirmed
Revision history for this message
In , Dbhole (dbhole) wrote :

This is a bug in the applet page. Liveconnect specifications state that MAYSCRIPT must be specified for Java->JS to work[1]. The ColorBlockApplet does not set this.

1. http://java.sun.com/j2se/1.4.2/docs/guide/plugin/developer_guide/java_js.html#enabling

Revision history for this message
In , mkaz (mubashir-kazia) wrote :

(In reply to comment #1)
> This is a bug in the applet page. Liveconnect specifications state that
> MAYSCRIPT must be specified for Java->JS to work[1]. The ColorBlockApplet does
> not set this.
>
> 1.
> http://java.sun.com/j2se/1.4.2/docs/guide/plugin/developer_guide/java_js.html#enabling
>

I tested after adding MAYSCRIPT tag it still does not work. It cannot find netscape.javascript.JSObject class.

Revision history for this message
In , Dbhole (dbhole) wrote :

Did you try it it with the new plugin (IcedTeaPlugin.so, built with --enable-liveconnect), or the old one? The old one (gcjwebplugin) is expected to throw that exception...

Revision history for this message
In , mkaz (mubashir-kazia) wrote :

Yes I can confirm that IcedTeaPlugin.so is used from Firefox3 in about:plugins. I also looked at the output when firefox is launched from command prompt. Can you tell me in which jar file netscape classes are supposed to be packaged?

Revision history for this message
In , Dbhole (dbhole) wrote :

Assuming you are using the tip, the classes should be in rt.jar

Revision history for this message
In , mkaz (mubashir-kazia) wrote :

I'm using ubuntu intrepid compiled package version 6b12-pre2-0ubuntu2 and the only Netscape class that is in rt.jar is sun.security.x509.NetscapeCertTypeExtention.
There are no netscape JS classes.

Revision history for this message
In , Dbhole (dbhole) wrote :

Hmm, AFAIK Ubuntu does not compile with liveconnect support. And if it did, it should have had the classes in rt.jar.

Can you post the output of about:plugins?

Revision history for this message
In , mkaz (mubashir-kazia) wrote :

Created attachment 116
Output of about:plugins

Revision history for this message
In , mkaz (mubashir-kazia) wrote :

Created attachment 117
Output of about:plugins

Revision history for this message
mkaz (mubashir-kazia) wrote :

This might be a packaging issue. Some classes that are required by icedtea6-plugin are supposed to be in rt.jar (as informed by Deepak Bhole @ redhat). rt.jar is part of openjdk-6-jre-headless and these classes are not found in the rt.jar there. The classes in question are
netscape.javascript.*.
The sources for these classes are however present in the source package in the directory openjdk-6-6b12~pre2/plugin/icedtea

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package openjdk-6 - 6b12~pre2-0ubuntu3

---------------
openjdk-6 (6b12~pre2-0ubuntu3) intrepid; urgency=low

  * Update IcedTea build infrastructure (20081015).
  * Add netscape/javascript class files to rt.jar. LP: #282762.
  * Be more verbose in the icedtea6-plugin package description.
  * Fix some lintian warnings.

 -- Matthias Klose <email address hidden> Wed, 15 Oct 2008 12:45:59 +0200

Changed in openjdk-6:
status: Confirmed → Fix Released
Revision history for this message
In , Matthias Klose (doko) wrote :

the current package in Ubuntu intrepid is configured with --enable-liveconnect.

there seems to be a problem about adding the netscape/javascript classes into the rt.jar, which is built in stage2. In the icedtea Makefile, these files are only included in rt-closed.jar, but not in the rt.jar, which is served at the end of the build.

Revision history for this message
In , Matthias Klose (doko) wrote :

tracked down the missing files to configuring with --with-alt-jar=/usr/bin/fastjar. Didn't find yet the cause. The current Ubuntu build does include these files.

--- rt-jar.list 2008-10-17 07:50:22.000000000 +0000
+++ rt-fastjar.list 2008-10-17 07:50:31.000000000 +0000
@@ -11008,11 +11008,6 @@
 net/sourceforge/jnlp/util/WeakList.class
 net/sourceforge/nanoxml/XMLElement.class
 net/sourceforge/nanoxml/XMLParseException.class
-netscape/javascript/JSException.class
-netscape/javascript/JSObject.class
-netscape/javascript/JSProxy.class
-netscape/javascript/JSRunnable.class
-netscape/javascript/JSUtil.class
 org/ietf/jgss/ChannelBinding.class
 org/ietf/jgss/GSSContext.class
 org/ietf/jgss/GSSCredential.class

Revision history for this message
In , Matthias Klose (doko) wrote :

In http://people.ubuntu.com/~doko/java/ColorBlockApplet.html
I added the MAYSCRIPT attribute, but I still cannot a reaction clicking on the applet area.

Revision history for this message
In , Dbhole (dbhole) wrote :

Fixed in tip -- http://people.ubuntu.com/~doko/java/ColorBlockApplet.html works for me now. Can you please retry?

Revision history for this message
Matthias Klose (doko) wrote :

applet -> LiveConnect communications doesn't work yet.

Changed in openjdk-6:
status: Fix Released → In Progress
Changed in cacao-oj6:
importance: Undecided → Medium
status: New → In Progress
Revision history for this message
In , Matthias Klose (doko) wrote :

fixed now.

there's one glitch. Clicking the first time on a button doesn't change the color, only with the second click the color is changed (but then it is changed two times).

Revision history for this message
In , Dbhole (dbhole) wrote :

There is a 3-4 second delay for the first action to happen, as mozilla builds a table of java objects initially.

How long did you wait after the first click? One way to verify that it was slow (as opposed to not working) is to run with the ICEDTEAPLUGIN_DEBUG variable set. This will slow things down a lot, but if it's outputting after first click, it means that it is processing...

Matthias Klose (doko)
Changed in openjdk-6:
milestone: none → ubuntu-8.10
Changed in cacao-oj6:
milestone: none → ubuntu-8.10
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package openjdk-6 - 6b12-0ubuntu3

---------------
openjdk-6 (6b12-0ubuntu3) intrepid; urgency=low

  * Update IcedTea build infrastructure (20081018).
    - Fix LiveConnect issues in the web plugin. LP: #282762.
    - Fail the build, if patches don't apply.
  * Show xvfb and xauth failures in the build log, when running the testsuites.
  * Kill processes which still hang after running the testsuite. Closes: #493339.
  * Run the testsuite in parallel, reducing build time.
  * openjdk-headless: Depend instead of recommending tzdata-java.

 -- Matthias Klose <email address hidden> Sat, 18 Oct 2008 17:15:14 +0200

Changed in openjdk-6:
status: In Progress → Fix Released
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package cacao-oj6 - 6b12-0ubuntu2

---------------
cacao-oj6 (6b12-0ubuntu2) intrepid; urgency=low

  * Update IcedTea build infrastructure (20081018).
    - Fix LiveConnect issues in the web plugin. LP: #282762.
    - Fail the build, if patches don't apply.
  * Show xvfb and xauth failures in the build log, when running the testsuites.
  * Kill processes which still hang after running the testsuite.
    Addresses: #493339.
  * Run the testsuite in parallel, reducing build time.
  * cacao-headless: Depend instead of recommending tzdata-java.

 -- Matthias Klose <email address hidden> Sat, 18 Oct 2008 17:12:49 +0200

Changed in cacao-oj6:
status: In Progress → Fix Released
Changed in openjdk:
status: Confirmed → Fix Released
Revision history for this message
jeanseb (jeanseb-valette) wrote :

I got the bug too with "cacao-oj6-plugin - 6b12-0ubuntu5 " , 64 bit

My bank applet (trade station)" dont start.

Changed in openjdk:
importance: Unknown → Medium
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.