'From Squeak3.6alpha of ''17 March 2003'' [latest update: #5205] on 22 May 2003 at 9:46:52 am'! !FileList2 class methodsFor: 'morphic ui' stamp: 'bkv 5/22/2003 08:47'! morphicViewOn: aDirectory withLabel: aString | aFileList window fileListBottom midLine fileListTopOffset buttonPane | aFileList _ self new directory: aDirectory. window _ (SystemWindow labelled: aString) model: aFileList. fileListTopOffset _ (TextStyle defaultFont pointSize * 2) + 14. fileListBottom _ 0.4. midLine _ 0.4. buttonPane _ aFileList optionalButtonRow addMorph: (aFileList morphicPatternPane vResizing: #spaceFill; yourself). self addFullPanesTo: window from: { {buttonPane. 0@0 corner: 1@0. 0@0 corner: 0@fileListTopOffset}. {aFileList morphicDirectoryTreePane. 0@0 corner: midLine@fileListBottom. 0@fileListTopOffset corner: 0@0}. {aFileList morphicFileListPane. midLine @ 0 corner: 1@fileListBottom. 0@fileListTopOffset corner: 0@0}. {aFileList morphicFileContentsPane. 0@fileListBottom corner: 1@1. nil}. }. aFileList postOpen. ^ window ! ! !HttpUrl methodsFor: '*bug fix archive' stamp: 'bkv 5/16/2003 07:01'! asMailMessage "Currently only supports text/plain downloads. Probably should be extended to handle application/octet-stream downloads of zipped mail." | mimeDoc in out char mailMsg | mimeDoc _ self retrieveContents. ( mimeDoc contentType = 'text/plain' ) ifFalse: [ ^nil ]. "Not supported right now." "The downloaded MIMEDocument is assumed to be like the .txt files available from swiki.gsug.org, which have linefeeds in them that blow up the MailMessage parser. If we remove all line feeds, the MailMessage object created from this String seems to be just fine." in _ ReadStream on: mimeDoc content. out _ WriteStream on: ''. [ in atEnd ] whileFalse: [ ((char _ in next) == Character lf) ifFalse: [ out nextPut: char ]]. mailMsg _ MailMessage from: out contents. ^mailMsg ! ! !MailMessage methodsFor: '*bug fix archive' stamp: 'bkv 5/16/2003 07:18'! asArchivePost ^ArchivePost withMailMessage: self! !