Jump to content

Multiple visible ObjectGui click not received


photo

Recommended Posts

Hi,

when multiple ObjectGui Objects are visible in my viewport the click event will not be executed anymore or very sporadic when I click on a widget which has a callback function.

When only one ObjectGui is visible it works fine. Is this a bug or did I miss something.

Thank you for your help.

Sebastian

Link to comment

Hi silent

we are using this version at the moment:

Version: 2.6.1 ver-2.6-cef3c5e Dec 21 2017

We are trying to implement a selection by label.

I put a little example in the attachement.

While both ObjectGui objects are visible, only one gets subsequent click events on the label, the other takes only one and then stops. Only after clicking on the other label again it is clickable again for only one time.

This effect gets worser with more ObjectGuis receiving no click events at all, even when they don't overlap.

When only one ObjectGui is visible in the viewport it works as expected most of the time.

Thanks Sebastian

 

appworldlogic.zip

selection.PNG

Link to comment

Hello Sebastian,

This behaviour looks like engine's bug to me right now. That's workaround for it I found:

void AppWorldLogic::click()
{
	static int i = 0;
	std::cout << "Clicked " << ++i << std::endl;
	gui2->getGui()->removeFocus(); // removing focus from gui to continue recieve clicks
}

 

Link to comment

Hi andrey-kozlov,

with the workarround it is better but sometimes I have to click twice and one is still not clickable when they overlap.

Is this going to be fixed?

Link to comment
  • 1 year later...
On 6/21/2018 at 8:33 AM, silent said:

Sebastian,

We will take a look at this issue more closely before the 2.8 SDK update. Right now there is no other workaround available, I'm afraid.

Hello silent,

 

did you have time to take a closer look to investigate it further?

We still have issues with mutiple ObjectGuis in the newest version 2.11 and 2.8.

We know there is not always time to resolve problems as soon as possible, but we would like to know if you are able to provide us a bugfix until end of may 2020.

We also discovered another issue when using render_border, the hardware mouse cursor is not matching the ObjectGui cursor.

We can workarround this by disabling the render_border, the click events have more priority for us.

I put a reproducer in the attachment.

2020-04-24 13-18-14_edit.mkv

I do have another question, we tested the horiziontal box widget for click events. but it is not working. Is there any way to overlay or increase label widgets with a bigger hitbox?

 

Thank you very much

source.zip

Link to comment
×
×
  • Create New...