patches
changeset 358 14a45495e3d8
parent 323 42233c66f9a0
child 362 87f7b4670ae8
equal deleted inserted replaced
357:dc01b7bc319e 358:14a45495e3d8
   138     (Smalltalk at:#Workstation) autoload.
   138     (Smalltalk at:#Workstation) autoload.
   139     (Smalltalk at:#DeviceHandle) autoload.
   139     (Smalltalk at:#DeviceHandle) autoload.
   140 ].
   140 ].
   141 !
   141 !
   142 
   142 
   143 "/
       
   144 "/ read the abbrev.stc file, extract class names
       
   145 "/ and install all nonExisting classes as autoloaded
       
   146 "/
       
   147 |needToReactivate|
       
   148 
       
   149 HistoryManager notNil ifTrue:[
       
   150     needToReactivate := HistoryManager isActive.
       
   151     HistoryManager deactivate.
       
   152 ] ifFalse:[
       
   153     needToReactivate := false
       
   154 ].
       
   155 
       
   156 Class withoutUpdatingChangesDo:[   
       
   157    'patches [info]: installing autoloaded classes ...' infoPrintCR.
       
   158    Smalltalk installAutoloadedClassesFrom:'include/abbrev.stc'.
       
   159 ].
       
   160 needToReactivate ifTrue:[HistoryManager activate].
       
   161 !
       
   162 
       
   163 "/
       
   164 "/ a kludge: we might have added new ImageReaders above - let Image know about it
       
   165 "/
       
   166 |imageClass cls|
       
   167 
       
   168 imageClass := Smalltalk at:#Image ifAbsent:nil.
       
   169 imageClass notNil ifTrue:[
       
   170     imageClass isBehavior ifTrue:[
       
   171 	imageClass initializeFileFormatTable.
       
   172     ]
       
   173 ].
       
   174 
       
   175 "/
       
   176 "/ some ST80 name aliases
       
   177 "/ (actually, much more is needed - this is just a start ...)
       
   178 "/
       
   179 (cls := Smalltalk at:#StandardSystemView) notNil ifTrue:[
       
   180     Smalltalk at:#ScheduledWindow put:cls
       
   181 ].
       
   182 (cls := Smalltalk at:#Socket) notNil ifTrue:[
       
   183     Smalltalk at:#UnixSocketAccessor put:cls.
       
   184     Smalltalk at:#SocketAccessor put:cls.
       
   185     Smalltalk at:#SocketAccessorByAddress put:cls.
       
   186 ].
       
   187 Smalltalk at:#BlockClosure put:Block.
       
   188 Smalltalk at:#CompiledMethod put:Method.
       
   189 (cls := Smalltalk at:#DialogBox) notNil ifTrue:[
       
   190     Smalltalk at:#Dialog     put:cls.
       
   191     Smalltalk at:#DialogView put:cls.
       
   192 ].
       
   193 Smalltalk at:#ByteString put:String.
       
   194 Smalltalk at:#ByteSymbol put:Symbol.
       
   195 Smalltalk at:#ByteEncodedString put:String.
       
   196 Smalltalk at:#Console put:Stderr.
       
   197 Smalltalk at:#HandlerList put:HandlerCollection.
       
   198 Smalltalk at:#SignalCollection put:SignalSet.
       
   199 Smalltalk at:#Timestamp put:AbsoluteTime.
       
   200 
       
   201 "/ FileDirectory notNil ifTrue:[
       
   202 "/     Smalltalk at:#Disk put:(Filename rootDirectory)
       
   203 "/ ].
       
   204 
       
   205 Display notNil ifTrue:[
       
   206     Smalltalk at:#Window put:(Display class).
       
   207     Smalltalk at:#Screen put:(Display class).
       
   208     Smalltalk at:#Sensor put:Display.
       
   209 ].
       
   210 
       
   211 "/
       
   212 "/ ST/X has (currently) no Double, but Float is what ST-80's Double is ...
       
   213 "/
       
   214 Smalltalk at:#Double put:Float.
       
   215 
       
   216 Smalltalk at:#Browser put:SystemBrowser.
       
   217 
       
   218 Project notNil ifTrue:[
   143 Project notNil ifTrue:[
   219     Project setDefaultProject.
   144     Project setDefaultProject.
   220     Project current packageName:#'patches'.
   145     Project current packageName:#'patches'.
   221 ].
   146 ].
   222 
   147 
   225 
   150 
   226 "/ future systems will read patches from a patch-directory,
   151 "/ future systems will read patches from a patch-directory,
   227 "/ called stxPatches. (we will deliver patch-sets in the future)
   152 "/ called stxPatches. (we will deliver patch-sets in the future)
   228 "/ This is not yet implemented, but we are prepared here for
   153 "/ This is not yet implemented, but we are prepared here for
   229 "/ this ...
   154 "/ this ...
       
   155 "/ patches from that directory are read in alphabetic order;
       
   156 "/ patches will be named them p_nnnn.st, where nnnn is a sequence-nr.
   230 
   157 
   231 |patchDir|
   158 |patchDir|
   232 
   159 
   233 patchDir := 'stxPatches' asFilename.
   160 patchDir := 'stxPatches' asFilename.
   234 (patchDir exists and:[patchDir isDirectory and:[patchDir isReadable]]) ifTrue:[
   161 (patchDir exists and:[patchDir isDirectory and:[patchDir isReadable]]) ifTrue:[
   235     patchDir directoryContents do:[:f |
   162     patchDir directoryContents sort do:[:f |
   236 	|fn|
   163 	|fn|
   237 
   164 
   238 	fn := (patchDir construct:f) name.
   165 	fn := (patchDir construct:f) name.
   239 	('patches [info]: reading patchFile ''' , fn , ''' ...') infoPrintCR.
   166 	('patches [info]: reading patchFile ''' , fn , ''' ...') infoPrintCR.
   240 	Smalltalk fileIn:fn.
   167 	Smalltalk fileIn:fn.