revert 8e9d54b & 6c5ee14 due to bug in JDK 21

see https://bugs.openjdk.org/browse/JDK-8313323
This commit is contained in:
Sebastian Stenzel
2023-10-09 16:19:56 +02:00
parent 943374856e
commit 83879f5cfe
3 changed files with 9 additions and 9 deletions

View File

@@ -6,7 +6,7 @@ public interface IpcMessageListener {
default void handleMessage(IpcMessage message) {
switch (message) {
case RevealRunningAppMessage _ -> revealRunningApp();
case RevealRunningAppMessage m -> revealRunningApp(); // TODO: rename to _ with JEP 443
case HandleLaunchArgsMessage m -> handleLaunchArgs(m.args());
}
}

View File

@@ -101,16 +101,16 @@ public class StartController implements FxController {
}
}
private void loadingKeyFailed(Throwable e) {
switch (e) {
case UnlockCancelledException _ -> {} //ok
case VaultKeyInvalidException _ -> {
LOG.error("Invalid key"); //TODO: specific error screen
private void loadingKeyFailed(Throwable t) {
switch (t) {
case UnlockCancelledException e -> {} // ok // TODO: rename to _ with JEP 443
case VaultKeyInvalidException e -> { // TODO: rename to _ with JEP 443
LOG.error("Invalid key"); // TODO: specific error screen
appWindows.showErrorWindow(e, window, null);
}
default -> {
LOG.error("Failed to load key.", e);
appWindows.showErrorWindow(e, window, null);
LOG.error("Failed to load key.", t);
appWindows.showErrorWindow(t, window, null);
}
}
}

View File

@@ -109,7 +109,7 @@ public class AwtTrayMenuController implements TrayMenuController {
menuItem.setEnabled(a.enabled());
menu.add(menuItem);
}
case SeparatorItem _ -> menu.addSeparator();
case SeparatorItem s -> menu.addSeparator(); // TODO: rename to _ with JEP 443
case SubMenuItem s -> {
var submenu = new Menu(s.title());
addChildren(submenu, s.items());