Open sillysloft opened 19 years ago
A Java program that demonstrates the problem
Original comment by: drepasky
Original comment by: fluxgen
Original comment by: fluxgen
Logged In: YES user_id=296419
Fixed in svn (revision 3969). The problem was that the transients were created before the transient for window. This was solved with a "waiting" list.
Original comment by: fluxgen
Java JDialogs behave inconsistently depending upon whether they are displayed before or after the JFrame that owns them. JDialogs that are displayed before their owing JFrames are installed can be brought in front of other JDialogs using the toFront method of JDialog, and they can be made resizable using the method setResizable(true). Neither the toFront method nor the setResizable(true) method work for JDialogs that are displayed after the JFrame that owns them is displayed.
I assume that this is a problem with the window manager because it is present only for some window managers. JDialogs behave as they should on KDE, Gnome Xfce, and MS Windows (not an X window manager). They behave as I have described on fluxbox and on Mac OS X (also not an X window manager). And on Linux, the problem occurs independently of whether I use a blackdown jvm or a Sun jvm.
The problem can be demonstrated using the attached code. Briefly, the code creates 5 dialogs that are displayed in the same place on the screen, and it provides a menu that can be used to bring dialogs to the top of the stack. Dialogs A and B work as they should. That is, they can be brought to the front of the others by selecting the appropriate menu item, and they are resizable. (They are displayed before the owning JFrame is displayed.) Dialogs C, D, and E, are displayed after the owning frame is installed, and they behave incorrectly: they cannot be brought to the fornt and are not resizable.
I realize that you may not be familiar with Java. I posted this to the Blackdown java mailing list several days ago and asked for insights that might help an X developer locate the problem. No one replied.
I'll gladly run tests if that helps.
Thanks,
Dick
Reported by: drepasky