Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

reboot confirmation dialog losing focus in front of xchat #23

Closed
Code7R opened this issue Mar 13, 2015 · 8 comments
Closed

reboot confirmation dialog losing focus in front of xchat #23

Code7R opened this issue Mar 13, 2015 · 8 comments
Labels
bug The issue exposes a bug.
Milestone

Comments

@Code7R
Copy link
Collaborator

Code7R commented Mar 13, 2015

I have a little glitch to report. Repro steps:

X-Chat must be the only window on the current workspace. Press Ctrl-Alt-Del and click reboot or use the hotkey. The confirmation window appears on top of xchat but it does NOT gain the focus.

I am not an expert WRT icewm's window handling, do you know someone more appropriate to care about this issue? Smells like some kind of concurency issue but it's only a wild guess.

@bbidulock
Copy link
Owner

It might be a little related to the java hack thing. I noticed that the code does not really appear to conform to ICCCM 2.0 behaviour for focus handling, particularly when WM_TAKE_FOCUS is specified (as it is in both cases). xchat is using gtk2 on my box, so I can't really think that xchat has a problem. What is your focus-new-windows setting?

@Code7R
Copy link
Collaborator Author

Code7R commented Mar 15, 2015

Nope, sorry. Disabling Java hack didn't change anything. I use default focus behavior (Click to focus).

I also see similar behaviour with the Eclipse startup dailog (Workspace selection), it does never get focus when created. Another funny effect is that when I start eclipse from the Taskbar command line, I get a fake "Task Bar" entry in the quick-switch list, which disappears the next time when Alt-Tab is pressed.

@bbidulock
Copy link
Owner

I'm a sloppy focus guy. I didn't mean that the java hack would fix anything. It seems that the need for the java hack in the first place was some non-conformance in IceWM to ICCCM 2.0 on the basis of focus behavior. So, can you not click in the confirmation window to have it take focus?

@bbidulock
Copy link
Owner

XChat is stealing focus. The confirmation dialog should likely grab both the keyboard and the pointer when presented so that no other window can simply steal its focus. Eclipse is a different issue.

@gijsbers
Copy link
Collaborator

gijsbers commented Oct 5, 2017

@bbidulock How can i understand the non-conformance you mentioned? I'm chasing a focus bug and I wonder if i'm onto the same thing, but i also need to know how i can verify if my solution is correct. The case is that sometimes no application window has input focus, even though it should. Then Alt+Tab shows the focus is with the taskbar, which in my view is incorrect as focus never needs to be set to the taskbar. This is for sloppy focus. I tracked it down to YFrameWindow::getInputFocusHint(). If we trace the history of this function then commit 5b844af introduces this function and it looks fine. Then commit 8d10c68 still makes sense to me. But then commit d3b00cc reverses this with the comment "JDK7 focus fix". That commit says that if InputHint is False and WM_TAKE_FOCUS is absent then input is true. Now the flow in YFrameWindow::avoidFocus() no longer makes sense either. So in my view we should revert commit d3b00cc to get back on the right track. If I do that then I can fix the taskbar-has-focus bug easily and always have correct sloppy focus. Comments?

gijsbers added a commit that referenced this issue Oct 8, 2017
gijsbers added a commit that referenced this issue Oct 8, 2017
as focus must reside with applications. See issue #23.
@bbidulock
Copy link
Owner

Wrong solution to this problem. The dialogs at issue should grab the pointer and the keyboard.

bbidulock added a commit that referenced this issue Oct 10, 2017
…s IceWM focus behavior non-conformant. See issue #23."

This reverts commit dad0795.
@bbidulock bbidulock added the bug The issue exposes a bug. label Oct 10, 2017
@bbidulock
Copy link
Owner

I can't get the logout confirmation dialog to lose focus in front of xchat now. Please recheck and close if fixed.

@bbidulock bbidulock added this to the 1.4.3 milestone Oct 19, 2017
@bbidulock
Copy link
Owner

@Code7R does this work now? Plesae reopen if it doesn't.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug The issue exposes a bug.
Projects
None yet
Development

No branches or pull requests

3 participants