6 Replies - 3580 Views - Last Post: 14 September 2009 - 07:36 PM Rate Topic: -----

#1 Tanira  Icon User is offline

  • D.I.C Head

Reputation: 10
  • View blog
  • Posts: 102
  • Joined: 30-May 09

JInternalFrame JDesktopPane issue

Posted 13 September 2009 - 01:04 PM

The internal frames can go beyond the desktoppane's bounds. Is there an easy way to solve this? Or do I need to use listeners?
Is This A Good Question/Topic? 0
  • +

Replies To: JInternalFrame JDesktopPane issue

#2 markhazlett9  Icon User is offline

  • Coding is a lifestyle
  • member icon

Reputation: 60
  • View blog
  • Posts: 1,666
  • Joined: 12-July 08

Re: JInternalFrame JDesktopPane issue

Posted 13 September 2009 - 01:08 PM

Can you please explain your issue a little further. And it would be good if we could see some code to go off of...

Cheers
Was This Post Helpful? 0
  • +
  • -

#3 Tanira  Icon User is offline

  • D.I.C Head

Reputation: 10
  • View blog
  • Posts: 102
  • Joined: 30-May 09

Re: JInternalFrame JDesktopPane issue

Posted 13 September 2009 - 01:17 PM

View Postmarkhazlett9, on 13 Sep, 2009 - 12:08 PM, said:

Can you please explain your issue a little further. And it would be good if we could see some code to go off of...

Cheers


o.o I have a JdesktopPane and a jinternalframe inside of it. I don't like the fact that the user can drag the jinternalframe off of the screen.


JFrame main = new JFrame();

JDesktopPane desktop = new JDestopPane();

JInternalFrame first = new JInternalFrame();

main.setContentPane(desktop);
desktop.add(first);



Was This Post Helpful? 0
  • +
  • -

#4 pbl  Icon User is offline

  • There is nothing you can't do with a JTable
  • member icon

Reputation: 8347
  • View blog
  • Posts: 31,913
  • Joined: 06-March 08

Re: JInternalFrame JDesktopPane issue

Posted 13 September 2009 - 04:46 PM

They are named "InternalFrame" where do you think the "Internal" keyword means ?
Was This Post Helpful? 0
  • +
  • -

#5 Tanira  Icon User is offline

  • D.I.C Head

Reputation: 10
  • View blog
  • Posts: 102
  • Joined: 30-May 09

Re: JInternalFrame JDesktopPane issue

Posted 13 September 2009 - 09:24 PM

View Postpbl, on 13 Sep, 2009 - 03:46 PM, said:

They are named "InternalFrame" where do you think the "Internal" keyword means ?


Internal means it turns the Frame into a layered frame of sorts. Then you place the internalframes inside. It's not that unreasonable to want to make the frames impossible to drag out of view. If I have the destopPane open and internalframes inside it, I don't want the user dragging them into difficult to find spots.
Was This Post Helpful? 0
  • +
  • -

#6 pbl  Icon User is offline

  • There is nothing you can't do with a JTable
  • member icon

Reputation: 8347
  • View blog
  • Posts: 31,913
  • Joined: 06-March 08

Re: JInternalFrame JDesktopPane issue

Posted 14 September 2009 - 04:12 PM

If there is a way to do it it will be with the putClientProperty() method of the JDesktopPanel
now which property ?
This is very badly documented
I have tried in the past to find a list of these properties but the only way is to look at the code
Was This Post Helpful? 0
  • +
  • -

#7 pbl  Icon User is offline

  • There is nothing you can't do with a JTable
  • member icon

Reputation: 8347
  • View blog
  • Posts: 31,913
  • Joined: 06-March 08

Re: JInternalFrame JDesktopPane issue

Posted 14 September 2009 - 07:36 PM

Hey!!!!

Forum is quite tonigh

Just tried it... I CANNOT drag the InternalFrame outside of the DesktopPane

so what is your problem ?

Post your whole code... you are changing the default behaviour somewhere
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1