'From etoys3.0 of 24 February 2008 [latest update: #2027] on 19 June 2008 at 3:50:46 pm'! "Change Set: tabAmongFields-sw Date: 19 June 2008 Author: Scott Wallace TRAC 7313: Tab-among-fields logic broken : The logic for tabbing among fields is broken in several ways; in particular any rotated text field, and any other text field whose immediate owner is not a PasteUpMorph, is excluded from participating properly in the tab-among-fields logic. Refer to the extensive method comment in this update's lone method for details."! !Morph methodsFor: 'structure' stamp: 'sw 6/19/2008 15:40'! pasteUpMorphHandlingTabAmongFields "For the purpose of determing how to service a 'tab' character hit within some text field, answer the nearest PasteUpMorph in my owner chain that would want to interpret the tab key as an attempt to navigate from field to field. Unless some playfield, book-page, or some such, has explicitly had its #tabAmongFields property set, this will normally be the World. Note that the only situation in which nil will be returned by this method is if the #tabAmongFields preference is set to false *and* there is no pasteup in the owner chain of the text-morph into which the tab-key was it which itself has the #tabAmongFields property." | aPasteUp | aPasteUp _ self pasteUpMorphOrWorld. [aPasteUp notNil] whileTrue: [((aPasteUp hasProperty: #tabAmongFields) or: [aPasteUp isWorldMorph and: [Preferences tabAmongFields]]) ifTrue: [^ aPasteUp]. aPasteUp _ aPasteUp pasteUpMorphOrWorld]. ^ nil! !