My popup always covered other windows
Answered
Hello, Everyone I got into a problem these dasy, my popup always covered other windows ,it's like this

I want to let my popup like a normal window and not aways covered other windows
I have read ComponentPopupBuilder.class many times , I really did't find way to deal it
Here is my code
private void customerPopupDialog(){
JBPopupFactory instance = JBPopupFactory.getInstance();
JButton button = new JButton("Hello Idea Plugin");
JPanel panel = new JPanel();
panel.setSize(40,20);
panel.add(button);
button.addActionListener(e -> new MyDialog(Application.project,"Test").show());
instance.createComponentPopupBuilder(panel, new JBLabel())
.setTitle("Customer Popup Dialog")
.setMovable(true)
.setResizable(true)
.setMayBeParent(true)
.setDimensionServiceKey(null,"com.yatoufang.test",true)
.setNormalWindowLevel(true)
.setMinSize(new Dimension(600,300))
.createPopup()
.showInFocusCenter();
}
Does anyone know how to solve it
Please sign in to leave a comment.
Sorry, I don't understand how a popup would not cover underlying windows by default. Please show a screenshot from existing UI to clarify what you want to achieve.
ok,I made a new screetshot. Is that mean popup always a top level window
This might be related to:
- https://youtrack.jetbrains.com/issue/IDEA-244182
- https://intellij-support.jetbrains.com/hc/en-us/community/posts/360008758199-JCEF-heavyweight-popup-closes-too-early-or-always-stay-on-top
Though my issue was on Linux.
hse Could you please file a bug in our tracker https://youtrack.jetbrains.com/issues/IDEA and specify exact IDE, OS versions? Thanks.
Thanks for all the replies