Relayering and dragging a group within a group

Jonathan Lynch jonathandlynch at gmail.com
Mon Jun 5 10:44:36 EDT 2006


relayer a group that is within another group is rather tricky...

It can be done, and I can send you a stack that does it if you want. What I
have done is this -
1)set the relayergroupedcontrols property to true
2)move all the subgroups to the bottom of the master group - this has to be
done in the correct order, so that when this process is finished the target
group has moved up or down a layer as desired
3)set the relayergroupedcontrols property back to false

This is, in my experience, the best way to do it. If you just directly
change the layer of the subgroup, it will wind up being moved inside another
subgroup, and will seem to dissappear.

On 6/4/06, David Epstein <dfepstein at comcast.net> wrote:
>
> When the mouse is pressed on a button, I want the group that it is
> part of to come to the front and be draggable to a different
> location.  There are several such groups, and all are parts of a
> higher-level group called "wb."
>
> The group "wb" has the following script:
>
> on mouseDown
>   if "button" is in the target then
>
>     -- (1) put the group this button belongs to on top of other
>     -- groups that are subgroups of group "wb":
>     put the short id of the owner of the target into tgid
>     start editing group "wb"
>     set the layer of group id tgid to top
>     stop editing
>
>     -- (2) move this group with the mouse until the mouse is released:
>     grab group id tgid of group "wb"
>   end if
> end mouseDown
>
> Part (2) does not work (using Metacard 2.5 on Mac OSX 10.4).  If I
> comment out part (1), part (2) works as expected.  Can anyone see an
> error or suggest a remedy?
>
> Many thanks.
>
> David Epstein
> _______________________________________________
> use-revolution mailing list
> use-revolution at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-revolution
>



More information about the use-livecode mailing list