mirror of
https://github.com/HMCL-dev/HMCL.git
synced 2025-08-03 11:26:38 -04:00
通过主页右下角弹出菜单切换版本后隐藏菜单 (#4163)
This commit is contained in:
parent
401fef5774
commit
c84afb3155
@ -276,7 +276,10 @@ public final class MainPage extends StackPane implements DecoratorPage {
|
||||
FXUtils.onClicked(menu, popup::hide);
|
||||
versionNodes = MappedObservableList.create(versions, version -> {
|
||||
Node node = PopupMenu.wrapPopupMenuItem(new GameItem(profile, version.getId()));
|
||||
FXUtils.onClicked(node, () -> profile.setSelectedVersion(version.getId()));
|
||||
FXUtils.onClicked(node, () -> {
|
||||
profile.setSelectedVersion(version.getId());
|
||||
popup.hide();
|
||||
});
|
||||
return node;
|
||||
});
|
||||
Bindings.bindContent(menu.getContent(), versionNodes);
|
||||
|
Loading…
x
Reference in New Issue
Block a user