Get a handler from a script
David Burgun
dburgun at dsl.pipex.com
Wed Mar 22 06:53:23 EST 2006
Hi,
Nice Script!
There is just one thing I don't understand?
What are the:
get "/*" & i
Statements for?????
Thanks a lot
All the Best
Dave
On 21 Mar 2006, at 14:45, Wouter wrote:
> on Sun Mar 19 16:12:57 CST 2006 Geoff Canyon wrote:
>
>> /* this is a comment
>> as is this */on mouseUp
>> answer "yes"
>> end mouseUp
>
>
> Another problem with this kind of commenting is shown in the
> following cases:
>
> /* this is a comment
> as is this */-function whatever
> return "something"
> end whatever
>
> /* this is a comment
> as is this */--function whatever
> return "something"
> end whatever
>
> Both will compile without throwing an error.
> Only the second one is a valid comment
>
> Greetings,
> Wouter
>
> PS another little update (beware of the mail line wraps):
>
> function retrieveActiveHandlers pScript
> put true into tFlag
> repeat for each line i in pScript
> if char 1 to 2 of word 1 of i = "/*" then
> put false into tFlag
> else if tFlag and token 1 of i is among the items of
> "on,function,setprop,getprop" then put token 1 to -1 of i & cr
> after tList
> else if tFlag = false then
> if (char 1 of word 1 of i is "#" or char 1 of word 1 of i is
> "-" ) and "*/" is in i then
> put true into tFlag
> get "/*" &i
> if tFlag and token 1 of it is among the items of
> "on,function,setprop,getprop" then
> put token 1 to -1 of it & cr after tList
> end if
> else
> repeat for each token j in i
> if j is "*/" then
> put true into tFlag
> get "/*" &i
> if tFlag and token 1 of it is among the items of
> "on,function,setprop,getprop" then
> put token 1 to -1 of it & cr after tList
> exit repeat
> end if
> end if
> end repeat
> end if
> end if --
> end repeat
> return tList
> end retrieveActiveHandlers
>
> _______________________________________________
> 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