United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-6649414 New plug-in continues to load Swing classes
JDK-6649414 : New plug-in continues to load Swing classes

Details
Type:
Bug
Submit Date:
2008-01-11
Status:
Closed
Updated Date:
2010-09-08
Project Name:
JDK
Resolved Date:
2008-01-31
Component:
deploy
OS:
generic
Sub-Component:
plugin
CPU:
generic
Priority:
P2
Resolution:
Fixed
Affected Versions:
6u10
Fixed Versions:
6u10 (b11)

Related Reports
Relates:

Sub Tasks

Description
###@###.### pointed out that the new Java Plug-In was still loading some Swing classes like javax.swing.JFrame in support of the ConsoleWindow, even if the Java Control Panel setting was to not show the Java Console. It was stated that the old Java Plug-In did not exhibit this behavior.

                                    

Comments
EVALUATION

Investigation with ###@###.### showed that because the return type of the method  sun.plugin.JavaRunTime.getJavaConsole() was ConsoleWindow, simply loading the JavaRunTime class was forcing ConsoleWindow and all of its superclasses to be loaded. This must have been true of the old plug-in as well, only because the old plug-in's tracing code was initialized later than in the new plug-in it was not apparent. Changing this method to return Object and doing explicit casts at the call sites solves the problem.
                                     
2008-01-11
SUGGESTED FIX

http://j2se.east.sun.com/deployment/www/webrevs/ccheung/1.6.0/6649414/webrev/
                                     
2008-01-11



Hardware and Software, Engineered to Work Together