• 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
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Order Of JInternalFrame

 
Ranch Hand
Posts: 100
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Guys,

I got a problem which i need suggestion to slove it.

this problem is like this, i have a JDesktopPane and Have a few menu on the MenuBar. When i click of new Frame on the menu Bar the program will create a new JInternalFrame. So each time i create a new JInternalFrame the New frame is always behind the old frame!!

I would like to ask for suggestion to overcome this problem all suggestion is well come thanks in advance
 
Sheriff
Posts: 11343
Mac Safari Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I don't know whether this would work, but have you tried setSelected(true)?
 
marc weber
Sheriff
Posts: 11343
Mac Safari Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Forget my previous suggestion of setSelected(true). It doesn't seem to do what I expected.

You can use setLocation(int, int) to position the JInternalFrames so that one is not directly on top of the other, and/or...

Use moveToFront() or moveToBack() after you've added the JInternalFrame to the JDesktopPane.
 
Koh Khai Huat
Ranch Hand
Posts: 100
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks that really slove my problem

thanks for everything.

regards
 
marc weber
Sheriff
Posts: 11343
Mac Safari Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It seems odd that there isn't a method in JDesktopPane to "cascade" or "tile" JInternalFrames...

:roll:
 
Whatever you say buddy! And I believe this tiny ad too:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic