Greetings everyone,
I'm having with groups that I think I can do an ugly workaround but .. I would prefer do do it the proper way.
I have a group. Inside the group I have several graphics, controls, etc... however, they do not fill the group completely. this means that some areas inside the group are "empty"
if I click on one of the components inside the group, the on mouseDown handler from the group is triggered.
However, if I click on an empty are inside the group, the on mouseDown of the group is not triggered.
I also noticed that while in design/edit view, if click on an empty area inside the group, instead of selecting the group, the interface selects the stack.
so my question is, what can I do in order to trigger the on mouseDown handler when I click anywhere inside the group (be it an empty area or an area with a control) ??
Note: Don't know if it's important or not,but my group background has a specific colour.
Many thanks in advance
- Miguel
Groups - mouseDown on empty area
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller
Re: Groups - mouseDown on empty area
Hola Miguel,
not sure if this is correct beahvior, but anyway, that's the way LC works currently.
I ususally add a simple opaque graphic to the group (lowest layer), so there finally
IS something that can catch the mouse events
Best
Klaus
not sure if this is correct beahvior, but anyway, that's the way LC works currently.
I ususally add a simple opaque graphic to the group (lowest layer), so there finally
IS something that can catch the mouse events

Best
Klaus
Re: Groups - mouseDown on empty area
Hi.
What Klaus said.
Or you can place a mouseDown handler in the card script, and check to see if the clickLoc is within the rect of the group.
Craig Newman
What Klaus said.
Or you can place a mouseDown handler in the card script, and check to see if the clickLoc is within the rect of the group.
Code: Select all
on mouseDown
if the clickLoc is within the rect of group "yourgroup" then doStuff
end mouseDown