(no subject)

Andre.Bisseret Andre.Bisseret at inria.fr
Sun Apr 18 18:06:54 EDT 2010


Le 18 avr. 10 à 15:34, Haroldo Mauro Jr. a écrit :

> At 15:06 +0200 18/04/10, Andre.Bisseret wrote:
>> Bonjour Haroldo,
>> Welcome to the list :-)))
>>
>>
>> Le 18 avr. 10 à 13:29, Haroldo Mauro Jr. a écrit :
>>
>>> Hi everybody, I just joined this list. I used Hypercard for many  
>>> years, since I got my first Mac in 1991. Then, some years ago  
>>> swiched to  Supercard, which I've been using a lot.  I've had  
>>> Revolution Studio for over a year but only now am trying to use it  
>>> more steadly. So, here's what I need help with right now.
>>> In a converted Hypercard stack, an arrowKey handler in the stack  
>>> script is not behaving as expected. So I checked the Revolution  
>>> dictionary and found this example below, which I tested on my  
>>> stack and it didn't work, just the same:
>>>
>>> (example from Rev dictionary)
>>> on arrowKey theKey -- make Up arrow go to the first card
>>> if theKey is "up" then go to card 1
>>> else pass arrowKey
>>> end arrowKey
>>>
>>> Instead of going to card 1 it kept going to the next card each  
>>> time I pressed the up arrow key, and after the last card the stack  
>>> just closed.
>>
>> I just made
>> -  a new main stack
>> - pasted  the handler above in the stack script
>>
>> then it is working as expected. Il I am on card 2 or 3, pressing  
>> the up arrow key leads me to card 1
>>
>> I am on RunRev Enterprise. I havn't RunRev Studio. But I tried with  
>> RunRev Media, and it is running as expected as well.
>>
>> Well, don"t know why it is not the case for you; hav'nt you kept  
>> another handler somewhere which could interfere? (take precedence  
>> over this one)
>>
>> Best regards from Grenoble
>>
>> André
>
>
> Andre, I opened the stack with Media, but no luck. However, I  
> created a new stack and it worked (the short one). It seems obvious  
> that the problem is in the stack.  However, I  converted the same  
> stack to Supercard and that same script (the long one) works in SC,  
> as well as in Hypercard. I did a search for arrowKey in the search  
> box and found it only  once, in the stack script.
>
> Haroldo

Haroldo,

I had tried only the short one. I just tried your long script on the  
same stack (I just added " if whichKey is "up" then go to card 1" as a  
first line, for fun ;-)) but might be useful anyway!

I  assume that your are expecting one is "circling" in the same  
background when, being on the first card of a bg, one presses the left  
arrowkey (or the  right arrowkey when being on the last card of the  
bg). If this is the case, then no problem; your script works well in a  
stack created in rev.

André









More information about the Use-livecode mailing list