Can somebody please explain to me why this works:
[java]
<!-- the start button -->
<panel id=“start_button” height=“50%” width=“50%” valign=“center” childLayout=“center”>
<control name=“button” label=“Start” id=“StartButton” align=“center” valign=“center”
visibleToMouse=“true”>
<interact onClick=“start(hud)” />
</control>
</panel>
[/java]
and yet this doesn’t:
[java]
<panel id=“main_pause” valign=“center” align=“center” height=“100%” width=“100%” childLayout=“center” backgroundColor="#000000ee">
<control name=“button” label=“Resume” id=“ResumeButton” align=“center” valign=“center”
visibleToMouse=“true”>
<interact onClick=“resumeGame()” />
</control>
</panel>
[/java]
What does ‘does not work’ mean exactly?
Sorry for not being clear. It means that the start button works like it should, it shows up, and you can click on it. The resume button shows up, but you can’t click on it. Unless the cursor starts off on the button when flycam is disabled, then all you have to do is move the mouse, and it activates the resume button…
Hi,
Does this http://hub.jmonkeyengine.org/groups/gui/forum/topic/buttons-behave-oddly/ describe your issue? I’ve got a similar problem and its currently (hopefully) being resolved.
Watch the demonstration video… it sounds quite close to your problem.
Lachlan
I’m on a really slow internet connection, I’m waiting for the video to load, but looking at your post, it looks exactly the same with the exception that even double clicking (or any amount of back-to-back clicking) won’t activate the button.
Dunno if it’s my laptop, or my OS, or my internet, etc. But I can’t view the video for some reason.
Oh. You can’t grab the test case? (except that’s probably just as big)
I’m quite new to jME, and I’m not sure what I can do to help fix this bug - not exactly sure where to ask… but it seems it can’t be fixed right now. I’m fine living with it for the moment, but its obviously not optimal.
To Moderators:
Is this then a duplicate? Is anything done to duplicate bug posts?
Lachlan
Posts just fall off the boards when no longer used, its not like its a double post (which would get locked).
Issue 520 has been accepted at priority critical so I’d imagine it will get worked on reasonably fast…
I’m sorry for the semi-duplicate post (I say that, because I can’t click on the button any number of times and get it to work.) I didn’t realize that lachlanap was having virtually the same problem as me.
I just read the bug report, and I may have found an exact problem not covered inside the report, or maybe the issue isn’t what you think, but tell me if I’m wrong. I created a simple game, with a start, hud, and pause screen.
However, even when I keep the mouse cursor visible the entire time, even during the non-paused game, the buttons in the pause screen are still broken, so it wouldn’t make sense that the problem would be with the mouse being disabled then re-enabled.
I’ve seen weird behaviors too but since I’ve changed how the interaction works I don’t see that as much, or at all. For testing purpose, try using this instead. It might work. Or not. But worth a try:
[xml]
<interact onRelease=“method()” />
[/xml]
It doesn’t seem to work for me…
Well, it was worth a try. Sadly I have nothing else to offer. I’m sure someone else will jump in.
That’s fine, I’ve gotten it to work with keyboard until its fixed.