Charm 4.0.0 PopupView shows up only once

前端 未结 1 1386
刺人心
刺人心 2021-01-26 04:21

I have a set of Controls which use PopupView. Since the update to Charm 4.0.0, they show some weird behaviour.

When I selected a Node containe

相关标签:
1条回答
  • 2021-01-26 04:35

    Thanks for reporting. I've filed an issue so it get fixed as soon as possible.

    In the meantime, a workaround for the PopupView can be this:

    PopupView popupView = new PopupView(button) {
    
        private final GlassPane glassPane = MobileApplication.getInstance().getGlassPane();
    
            {
                this.setOnMouseReleased(e -> this.hide());
            }
    
        @Override public void show() {
            // before showing add the glassPane (issue #2):
            this.mobileLayoutPaneProperty().set(glassPane);
            super.show(); 
        }
    
        @Override public void hide() {
            // when hiding don't show again (issue #1):
            setShowing(false);
            super.hide(); 
        }
    };
    
    0 讨论(0)
提交回复
热议问题