I'm creating a Java program which pushes notifications and I want to remove or edit the line which says "Java(TM) Platform SE binary".
Is this possible? I searched on google but I couldn't see info about this.
Here is the related code. The last line is the line that pushes the notification.
public void mostrarNotificacion(Usuario user) throws AWTException, java.net.MalformedURLException, IOException {
//Obtain only one instance of the SystemTray object
SystemTray tray = SystemTray.getSystemTray();
//Get image
BufferedImage trayIconImage = ImageIO.read(getClass().getResource("favicon.png"));
int trayIconWidth = new TrayIcon(trayIconImage).getSize().width;
TrayIcon trayIcon = new TrayIcon(trayIconImage.getScaledInstance(trayIconWidth, -1, Image.SCALE_SMOOTH));
//Let the system resizes the image if needed
trayIcon.setImageAutoSize(true);
//Set tooltip text and notification text
if(user.getDescargos()>=5 || user.getOtrosPendientes()>=1){
mensaje = "Descargos pendientes: " + user.getDescargos() + "\nSecciones pendientes: "+ user.getOtrosPendientes();
}
trayIcon.setToolTip(mensaje);
tray.add(trayIcon);
trayIcon.displayMessage("Pendientes EKHI", mensaje, MessageType.WARNING);
}
Manage notifications Windows 10: Select Start > Settings > System > Notifications & actions. Manage notifications MacOS: Select Apple menu > System Preferences > Notifications. Manage notifications Android: Select your phone's Settings app > Apps & Notifications>
To get started, head to Settings > System > Notifications & actions – or, if you're on a Windows 10 PC, click here to open notifications & actions. First, send notifications, reminders and alarms directly to the action center by right-clicking action center in your taskbar, then selecting Turn on quiet hours.
"Java(TM) Platform SE binary" doesn't appear if you use TrayIcon.MessageType.NONE
Example Image:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With