'From Squeak3.4beta of ''1 December 2002'' [latest update: #5156] on 21 December 2002 at 1:39:37 pm'! "Change Set: AcornDirFixes Date: 21 December 2002 Author: tim@sumeru.stanford.edu Make sure at least one sensible directory appears in directoryContentsFor:. Only affects Acorn machines"! !AcornFileDirectory methodsFor: 'private' stamp: 'tpr 12/21/2002 13:37'! directoryContentsFor: fullPath "Return a collection of directory entries for the files and directories in the directory with the given path. See primLookupEntryIn:index: for further details." "FileDirectory default directoryContentsFor: ''" | entries extraPath | entries _ super directoryContentsFor: fullPath. fullPath isEmpty ifTrue: [ "For Acorn we also make sure that at least the parent of the current dir is added - sometimes this is in a filing system that has not been (or cannot be) polled for disc root names" extraPath _ self class default containingDirectory. (entries findFirst: [:ent | ent name = extraPath fullName] ) > 0 ifFalse: [entries _ entries copyWith: (DirectoryEntry name: extraPath fullName creationTime: 0 modificationTime: 0 isDirectory: true fileSize: 0)]]. ^ entries ! !