diff --git a/modules/platform-ui/src/main/java/com/shade/platform/ui/menus/impl/MenuManagerImpl.java b/modules/platform-ui/src/main/java/com/shade/platform/ui/menus/impl/MenuManagerImpl.java index a1f954a90..66ecd0666 100644 --- a/modules/platform-ui/src/main/java/com/shade/platform/ui/menus/impl/MenuManagerImpl.java +++ b/modules/platform-ui/src/main/java/com/shade/platform/ui/menus/impl/MenuManagerImpl.java @@ -456,9 +456,15 @@ public void update() { } putValue(Action.NAME, Objects.requireNonNullElseGet(item.getName(context), metadata::name)); - putValue(Action.SHORT_DESCRIPTION, metadata.description()); putValue(Action.SMALL_ICON, icon); + if (metadata.keystroke().isEmpty()) { + putValue(Action.SHORT_DESCRIPTION, metadata.description()); + } else { + final String accelerator = UIUtils.getTextForAccelerator(KeyStroke.getKeyStroke(metadata.keystroke())); + putValue(Action.SHORT_DESCRIPTION, "%s (%s)".formatted(metadata.description(), accelerator)); + } + if (item instanceof MenuItem.Check check) { putValue(Action.SELECTED_KEY, check.isChecked(context)); } else if (item instanceof MenuItem.Radio radio) {