For all my previous projects I used JFrames
in which most of the new tasks are opened on new JFrames
on top of a main JFrame
. But for my next project the customer requested new windows to be opened inside the JFrame
( he was referring to JInternalFrame
).
What I want to know is is there any drawbacks when using JInternalFrame
? as Sun specifies it's a LightWeight Component
when compared to JFrame
.
as Sun specifies it's a LightWeight Component when compared to JFrame.
A JFrame is basically a lightweight component as well. The border and title is an OS related object and you can't change the behaviour of any of those features. However, all Swing components are added to the content pane of the frame which is a JPanel.
A JInternalFrame also uses a JPanel as a content pane, so, any Swing component that you can add to a JFrame you can add to a JInternalFrame.