Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

JWindow problem

 
Stewart Griffin
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Does anyone know how to keep a JWindow on top of the screen?
If I click any part of the screen the JWindow stays on top.
But if I click on any part of the JWindow, it disappears under the main JFrame, eventhough I dont implement any of the listeners.
Here's my code

Any ideas ppl?
 
Stewart Griffin
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Its ok,
I realised where the prob is.
I forgot to add the action listeners to the window.
I just added them in the class constructor.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic