Código java:
Ver original
try{ final TrayIcon trayIcon; if (SystemTray.isSupported()) { SystemTray tray = SystemTray.getSystemTray(); } } } } } }; } }; this.setExtendedState(0); //<<---problema---- } }; defaultItem.addActionListener(exitListener); abrir.addActionListener(abrirListener); popup.add(defaultItem); popup.add(abrir); trayIcon = new TrayIcon(image, "Tray Demo", popup); trayIcon.displayMessage("Action Event", "An Action Event Has Been Performed!", TrayIcon.MessageType.INFO); } }; trayIcon.setImageAutoSize(true); trayIcon.addActionListener(actionListener); trayIcon.addMouseListener(mouseListener); try { tray.add(trayIcon); } } else { // System Tray is not supported } } public void run() { new Marco().setVisible(true); } }); }