[Squeakland] bug in PasteUpMorph::cursorWrapped: ?

Nicholas Bennett nicholasjbennett at hotmail.com
Fri Jun 3 19:13:45 PDT 2005


squeakers,

I think the implementation for PasteUpMorph::cursorWrapped: is flawed.

I used a Holder to hold 4 Sketches to use in an animation cycle. I made a 
'tick count' variable and each tick of a scrip set the Holder cursor to tick 
count. Once tick is greater than 4 things go wrong, the first sketch gets 
shown twice and the last never.

The code for PasteUpMorph::cursorWrapped looks like it would work if the 
'indexing' of elements was zero based - but it seems to be '1' based - at 
least for a 'Holder'.

the relevant part of the method is:
    t2 > submorphs size
        ifTrue: [submorphs size > 0
                        ifTrue: [cursor _ cursor \\ submorphs size]
                        ifFalse: [cursor _ 1]].

I think it probbaly means 'cursor _ cursor \\ submorphs size + 1' but there 
could be other users of PasteUpMorph that are zero based.

Is this a bug? seems that it would be easier to make animation cycles work 
like kids would expect them to with a change like this. Can someone give me 
a reference to the bug reporting / fixing proceedure for squeakland 
codebase?

regards,
nicholas




More information about the Squeakland mailing list