I have an issue with JPanels. I have two layers of JPanel. The first layer is JPanel with image and second layer show JComponents. It looks like this:
JFrame
- JPanel1 (Image)
- JPanel2 (JComponents)
When I have more than one component on JPanel2
, then JPanel2
is not transparent but it has a grey background and I don't see JPanel1(image)
under it. How to set JPanel2
as glass pane when his parent is JPanel1
?