Reset Locals?

Scott Rossi scott at tactilemedia.com
Thu Jul 6 00:42:14 EDT 2006


Recently, Trevor DeVore wrote:

> script locals are only preserved across script compilation if you
> 
> set the preserveVariables to true
> 
> Otherwise 2.7 behaves as previous engines.

Thanks, but this doesn't seem to be the case here (OSX 10.3.9, Rev 2.7.2).

New stack/button script:

local myCheck
on mouseUp
  if myCheck = "" then
    put 5 into myCheck
  else put 2 into myCheck
  answer myCheck
end mouseUp

After the first "check", the value of myCheck is consistently 2, even when
the script is edited.  Rev says the preserveVariables is false.

In previous versions (for me), any time the script is edited, the local is
reset.  I just checked with 2.6.1 and this is the case.

The only two reasons I can think of why this might be are 1) it's an OSX
10.3.9 thing (as opposed to 10.4), or it's something the Rev guys are fixing
for 2.7.3. ???

(Also, why is the answer dialog so slow to appear in Rev 2.7?  2.6 is way
faster.)

Regards,

Scott Rossi
Creative Director
Tactile Media, Multimedia & Design
-----
E: scott at tactilemedia.com
W: http://www.tactilemedia.com





More information about the use-livecode mailing list