# HG changeset patch # User penk # Date 1039696649 -3600 # Node ID 777181a805ec838851995019e65c25a8dd73b409 # Parent 9b496f6aa2a152f4be37e8beaef02dc33895a232 restart image process after restart from image diff -r 9b496f6aa2a1 -r 777181a805ec DirectoryContentsBrowser.st --- a/DirectoryContentsBrowser.st Thu Dec 12 12:59:08 2002 +0100 +++ b/DirectoryContentsBrowser.st Thu Dec 12 13:37:29 2002 +0100 @@ -2098,14 +2098,15 @@ ! startUpdateTask - - | processLoop | - updateTask isNil ifTrue:[ - processLoop := self updateLoop. - updateTask := processLoop newProcess. + updateTask := [ + [true] whileTrue:[ + self updateStep + ] + ] newProcess. updateTask name:'DirectoryContentsBrowser updateTask'. updateTask priorityRange:(Processor systemBackgroundPriority to:Processor activePriority). + updateTask restartable:true. updateTask resume. ]. ! @@ -2158,30 +2159,25 @@ ] ! -updateLoop - - ^ [ - [true] whileTrue:[ - AbortSignal handle:[ - self debugMessage:'get an abort signal'. - self directoryContentsChangeFlag:false. - self filterChangeFlag:false. - self sortBlockChangeFlag:false. - ] do:[ - | timeOut | - self debugMessage:'sema wait'. - timeOut := (self changeSema waitWithTimeoutMs:(self class updateTaskCyleTime)) isNil. - self debugMessage:'timeOut:', timeOut asString. - (self filterChangeFlag or:[self sortBlockChangeFlag or:[self directoryChangeFlag]]) ifTrue:[ - | oldCursor | - oldCursor := self window cursor. - self showCursor:(Cursor execute). - self updateBlock value:timeOut. - self showCursor:oldCursor. - ] ifFalse:[ - self updateBlock value:timeOut. - ] - ] +updateStep + AbortSignal handle:[ + self debugMessage:'get an abort signal'. + self directoryContentsChangeFlag:false. + self filterChangeFlag:false. + self sortBlockChangeFlag:false. + ] do:[ + | timeOut | + self debugMessage:'sema wait'. + timeOut := (self changeSema waitWithTimeoutMs:(self class updateTaskCyleTime)) isNil. + self debugMessage:'timeOut:', timeOut asString. + (self filterChangeFlag or:[self sortBlockChangeFlag or:[self directoryChangeFlag]]) ifTrue:[ + | oldCursor | + oldCursor := self window cursor. + self showCursor:(Cursor execute). + self updateBlock value:timeOut. + self showCursor:oldCursor. + ] ifFalse:[ + self updateBlock value:timeOut. ] ] ! ! @@ -2710,5 +2706,5 @@ !DirectoryContentsBrowser class methodsFor:'documentation'! version - ^ '$Header: /cvs/stx/stx/libtool/DirectoryContentsBrowser.st,v 1.64 2002-12-06 11:48:59 cg Exp $' + ^ '$Header: /cvs/stx/stx/libtool/DirectoryContentsBrowser.st,v 1.65 2002-12-12 12:37:29 penk Exp $' ! !