Merge pull request #4874 from jmacxx/fix_systray_error

Prevent annoying popup errors for unhandled systray exception.
This commit is contained in:
Christoph Atteneder 2020-12-03 21:21:47 +01:00 committed by GitHub
commit c782f22fe8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -74,6 +74,9 @@ public class CommonSetup {
} else if (throwable instanceof ClassCastException &&
"sun.awt.image.BufImgSurfaceData cannot be cast to sun.java2d.xr.XRSurfaceData".equals(throwable.getMessage())) {
log.warn(throwable.getMessage());
} else if (throwable instanceof UnsupportedOperationException &&
"The system tray is not supported on the current platform.".equals(throwable.getMessage())) {
log.warn(throwable.getMessage());
} else {
log.error("Uncaught Exception from thread " + Thread.currentThread().getName());
log.error("throwableMessage= " + throwable.getMessage());