From: Robert Carlin <jythoneer@ho...> - 2003-09-08 06:47:02
Java does support such a property, to handle your performance problem.
I'm using Sun's Java SDK 1.4.1, but the documentation indicates support at
least back to 1.3.1 for this technique.
Simply call the setDragMode(int dragMode) method from your JDesktopPane
instance like this:
desktop = javax.swing.JDesktopPane()
# or use the property directly,
# desktop.dragMode = javax.swing.JDesktopPane.OUTLINE_DRAG_MODE
The other value (which it defaults to) is
javax.swing.JDesktopPane.LIVE_DRAG_MODE, which definitely impacts
performance as it repaints the JInternalFrame constantly when dragged.
See also the Swing Documentation, under JDesktopPane.
>From: "Jon Franz" <jfranz@...>
>Subject: [Jython-users] Swing question
>Date: Sun, 7 Sep 2003 19:35:07 -0400
>I'm using JDesktopPanes and JInternalFrames in my application,
>and I've noticed that dragging the JInternalFrames uses a lot of
>CPU time. Is there a way to turn off the re-drawing of a JInternalFrame's
>contents while it is being dragged? This would be the equivilent of
>the 'show window contents while dragging' option on windows machines,
>I've dug and dug, but my googling seems to turn up no examples or how-tos.
>This sf.net email is sponsored by:ThinkGeek
>Welcome to geek heaven.
>Jython-users mailing list
Need more e-mail storage? Get 10MB with Hotmail Extra Storage.
Get latest updates about Open Source Projects, Conferences and News.