--- a/FBrowser.st Mon Jan 15 13:40:35 1996 +0100
+++ b/FBrowser.st Wed Jan 17 11:52:58 1996 +0100
@@ -716,13 +716,13 @@
lockUpdate := false.
CommandHistory isNil ifTrue:[
- CommandHistory := OrderedCollection new.
- CommandHistorySize := 50
+ CommandHistory := OrderedCollection new.
+ CommandHistorySize := 50
].
DirectoryHistory isNil ifTrue:[
- DirectoryHistory := OrderedCollection new.
- DirectoryHistoryWhere := OrderedCollection new.
- HistorySize := 15.
+ DirectoryHistory := OrderedCollection new.
+ DirectoryHistoryWhere := OrderedCollection new.
+ HistorySize := 15.
].
commandIndex := 0.
@@ -730,12 +730,12 @@
self label:myName.
labelFrame := View
- origin:(0.0 @ 0.0)
- corner:(1.0 @ (font height * 2))
- in:self.
+ origin:(0.0 @ 0.0)
+ corner:(1.0 @ (font height * 2))
+ in:self.
styleSheet name = #st80 ifTrue:[
- labelFrame level:1
+ labelFrame level:1
].
spacing := ViewSpacing.
@@ -748,7 +748,7 @@
filterField := EditField in:labelFrame.
filterField origin:[((width // 4 * 3) + halfSpacing) @ halfSpacing]
- corner:(1.0 @ filterField heightIncludingBorder).
+ corner:(1.0 @ filterField heightIncludingBorder).
filterField rightInset:ViewSpacing-halfSpacing.
self initializeFilterPattern.
@@ -756,11 +756,11 @@
labelView := Label in:labelFrame.
labelView origin:(halfSpacing @ halfSpacing)
- extent:[((width // 4 * 3) - spacing - borderWidth)
- @
- (filterField heightIncludingBorder)
- "(font height + font descent)"
- ].
+ extent:[((width // 4 * 3) - spacing - borderWidth)
+ @
+ (filterField heightIncludingBorder)
+ "(font height + font descent)"
+ ].
labelView adjust:#right.
labelView borderWidth:0.
labelView model:self; menu:#labelMenu; aspect:#path; labelMessage:#path.
@@ -768,8 +768,8 @@
killButton := Button label:(resources string:'kill') in:self.
killButton origin:(halfSpacing @ halfSpacing)
- extent:(killButton width @ filterField height).
- killButton hiddenOnRealize:true.
+ extent:(killButton width @ filterField height).
+ killButton beInvisible.
self initializeCommandViewIn:self.
@@ -785,7 +785,7 @@
frame := VariableVerticalPanel origin:0.0@0.0 corner:1.0@1.0 in:self.
frame topInset:labelFrame height.
commandView notNil ifTrue:[
- frame bottomInset:(commandView height + spacing + spacing)
+ frame bottomInset:(commandView height + spacing + spacing)
].
topFrame := ScrollableView for:SelectionInListView in:frame.
@@ -794,7 +794,7 @@
fileListView := topFrame scrolledView.
fileListView action:[:lineNr | self fileSelect:lineNr].
fileListView doubleClickAction:[:lineNr | self fileSelect:lineNr.
- self fileGet].
+ self fileGet].
fileListView multipleSelectOk:true.
fileListView menuHolder:self; menuPerformer:self; menuMessage:#fileListMenu.
@@ -803,12 +803,13 @@
v origin:(0.0 @ 0.3) corner:(1.0 @ 1.0).
subView := v scrolledView.
(subView respondsTo:#directoryForFileDialog:) ifTrue:[
- subView directoryForFileDialog:currentDirectory
+ subView directoryForFileDialog:currentDirectory
].
ObjectMemory addDependent:self.
"Modified: 6.9.1995 / 20:26:06 / claus"
+ "Modified: 17.1.1996 / 11:45:56 / cg"
!
initializeCommandViewIn:frame
@@ -1398,18 +1399,18 @@
bring it to front, and turn hidden-mode off
"
killButton raise.
- killButton hiddenOnRealize:false.
+ killButton beVisible.
"
it will make me raise stopSignal when pressed
"
killButton
- action:[
- stream notNil ifTrue:[
- access critical:[
- myProcess interruptWith:[stopSignal raise].
- ]
- ]
- ].
+ action:[
+ stream notNil ifTrue:[
+ access critical:[
+ myProcess interruptWith:[stopSignal raise].
+ ]
+ ]
+ ].
"
start it up under its own windowgroup
"
@@ -1421,63 +1422,63 @@
self label:(myName , ': executing ' , (command copyTo:(20 min:command size)) , ' ...').
[
self withWaitCursorDo:[
- stopSignal catch:[
- startLine := subView cursorLine.
- startCol := subView cursorCol.
+ stopSignal catch:[
+ startLine := subView cursorLine.
+ startCol := subView cursorCol.
- stream := PipeStream readingFrom:('cd '
- , currentDirectory pathName
- , '; '
- , command
- , ' 2>&1' ).
- stream notNil ifTrue:[
- "
- this can be a time consuming operation; therefore lower my priority
- "
- myProcess := Processor activeProcess.
- myPriority := myProcess priority.
- myProcess priority:(Processor userBackgroundPriority).
+ stream := PipeStream readingFrom:('cd '
+ , currentDirectory pathName
+ , '; '
+ , command
+ , ' 2>&1' ).
+ stream notNil ifTrue:[
+ "
+ this can be a time consuming operation; therefore lower my priority
+ "
+ myProcess := Processor activeProcess.
+ myPriority := myProcess priority.
+ myProcess priority:(Processor userBackgroundPriority).
- [
- |codeView lines|
+ [
+ |codeView lines|
- codeView := subView.
+ codeView := subView.
- replace ifTrue:[
- codeView list:nil.
- lnr := 1.
- ].
+ replace ifTrue:[
+ codeView list:nil.
+ lnr := 1.
+ ].
- [stream atEnd] whileFalse:[
- (stream readWaitWithTimeoutMs:250) ifFalse:[
- "
- data available
- "
- lines := OrderedCollection new:50.
- line := stream nextLine.
- line notNil ifTrue:[lines add:line].
+ [stream atEnd] whileFalse:[
+ (stream readWaitWithTimeoutMs:250) ifFalse:[
+ "
+ data available
+ "
+ lines := OrderedCollection new:50.
+ line := stream nextLine.
+ line notNil ifTrue:[lines add:line].
- [stream atEnd not
- and:[stream canReadWithoutBlocking
- and:[lines size < 50]]] whileTrue:[
- line := stream nextLine.
- line notNil ifTrue:[lines add:line].
- ].
+ [stream atEnd not
+ and:[stream canReadWithoutBlocking
+ and:[lines size < 50]]] whileTrue:[
+ line := stream nextLine.
+ line notNil ifTrue:[lines add:line].
+ ].
- "
- need this critical section; otherwise,
- we could get the signal while waiting for
- an expose event ...
- "
- access critical:[
- lines size > 0 ifTrue:[
- replace ifTrue:[
- lines do:[:line |
- codeView at:lnr put:line withTabsExpanded.
- codeView cursorToBottom; cursorDown.
- lnr := lnr + 1.
- ].
- ] ifFalse:[
+ "
+ need this critical section; otherwise,
+ we could get the signal while waiting for
+ an expose event ...
+ "
+ access critical:[
+ lines size > 0 ifTrue:[
+ replace ifTrue:[
+ lines do:[:line |
+ codeView at:lnr put:line withTabsExpanded.
+ codeView cursorToBottom; cursorDown.
+ lnr := lnr + 1.
+ ].
+ ] ifFalse:[
codeView insertLines:lines before:codeView cursorLine.
codeView cursorDown:lines size.
"/ lines do:[:line |
@@ -1486,68 +1487,68 @@
"/ ]
"/ codeView insertStringAtCursor:line.
"/ codeView insertCharAtCursor:(Character cr).
- ]
- ].
- ].
- ].
+ ]
+ ].
+ ].
+ ].
- shown ifTrue:[windowGroup processExposeEvents].
- "
- give others running at same prio a chance too
- (especially other FileBrowsers doing the same)
- "
- Processor yield
- ].
- ] valueNowOrOnUnwindDo:[
- stream close. stream := nil.
- ].
- self updateCurrentDirectory
- ].
- replace ifTrue:[
- subView modified:false.
- ].
- ]
+ shown ifTrue:[windowGroup processExposeEvents].
+ "
+ give others running at same prio a chance too
+ (especially other FileBrowsers doing the same)
+ "
+ Processor yield
+ ].
+ ] valueNowOrOnUnwindDo:[
+ stream close. stream := nil.
+ ].
+ self updateCurrentDirectory
+ ].
+ replace ifTrue:[
+ subView modified:false.
+ ].
+ ]
]
] valueNowOrOnUnwindDo:[
- |wg|
+ |wg|
- self label:myName; iconLabel:myName.
- myProcess notNil ifTrue:[myProcess priority:myPriority].
+ self label:myName; iconLabel:myName.
+ myProcess notNil ifTrue:[myProcess priority:myPriority].
- "
- remove the killButton from its group
- (otherwise, it will be destroyed when we shut down the group)
- "
- wg := killButton windowGroup.
- killButton windowGroup:nil.
- "
- shut down the windowgroup
- "
- wg notNil ifTrue:[
- wg process terminate.
- ].
- "
- hide the button, and make sure it will stay
- hidden when we are realized again
- "
- killButton unrealize.
- killButton hiddenOnRealize:true.
- "
- clear its action (actually not needed, but
- releases reference to thisContext earlier)
- "
- killButton action:nil.
+ "
+ remove the killButton from its group
+ (otherwise, it will be destroyed when we shut down the group)
+ "
+ wg := killButton windowGroup.
+ killButton windowGroup:nil.
+ "
+ shut down the windowgroup
+ "
+ wg notNil ifTrue:[
+ wg process terminate.
+ ].
+ "
+ hide the button, and make sure it will stay
+ hidden when we are realized again
+ "
+ killButton beInvisible.
+ "
+ clear its action (actually not needed, but
+ releases reference to thisContext earlier)
+ "
+ killButton action:nil.
].
currentFileName isNil ifTrue:[
- subView modified:false.
+ subView modified:false.
].
subView size > 10000 ifTrue:[
- self warn:'text quite large now - please cut off some lines'
+ self warn:'text quite large now - please cut off some lines'
]
"Modified: 21.9.1995 / 11:18:46 / claus"
+ "Modified: 17.1.1996 / 11:45:49 / cg"
!
doFileGet
@@ -2370,4 +2371,4 @@
!FileBrowser class methodsFor:'documentation'!
version
-^ '$Header: /cvs/stx/stx/libtool/Attic/FBrowser.st,v 1.65 1995-12-17 14:47:14 cg Exp $'! !
+^ '$Header: /cvs/stx/stx/libtool/Attic/FBrowser.st,v 1.66 1996-01-17 10:52:58 cg Exp $'! !
--- a/FileBrowser.st Mon Jan 15 13:40:35 1996 +0100
+++ b/FileBrowser.st Wed Jan 17 11:52:58 1996 +0100
@@ -716,13 +716,13 @@
lockUpdate := false.
CommandHistory isNil ifTrue:[
- CommandHistory := OrderedCollection new.
- CommandHistorySize := 50
+ CommandHistory := OrderedCollection new.
+ CommandHistorySize := 50
].
DirectoryHistory isNil ifTrue:[
- DirectoryHistory := OrderedCollection new.
- DirectoryHistoryWhere := OrderedCollection new.
- HistorySize := 15.
+ DirectoryHistory := OrderedCollection new.
+ DirectoryHistoryWhere := OrderedCollection new.
+ HistorySize := 15.
].
commandIndex := 0.
@@ -730,12 +730,12 @@
self label:myName.
labelFrame := View
- origin:(0.0 @ 0.0)
- corner:(1.0 @ (font height * 2))
- in:self.
+ origin:(0.0 @ 0.0)
+ corner:(1.0 @ (font height * 2))
+ in:self.
styleSheet name = #st80 ifTrue:[
- labelFrame level:1
+ labelFrame level:1
].
spacing := ViewSpacing.
@@ -748,7 +748,7 @@
filterField := EditField in:labelFrame.
filterField origin:[((width // 4 * 3) + halfSpacing) @ halfSpacing]
- corner:(1.0 @ filterField heightIncludingBorder).
+ corner:(1.0 @ filterField heightIncludingBorder).
filterField rightInset:ViewSpacing-halfSpacing.
self initializeFilterPattern.
@@ -756,11 +756,11 @@
labelView := Label in:labelFrame.
labelView origin:(halfSpacing @ halfSpacing)
- extent:[((width // 4 * 3) - spacing - borderWidth)
- @
- (filterField heightIncludingBorder)
- "(font height + font descent)"
- ].
+ extent:[((width // 4 * 3) - spacing - borderWidth)
+ @
+ (filterField heightIncludingBorder)
+ "(font height + font descent)"
+ ].
labelView adjust:#right.
labelView borderWidth:0.
labelView model:self; menu:#labelMenu; aspect:#path; labelMessage:#path.
@@ -768,8 +768,8 @@
killButton := Button label:(resources string:'kill') in:self.
killButton origin:(halfSpacing @ halfSpacing)
- extent:(killButton width @ filterField height).
- killButton hiddenOnRealize:true.
+ extent:(killButton width @ filterField height).
+ killButton beInvisible.
self initializeCommandViewIn:self.
@@ -785,7 +785,7 @@
frame := VariableVerticalPanel origin:0.0@0.0 corner:1.0@1.0 in:self.
frame topInset:labelFrame height.
commandView notNil ifTrue:[
- frame bottomInset:(commandView height + spacing + spacing)
+ frame bottomInset:(commandView height + spacing + spacing)
].
topFrame := ScrollableView for:SelectionInListView in:frame.
@@ -794,7 +794,7 @@
fileListView := topFrame scrolledView.
fileListView action:[:lineNr | self fileSelect:lineNr].
fileListView doubleClickAction:[:lineNr | self fileSelect:lineNr.
- self fileGet].
+ self fileGet].
fileListView multipleSelectOk:true.
fileListView menuHolder:self; menuPerformer:self; menuMessage:#fileListMenu.
@@ -803,12 +803,13 @@
v origin:(0.0 @ 0.3) corner:(1.0 @ 1.0).
subView := v scrolledView.
(subView respondsTo:#directoryForFileDialog:) ifTrue:[
- subView directoryForFileDialog:currentDirectory
+ subView directoryForFileDialog:currentDirectory
].
ObjectMemory addDependent:self.
"Modified: 6.9.1995 / 20:26:06 / claus"
+ "Modified: 17.1.1996 / 11:45:56 / cg"
!
initializeCommandViewIn:frame
@@ -1398,18 +1399,18 @@
bring it to front, and turn hidden-mode off
"
killButton raise.
- killButton hiddenOnRealize:false.
+ killButton beVisible.
"
it will make me raise stopSignal when pressed
"
killButton
- action:[
- stream notNil ifTrue:[
- access critical:[
- myProcess interruptWith:[stopSignal raise].
- ]
- ]
- ].
+ action:[
+ stream notNil ifTrue:[
+ access critical:[
+ myProcess interruptWith:[stopSignal raise].
+ ]
+ ]
+ ].
"
start it up under its own windowgroup
"
@@ -1421,63 +1422,63 @@
self label:(myName , ': executing ' , (command copyTo:(20 min:command size)) , ' ...').
[
self withWaitCursorDo:[
- stopSignal catch:[
- startLine := subView cursorLine.
- startCol := subView cursorCol.
+ stopSignal catch:[
+ startLine := subView cursorLine.
+ startCol := subView cursorCol.
- stream := PipeStream readingFrom:('cd '
- , currentDirectory pathName
- , '; '
- , command
- , ' 2>&1' ).
- stream notNil ifTrue:[
- "
- this can be a time consuming operation; therefore lower my priority
- "
- myProcess := Processor activeProcess.
- myPriority := myProcess priority.
- myProcess priority:(Processor userBackgroundPriority).
+ stream := PipeStream readingFrom:('cd '
+ , currentDirectory pathName
+ , '; '
+ , command
+ , ' 2>&1' ).
+ stream notNil ifTrue:[
+ "
+ this can be a time consuming operation; therefore lower my priority
+ "
+ myProcess := Processor activeProcess.
+ myPriority := myProcess priority.
+ myProcess priority:(Processor userBackgroundPriority).
- [
- |codeView lines|
+ [
+ |codeView lines|
- codeView := subView.
+ codeView := subView.
- replace ifTrue:[
- codeView list:nil.
- lnr := 1.
- ].
+ replace ifTrue:[
+ codeView list:nil.
+ lnr := 1.
+ ].
- [stream atEnd] whileFalse:[
- (stream readWaitWithTimeoutMs:250) ifFalse:[
- "
- data available
- "
- lines := OrderedCollection new:50.
- line := stream nextLine.
- line notNil ifTrue:[lines add:line].
+ [stream atEnd] whileFalse:[
+ (stream readWaitWithTimeoutMs:250) ifFalse:[
+ "
+ data available
+ "
+ lines := OrderedCollection new:50.
+ line := stream nextLine.
+ line notNil ifTrue:[lines add:line].
- [stream atEnd not
- and:[stream canReadWithoutBlocking
- and:[lines size < 50]]] whileTrue:[
- line := stream nextLine.
- line notNil ifTrue:[lines add:line].
- ].
+ [stream atEnd not
+ and:[stream canReadWithoutBlocking
+ and:[lines size < 50]]] whileTrue:[
+ line := stream nextLine.
+ line notNil ifTrue:[lines add:line].
+ ].
- "
- need this critical section; otherwise,
- we could get the signal while waiting for
- an expose event ...
- "
- access critical:[
- lines size > 0 ifTrue:[
- replace ifTrue:[
- lines do:[:line |
- codeView at:lnr put:line withTabsExpanded.
- codeView cursorToBottom; cursorDown.
- lnr := lnr + 1.
- ].
- ] ifFalse:[
+ "
+ need this critical section; otherwise,
+ we could get the signal while waiting for
+ an expose event ...
+ "
+ access critical:[
+ lines size > 0 ifTrue:[
+ replace ifTrue:[
+ lines do:[:line |
+ codeView at:lnr put:line withTabsExpanded.
+ codeView cursorToBottom; cursorDown.
+ lnr := lnr + 1.
+ ].
+ ] ifFalse:[
codeView insertLines:lines before:codeView cursorLine.
codeView cursorDown:lines size.
"/ lines do:[:line |
@@ -1486,68 +1487,68 @@
"/ ]
"/ codeView insertStringAtCursor:line.
"/ codeView insertCharAtCursor:(Character cr).
- ]
- ].
- ].
- ].
+ ]
+ ].
+ ].
+ ].
- shown ifTrue:[windowGroup processExposeEvents].
- "
- give others running at same prio a chance too
- (especially other FileBrowsers doing the same)
- "
- Processor yield
- ].
- ] valueNowOrOnUnwindDo:[
- stream close. stream := nil.
- ].
- self updateCurrentDirectory
- ].
- replace ifTrue:[
- subView modified:false.
- ].
- ]
+ shown ifTrue:[windowGroup processExposeEvents].
+ "
+ give others running at same prio a chance too
+ (especially other FileBrowsers doing the same)
+ "
+ Processor yield
+ ].
+ ] valueNowOrOnUnwindDo:[
+ stream close. stream := nil.
+ ].
+ self updateCurrentDirectory
+ ].
+ replace ifTrue:[
+ subView modified:false.
+ ].
+ ]
]
] valueNowOrOnUnwindDo:[
- |wg|
+ |wg|
- self label:myName; iconLabel:myName.
- myProcess notNil ifTrue:[myProcess priority:myPriority].
+ self label:myName; iconLabel:myName.
+ myProcess notNil ifTrue:[myProcess priority:myPriority].
- "
- remove the killButton from its group
- (otherwise, it will be destroyed when we shut down the group)
- "
- wg := killButton windowGroup.
- killButton windowGroup:nil.
- "
- shut down the windowgroup
- "
- wg notNil ifTrue:[
- wg process terminate.
- ].
- "
- hide the button, and make sure it will stay
- hidden when we are realized again
- "
- killButton unrealize.
- killButton hiddenOnRealize:true.
- "
- clear its action (actually not needed, but
- releases reference to thisContext earlier)
- "
- killButton action:nil.
+ "
+ remove the killButton from its group
+ (otherwise, it will be destroyed when we shut down the group)
+ "
+ wg := killButton windowGroup.
+ killButton windowGroup:nil.
+ "
+ shut down the windowgroup
+ "
+ wg notNil ifTrue:[
+ wg process terminate.
+ ].
+ "
+ hide the button, and make sure it will stay
+ hidden when we are realized again
+ "
+ killButton beInvisible.
+ "
+ clear its action (actually not needed, but
+ releases reference to thisContext earlier)
+ "
+ killButton action:nil.
].
currentFileName isNil ifTrue:[
- subView modified:false.
+ subView modified:false.
].
subView size > 10000 ifTrue:[
- self warn:'text quite large now - please cut off some lines'
+ self warn:'text quite large now - please cut off some lines'
]
"Modified: 21.9.1995 / 11:18:46 / claus"
+ "Modified: 17.1.1996 / 11:45:49 / cg"
!
doFileGet
@@ -2370,4 +2371,4 @@
!FileBrowser class methodsFor:'documentation'!
version
-^ '$Header: /cvs/stx/stx/libtool/FileBrowser.st,v 1.65 1995-12-17 14:47:14 cg Exp $'! !
+^ '$Header: /cvs/stx/stx/libtool/FileBrowser.st,v 1.66 1996-01-17 10:52:58 cg Exp $'! !