Tray icon problem

12 views
Skip to first unread message

sozonovsky

unread,
Oct 6, 2011, 4:11:58 AM10/6/11
to easytesting
Hi all,

Unable to find how to add issue to project Jira, so posting it here.
We are using fest to run cucumber scripts on Java UI. Our application
started automatiaclly, some cucumber scripts are converted to fest
code calls, ui clicked, all is ok. After cucumber finished,
appliaction still works (by intention), but its tray icon popup gets
unavailable and I see exceptions in console:

Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
at org.fest.swing.awt.AWT.locationOnScreenOf(AWT.java:278)
at org.fest.swing.input.InputState.updateState(InputState.java:97)
at org.fest.swing.input.InputState.update(InputState.java:78)
at org.fest.swing.input.InputState$1.processEvent(InputState.java:53)
at
org.fest.swing.listener.EventDispatchThreadedEventListener.eventDispatched(EventDispatchThreadedEventListener.java:
72)
at org.fest.swing.input.EventNormalizer.delegate(EventNormalizer.java:
86)
....

Quick research shows that problem is in locationOnScreenOf method
where code expects that mouseEvent.getComponen() returns not null
value.
But that is not correct, because of Javadoc of TrayIcon says that
there should be null in case of TrayIcon. See
http://download.oracle.com/javase/6/docs/api/java/awt/TrayIcon.html
for details.

Is there a chance to get that fixed in next version? Could also me
write some code to workaround the issue?

Thanks in advance,
Pavel Sozonovsky
Reply all
Reply to author
Forward
0 new messages