Search code examples
javaswingjframejdesktoppane

How to put JDesktopPane in background in JFrame


i'm developing a java application in which i have a JFrame with a JDesktopPane in full screen size. My problem is that JDesktopPane cover the JButton(s) inside the JFrame so i can't click on JButton(s). I add JDesktopPane to my JFrame in this way:

jDesktopPane1 = new JDesktopPane();
jDesktopPane1.setSize(Toolkit.getDefaultToolkit().getScreenSize());
jDesktopPane1.setOpaque(false);

How can i disable JDesktopPane when i don't need to use it?


Solution

  • I think that you have to check

    1. Full-Screen Exclusive Mode API

    2. How to Create Translucent and Shaped Windows