Skip to main content

Heavyweight/Lightweight Mixing feature of Java 7

10 replies [Last post]
darwinjob
Offline
Joined: 2004-11-16

Hi
There is a bug which was recently closed:
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4154448

The evaluation parts says:
"Having the Heavyweight/Lightweight Mixing feature implemented, we don't actually need any heavyweight JInternalFrame. At least the problems mentioned in the Description of this CR are succesfully resolved with the fix for 4811096 at JDK7. Hence, this CR is closed as 'Will Not Fix'."

Sounds like the bug is fixed in Java 7. I downloaded and tested latest snapshot jre-7-ea-bin-b16-windows-i586-20_jul_2007.jar but I could not notice any difference in (JInternalFrame + Canvas3D) or even (JInternalFrame + Button) behavior.

Where can I get more information about Heavyweight/Lightweight Mixing feature of Java 7?

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
emzic
Offline
Joined: 2006-04-21

great to see, that we can finally put a heavyweight in a JInternalFrame!

does anyone know details about the bugfix and if it required changes in native code? i am asking, because i intend to backport it to java6.

thanks!

anthony_p
Offline
Joined: 2006-07-24

Possibly this CR:

http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6682046
(Mixing code does not always recalculate shapes correctly when resizing components)

could solve a number of issues. It's not yet integrated though, the work is currently in progress.

interactivemesh
Offline
Joined: 2006-06-07

Hi,

here are some test results of my MDI application under [b]JDK/JRE 1.7.0_b28[/b]:

- repainting of several overlapping JInternalFrames works fine now

- JInternalFrame's outline is still hidden in outline dragging mode (can this be solved at all?)
- repainting or resizing doesn't work well when a JInternalFrame's width and/or height are increased, the former dimension is kept

New screenshots are available here: http://www.interactivemesh.org/off/heavylightweighttest.html

August

trembovetski
Offline
Joined: 2003-12-31

Thanks for the report. I suggest that you file a bug against AWT.

Dmitri

interactivemesh
Offline
Joined: 2006-06-07

Hi,

suprised by this news I reactivated an older MDI application based on JDesktopPane, JInternalFrame and Canvas3D of Java3D. I compiled and ran it under JDK/JRE 1.7.0_b19:

- Z-order of JInternalFrame and Canvas3D works fine
- Java3D rendering has Similar/same performance compared to JRE 1.6
- When a non selected JInternalFrame is selected the background is shown for a few milliseconds before its Canvas3D is rendered
- JInternalFrames which were moved back are often not fully repainted
- In outline dragging mode the JInternalFrame's outline is hidden by its own Canvas3D and those of other JInternalFrames

Screenshots are available here: http://www.interactivemesh.org/off/heavylightweighttest.html

August

anthony_p
Offline
Joined: 2006-07-24

Hey,

It really got fixed, though not integrated yet. I think that it will be integrated into the b19 of JDK7. Please wait until then. Thanks for the patience!

--
best regards,
Anthony

darwinjob
Offline
Joined: 2004-11-16

Thanks for the fast reply.

Could you please answer yet another little question? :)

Does the feature work "right out of the box" or should I play with z order (if yes - how?) ?

Best regards
D

anthony_p
Offline
Joined: 2006-07-24

Exactly right out of the box!

The limitations? Well, a very small number. Just the transparent (setOpaque(false)) LW components do not behave very correctly. All the rest works just fine.

--
best regards,
Anthony

darwinjob
Offline
Joined: 2004-11-16

That is the miracle! :)

I'll be waiting for the b19.

Thank you.

D

darwinjob
Offline
Joined: 2004-11-16

Just tested b19 with java3d 1.5.1 Canvas3d inside JInternalFrame.
[b]IT WORKS!!![/b]