This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Bug is transferred from BugTraq: http://developer.java.sun.com/developer/bugParade/bugs/ 4865129.html ------------------------------------------------------------------- Description: jdk 1.4.1_02 & 1.4.2, S1S5 rc 1, 2, 3 builds Using Redhat Linux 7.2 with gnome desktop environment version 1.4, the foucs does not go to the newly popup New Wizard window. Instead, the focus is on the Explorer window. This happens on the SDI mode only which caused 50+% of the 600 a11y automated testcases to fail. Repro steps: 1. make sure the IDE is in SDI mode and the desktop environment is set to "click on window to make focus" mode 2. put your focus on the Explorer window 3. press Control-N to bring up the New Wizard window ===>>> At this point, the focus should be on the New Wizard window but it's still at the Explorer window. Another one is when the ide first came up, the registration window also came up and displayed on top but the focus is on the Explorer window. Using the mouse can also reproduce this problem. 1. make sure the IDE is in SDI mode and the desktop environment is set to "click on window to make focus" mode 2. right-click on a filesystem and select the following from the popup menu New->All Tempaltes or right-click on the "Filesystems" and select Mount->Local Directory or select anything to popup a window from the Explorer window will have this same effect. ===>>> the New Wizard window comes up but the focus is still on the Explorer window. A comment.
It works fine with KDE 2.1.1, RH 7.1. (JDK 1.4.1_02, JDK 1.4.2_b22). Peter please check with Gnome.
reason why this is P1? Please don't abuse priotity. Anyway, this bug is INVALID. Whether the newly displayed dialog/window gets the keyboard focus or not is a property of the window manager. Applications incl. java/awt ones cannot influence it. Your window manager may have a setting for it. Please also verify how the behaviour you desires works in other java apps. Furthermore GNOME is a desktop enviroment, not a window manager. Please look in GNOME Control Center (gnomecc) to see which one is in use. I use sawfish and it does not work by default, I have to tweak the settings.
Trung: please note that Gnome 1.4 is supported desktop environment for S1S 5. Specific window manager details need to be provided and alternative managers/settings investigated. On the other hand, SDI is not the default windowing mode for NB 3.5/S1S 5 and the same action works fine in MDI. Thus, a viable workaround exists.
I was playing with gnome/sawfish a bit. And it seems it is not possible to tweak sawfish to solve this issue. The problem is, that the dialog which is shown (wizard) has as its parent the main window, not explorer one (it has some reasons in NB to have it implemented this way). Sawfish has a setting when dialogs should inherit focus from its parent window, but this doesn't help now (in our case main window doesn't have a focus, but explorer - there fore it works in MDI -> exporer is in main window). I will check whether there are some focus requests from NB code.
> Trung: please note that Gnome 1.4 is supported desktop > environment for S1S 5. sure. The problem came up on mailing lists many times in the past. This is the limitation of java/windowing toolkit environment. The best we can do is to document it. BTW "Gnome 1.4 is a supported desktop environment" is a fuzzy statement. What's important is the window manager, not GNOME or KDE. KDE allows only one window manager (AFAIK) but there is no such a limitation w/ GNOME. Imagine the users who love the acient twm and demands us to make our IDE work w/ it!
> I was playing with gnome/sawfish a bit. And it seems it is not > possible to tweak sawfish to solve this issue. it's not usual setting, you must use lisp code to customize sawfish. I posted such a code to nbusers a year or two ago. > I will check whether there are some focus requests from NB code. you don't have to. I think I know where the problem is. In X window there is two concepts: switching focus to a window and fronting it. These are independent. In java you have only one, the latter. In KDE fronting implies getting focus, but not in sawfish and many other WMs. (Yes, SDI is not supportable, you can't make it work).
Yes, the problem occurs on the S1S5 supported platform (Redhat Linux 7.2 with gnome v1.4 desktop environment but I don't if this occurs on other versions of RH linux using the other versions of gnome desktop. I believe this is from the window manager instead of gnome desktop. From the Sawfish window manager's Focus Behavior dialog box, here's what I got for the setting. "click" - When does the mouse pointer to get focus affect the input focus x Focus on application windows when they first appear x Dialog windows inherit the focus from their parent x Raise windows when they are focused 0 - Delay in milliseconds until focused windows are raised I am also testing on Solaris 9 on sparc system with Gnome v2.0 desktop as well but this problem does not occur there.
*** Issue 33850 has been marked as a duplicate of this issue. ***
A CLOSED issue mistakenly moved into the NEW state... closing again...