• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

panel and frame (Swing)

 
Ranch Hand
Posts: 32
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi
I am using a frame. The frame has a panel in its center. When I click a button in the toolbar in the frame, an internal frame is added to the center of this frame.Suppose after adding this internal frame to the frame, I display another dialog or frame and close this. What happens is that, instead of displaying this internal frame, this panel is shown first and only after sometime the internal frame is displayed.
Plese give a solution
Thanks
Elizabeth.
 
Ranch Hand
Posts: 1492
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Elizabeth,
I am not exactly sure what you are doing. But a frame, by default, uses a BorderLayout manager. A BorderLayout only supports a single component in each of its sections. In your discussion you mentioned that you are placing 2 components into the Center (Panel and JInternalFrame). Since you can only have one, maybe you had better remove the Panel when you add the JInternalFrame.
NOTE: JInternalFrame is really designed for JDesktopPane to allow for overlapping components, etc.
Regards,
Manfred.
 
when your children are suffering from your punishment, tell your them it will help them write good poetry when they are older. Like this tiny ad:
Smokeless wood heat with a rocket mass heater
https://woodheat.net
reply
    Bookmark Topic Watch Topic
  • New Topic