summaryrefslogtreecommitdiff
path: root/BKUWebStart/src
diff options
context:
space:
mode:
authortkellner <tkellner@8a26b1a7-26f0-462f-b9ef-d0e30c41f5a4>2014-03-12 16:36:52 +0000
committertkellner <tkellner@8a26b1a7-26f0-462f-b9ef-d0e30c41f5a4>2014-03-12 16:36:52 +0000
commit80e3cf38ac1541e1f2033b16b47a5a91b34cff4a (patch)
tree834b3414205172d1e9ea0c4f5f88c995ec288a82 /BKUWebStart/src
parent7a5154ca243b6f65f83b3ea14d3dac5510ca15e1 (diff)
downloadmocca-80e3cf38ac1541e1f2033b16b47a5a91b34cff4a.tar.gz
mocca-80e3cf38ac1541e1f2033b16b47a5a91b34cff4a.tar.bz2
mocca-80e3cf38ac1541e1f2033b16b47a5a91b34cff4a.zip
Catch null trayicon event (double click)
git-svn-id: https://joinup.ec.europa.eu/svn/mocca/trunk@1309 8a26b1a7-26f0-462f-b9ef-d0e30c41f5a4
Diffstat (limited to 'BKUWebStart/src')
-rw-r--r--BKUWebStart/src/main/java/at/gv/egiz/bku/webstart/gui/MOCCAIcon.java11
1 files changed, 8 insertions, 3 deletions
diff --git a/BKUWebStart/src/main/java/at/gv/egiz/bku/webstart/gui/MOCCAIcon.java b/BKUWebStart/src/main/java/at/gv/egiz/bku/webstart/gui/MOCCAIcon.java
index eaf2bee5..1b9996fc 100644
--- a/BKUWebStart/src/main/java/at/gv/egiz/bku/webstart/gui/MOCCAIcon.java
+++ b/BKUWebStart/src/main/java/at/gv/egiz/bku/webstart/gui/MOCCAIcon.java
@@ -229,6 +229,11 @@ public class MOCCAIcon implements StatusNotifier, ActionListener, ItemListener {
*/
@Override
public void actionPerformed(ActionEvent e) {
+ if ((e == null) || (e.getActionCommand() == null)) {
+ log.debug("tray menu command is null");
+ return;
+ }
+
switch (COMMANDS.valueOf(e.getActionCommand())) {
case SHUTDOWN_COMMAND:
log.debug("shutdown requested via tray menu");
@@ -262,12 +267,12 @@ public class MOCCAIcon implements StatusNotifier, ActionListener, ItemListener {
log.debug("get-certificate dialog requested via tray menu");
controller.getCertificate(messages.getLocale());
break;
-
+
case HARDWAREINFO_COMMAND:
log.debug("hardware-info dialog requested via tray menu");
controller.hardwareInfo(messages.getLocale());
break;
-
+
case HELP_COMMAND:
log.debug("help page requested via tray menu");
controller.showHelp(messages.getLocale());
@@ -277,7 +282,7 @@ public class MOCCAIcon implements StatusNotifier, ActionListener, ItemListener {
log.debug("identity link dialog requested via tray menu");
controller.getIdentityLink(messages.getLocale());
break;
-
+
default:
log.error("unknown tray menu command: " + e.getActionCommand());
}