AbstractFileBrowser.st
changeset 19582 32a575b05791
parent 19572 11ffbd148327
equal deleted inserted replaced
19581:4169ae666b57 19582:32a575b05791
     1 "{ Encoding: utf8 }"
       
     2 
       
     3 "
     1 "
     4  COPYRIGHT (c) 2002 by eXept Software AG
     2  COPYRIGHT (c) 2002 by eXept Software AG
     5               All Rights Reserved
     3               All Rights Reserved
     6 
     4 
     7  This software is furnished under a license and may be used
     5  This software is furnished under a license and may be used
  3024                                 (decodedChar between:0 and:31) ifTrue:[
  3022                                 (decodedChar between:0 and:31) ifTrue:[
  3025                                     "/ the 'nul', 'soh' .. 'gs' chars in unicodePage 2400
  3023                                     "/ the 'nul', 'soh' .. 'gs' chars in unicodePage 2400
  3026                                     "/ are perfect here, but usually not available in the font
  3024                                     "/ are perfect here, but usually not available in the font
  3027                                     "/ and we have currently no way of knowing if they are...
  3025                                     "/ and we have currently no way of knowing if they are...
  3028                                     "/ (could let the font draw into a bitmap and check if there is something...)
  3026                                     "/ (could let the font draw into a bitmap and check if there is something...)
  3029                                     "/ For now, write a dot.·
  3027                                     "/ For now, write a dot.·
  3030                                     "/ charPrinted := (Character value:(byte + 16r2400))
  3028                                     "/ charPrinted := (Character value:(byte + 16r2400))
  3031                                 ].
  3029                                 ].
  3032                             ].
  3030                             ].
  3033                         ].
  3031                         ].
  3034                         asciiString := String with:charPrinted.
  3032                         asciiString := String with:charPrinted.
  8752                 ^ self.
  8750                 ^ self.
  8753             ].
  8751             ].
  8754 
  8752 
  8755             file1 notNil ifTrue:[
  8753             file1 notNil ifTrue:[
  8756                 file1 isDirectory ifTrue:[
  8754                 file1 isDirectory ifTrue:[
  8757                     text1 := file1 directoryContents asString.
  8755                     text1 := file1 directoryContents asStringCollection asString.
  8758                 ] ifFalse:[
  8756                 ] ifFalse:[
  8759                     text1 := file1 contents.
  8757                     text1 := file1 contents.
  8760                 ]
  8758                 ]
  8761             ].
  8759             ].
  8762             file2 isDirectory ifTrue:[
  8760             file2 isDirectory ifTrue:[
  8763                 text2 := file2 directoryContents asString.
  8761                 text2 := file2 directoryContents asStringCollection asString.
  8764             ] ifFalse:[
  8762             ] ifFalse:[
  8765                 text2 := file2 contents.
  8763                 text2 := file2 contents.
  8766             ].
  8764             ].
  8767             text1 = text2 ifTrue:[
  8765             text1 = text2 ifTrue:[
  8768                 (file1 isDirectory or:[file2 isDirectory]) ifTrue:[
  8766                 (file1 isDirectory or:[file2 isDirectory]) ifTrue:[
  9259                 redefKind := 'class'.
  9257                 redefKind := 'class'.
  9260                 isRedef := true.
  9258                 isRedef := true.
  9261             ] ifFalse:[sig == HaltInterrupt ifTrue:[ |sender|
  9259             ] ifFalse:[sig == HaltInterrupt ifTrue:[ |sender|
  9262                 label := msg := 'Breakpoint/Halt in fileIn'.
  9260                 label := msg := 'Breakpoint/Halt in fileIn'.
  9263                 sender := ex suspendedContext.
  9261                 sender := ex suspendedContext.
  9264                 msg := msg , ('\\in %1 » %2' bindWith:(sender receiver class name) with:(sender sender selector))
  9262                 msg := msg , ('\\in %1 » %2' bindWith:(sender receiver class name) with:(sender sender selector))
  9265             ] ifFalse:[
  9263             ] ifFalse:[
  9266                 label := 'Error in fileIn'.
  9264                 label := 'Error in fileIn'.
  9267                 msg := 'error in fileIn: %1'
  9265                 msg := 'error in fileIn: %1'
  9268             ]]].
  9266             ]]].
  9269 
  9267