valid = false;
if (SystemTray.isSupported()) {
Image image = Toolkit.getDefaultToolkit().getImage(getClass().getResource("/com/art/anette/client/ui/resources/logo.png"));
PopupMenu popup = createPopupMenu(mainWindow);
trayForm = new TrayForm(logic, guiController);
Dimension d = Toolkit.getDefaultToolkit().getScreenSize();
trayForm.setLocation(d.width - trayForm.getWidth(), d.height - trayForm.getHeight() - 30);
trayIcon = new TrayIcon(image, String.format(lang.getString("TrayTitle"), Global.APP_NAME), popup);
trayIcon.setImageAutoSize(true);
trayIcon.addMouseListener(this);