/hg/icedtea-web: remove control panel's dependency on JNLPRuntim...

Andrew Su asu at redhat.com
Wed Jan 12 08:35:22 PST 2011



----- Original Message -----
> From: "Omair Majid" <omajid at redhat.com>
> To: "Andrew Su" <asu at redhat.com>
> Cc: distro-pkg-dev at openjdk.java.net
> Sent: Wednesday, January 12, 2011 10:53:01 AM
> Subject: Re: /hg/icedtea-web: remove control panel's dependency on JNLPRuntim...
> On 01/12/2011 10:00 AM, Andrew Su wrote:
> > Hello Omair,
> >
> > I was trying to use control panel to set some values, but noticed
> > the look and feel was not how it should be and also I get a few
> > exceptions from CertificatePane.
> >
> > java.lang.NullPointerException
> > 	at java.io.File.<init>(File.java:239)
> > 	at
> > 	net.sourceforge.jnlp.security.KeyStores.getKeyStore(KeyStores.java:124)
> > 	at
> > 	net.sourceforge.jnlp.security.KeyStores.getKeyStore(KeyStores.java:103)
> > 	at
> > 	net.sourceforge.jnlp.security.viewer.CertificatePane.initializeKeyStore(CertificatePane.java:148)
> > 	at
> > 	net.sourceforge.jnlp.security.viewer.CertificatePane.repopulateTables(CertificatePane.java:285)
> > 	at
> > 	net.sourceforge.jnlp.security.viewer.CertificatePane.<init>(CertificatePane.java:140)
> > 	at
> > 	net.sourceforge.jnlp.controlpanel.ControlPanel.createCertificatesSettingsPanel(ControlPanel.java:276)
> > 	at
> > 	net.sourceforge.jnlp.controlpanel.ControlPanel.createMainSettingsPanel(ControlPanel.java:220)
> > 	at
> > 	net.sourceforge.jnlp.controlpanel.ControlPanel.<init>(ControlPanel.java:108)
> > 	at
> > 	net.sourceforge.jnlp.controlpanel.ControlPanel$5.run(ControlPanel.java:360)
> > 	at
> > 	java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:226)
> > 	at java.awt.EventQueue.dispatchEvent(EventQueue.java:602)
> > 	at
> > 	java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:275)
> > 	at
> > 	java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:200)
> > 	at
> > 	java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:190)
> > 	at
> > 	java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:185)
> > 	at
> > 	java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:177)
> > 	at java.awt.EventDispatchThread.run(EventDispatchThread.java:138)
> > java.lang.NullPointerException
> > 	at
> > 	net.sourceforge.jnlp.security.viewer.CertificatePane.readKeyStore(CertificatePane.java:258)
> > 	at
> > 	net.sourceforge.jnlp.security.viewer.CertificatePane.repopulateTables(CertificatePane.java:286)
> > 	at
> > 	net.sourceforge.jnlp.security.viewer.CertificatePane.<init>(CertificatePane.java:140)
> > 	at
> > 	net.sourceforge.jnlp.controlpanel.ControlPanel.createCertificatesSettingsPanel(ControlPanel.java:276)
> > 	at
> > 	net.sourceforge.jnlp.controlpanel.ControlPanel.createMainSettingsPanel(ControlPanel.java:220)
> > 	at
> > 	net.sourceforge.jnlp.controlpanel.ControlPanel.<init>(ControlPanel.java:108)
> > 	at
> > 	net.sourceforge.jnlp.controlpanel.ControlPanel$5.run(ControlPanel.java:360)
> > 	at
> > 	java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:226)
> > 	at java.awt.EventQueue.dispatchEvent(EventQueue.java:602)
> > 	at
> > 	java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:275)
> > 	at
> > 	java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:200)
> > 	at
> > 	java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:190)
> > 	at
> > 	java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:185)
> > 	at
> > 	java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:177)
> > 	at java.awt.EventDispatchThread.run(EventDispatchThread.java:138)
> >
> >
> > The reason the use of JNLPRuntime was so that CertificatePane didn't
> > do this + it also sets the look and feel.
> >
> 
> Thanks for catching the error. I noticed the look and feel problem
> myself this morning, but I didnt notice the exceptions.
> 
> I would really like to avoid calling JNLPRuntime.initialize(), since
> that sets up a whole bunch of other stuff that the control panel
> really
> does not need - such as the security manager, security threads and so
> on. Ideally, there would be no dependencies to anything else in Netx
> either, but CertificatePane is intent on making things more
> interesting
> for us :/
> 
> The attached patch is my attempt at fixing things.
> 
> Or do you think it would be better to revert the original patch
> (remove
> the dependency on JNLPRuntime) ?

Hi Omair,

This patch looks fine to me and also fixes the issues mentioned. 
I am for not using JNLPRuntime.initialize() as well.
Thanks for the quick fix!

Cheers,
  Andrew


> 
> Cheers,
> Omair



More information about the distro-pkg-dev mailing list