This part always confuses me ... so this is kind of a guess. I think the
"send ...*in 0 ticks*" means that the message is queued for delivery, so
the repeat loop finishes, then the lockMoves gets set false, then
mouseUp finishes, and *then* your messages get delivered, one after another.
Try just doing
send "ElementMove"&& value(tObjecte)& comma& value(tPosicio) to me
instead of
send "ElementMove"&& value(tObjecte)& comma& value(tPosicio) to me in
0 ticks
-- Alex.
On 21/01/2011 11:04, JosepM wrote:
Hi,
I'm trying to move some buttons all at the same time but I can't...
Only I get to move one after one.
on mouseUp
set itemdel to tab
set the lockMoves to true
repeat for each line tLinea in fld "f_punts"
put item 2 of tLinea into tObjecte
put value(item 1 of tLinea) into tPosicio
send "ElementMove"&& value(tObjecte)& comma& value(tPosicio) to me
in 0 ticks
end repeat
set the lockMoves to false
end mouseUp
on ElementMove pObject, pLocationX, pLocationY
move button pObject of stack "s_tactiques_futbol" to
pLocationX,pLocationY
end ElementMove
Salut,
Josep
_______________________________________________
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode