You are not logged in.

#1 2010-10-06 23:22:01

ltpl4y3r
Member
Registered: 2008-08-23
Posts: 28

Minecraft won't retain focus on click, Openbox to blame

I have been attempting to play minecraft in chrome and firefox (just the classic version). I found that I could walk around just fine, but when I tried to click to place blocks or destroy them, that I would lose focus on the game and the pause screen would come up. After a visit to #MinecraftHelp, I tried a different window manager. I only have twm installed as a backup, but I rebooted X.org with twm and it worked... perfectly.

So, it seems as though there is something going on with openbox that makes me lose focus when I click. I <3 openbox and don't wish to switch, but I would really like to try to find a way to play in the browser, without having to restart X.

Any ideas?

Offline

#2 2010-10-07 10:51:49

R00KIE
Forum Fellow
From: Between a computer and a chair
Registered: 2008-09-14
Posts: 4,734

Re: Minecraft won't retain focus on click, Openbox to blame

You can try using xnest which may work ok ... ish or you can start a new X session just to play minecraft, there is no need to kill your "normal" X session.


R00KIE
Tm90aGluZyB0byBzZWUgaGVyZSwgbW92ZSBhbG9uZy4K

Offline

#3 2010-10-19 20:30:37

ltpl4y3r
Member
Registered: 2008-08-23
Posts: 28

Re: Minecraft won't retain focus on click, Openbox to blame

Just thought I would drop an update. I tried xnest, and it gave me fits about aiglx or something, so I tried pekwm. I had the same issue with pekwm, so I tried the Virtual X session with twm. This is working, but still isn't ideal. It would be great to have a window to play it in, but since I am not ready for a big change in window manager, I think I will stick with this method. Thanks R00KIE!

Offline

#4 2010-10-21 19:54:20

ltpl4y3r
Member
Registered: 2008-08-23
Posts: 28

Re: Minecraft won't retain focus on click, Openbox to blame

A list of window managers that have yet to work.

  • Openbox

  • PekWM

  • Awesome

A list of window managers that work:

  • twm


This is annoying...

Offline

#5 2010-10-25 02:48:19

quantumphaze
Member
From: Melbourne, Australia
Registered: 2008-11-14
Posts: 175

Re: Minecraft won't retain focus on click, Openbox to blame

Isn't there a way to swap out your window manager at runtime? You can do it with the full desktop environments (I have often swapped out KWin with Openbox for games back when it was really unstable) and all your current windows will still be there (though maximized ones will no longer be maximized and everything is slapped onto desktop 1). I don't know if it would work when the WM is the only thing running that lets you launch stuff and leave you with an unusable X session where you can't click or type. Try a $YourTestingWM --replace and see what happens.


▁▂▃▄▅▆▇█▉▊▋▌▍▎▏▏▎▍▌▋▊▉█▇▆▅▄▃▂▁

Offline

#6 2010-10-29 18:00:13

minasmorath
Member
From: USA
Registered: 2009-11-24
Posts: 52
Website

Re: Minecraft won't retain focus on click, Openbox to blame

I have the same problem, and yes it is Openbox and the way it interacts with Java. There is a simple fix though (swapping window managers on the fly... ugh).

To fix it, I just installed metacity. Now  I open minecraft in firefox and a terminal in the background, and run 'metacity --replace &', which replaces Openbox (and 'fixes' the problem). I leave that terminal open in the background so that when I'm done playing, I can alt-tab over to it and run 'openbox --replace &'. Clean and simple.

Hope that helps someone.

(I stumbled on this thread via google, didn't think to check the forums for my problem first, but I will next time)

Offline

#7 2011-01-13 21:43:22

Skyalmian
Member
Registered: 2009-06-28
Posts: 121

Re: Minecraft won't retain focus on click, Openbox to blame

Ah, this thread in full explains the issue...
No solution at present.
I wonder if there's an Openbox + java focus bug filed... "Java" as keyword turns up nothing on Icculus, so...filed.
I wonder if one can "CC" e-mail addresses at whim, not just for those who have an account in the Bugzilla database... With permission, I'd add anyone in this thread who wants to be CC'd when a change is made to the bug. smile

Last edited by Skyalmian (2011-01-14 00:24:01)

Offline

#8 2011-08-31 21:12:55

Skyalmian
Member
Registered: 2009-06-28
Posts: 121

Re: Minecraft won't retain focus on click, Openbox to blame

Comment 1: Dana Jansens 2011-08-31 13:42:14 EDT wrote:

The way to "fix" this is to stop grabbing the mouse on the client window. Which means that you can't have any client context mouse bindings.

Metacity works because they hard code their mouse behaviour.

The other way to fix this is to have Java not ignore the mouse clicks that we forward to them.  Of course this works for every other application except java applets.

One possible workaround (this is a lot of work around just for broken java applets) would be to have 2 mouse contexts for clients.  One for active clients and one for inactive clients.

What you think Mika?

Offline

Board footer

Powered by FluxBB