--- a/WorkspaceApplication.st Tue Feb 25 13:37:28 2003 +0100
+++ b/WorkspaceApplication.st Tue Feb 25 15:43:00 2003 +0100
@@ -1087,7 +1087,7 @@
(self askIfModified:'Text was modified. Load anyway ?' yesButton:'Load') ifFalse:[ ^ self].
- file := Dialog requestFileName:'Load file:' default:'file.wsp' pattern:'*.wsp'.
+ file := Dialog requestFileName:'Load file' default:'file.wsp' pattern:'*.wsp'.
file size > 0 ifTrue:[
self loadFile:file
]
@@ -1441,22 +1441,28 @@
!WorkspaceApplication methodsFor:'private'!
askForFile:question thenDo:aBlock
- |file doAppend|
-
- doAppend := false.
- Dialog aboutToOpenBoxNotificationSignal handle:[:n |
- |box|
+ Dialog
+ requestSaveFileName:(resources string:question)
+ default:'file.wsp'
+ fromDirectory:nil
+ action:[:fileName | aBlock value:fileName value:false]
+ appendAction:[:fileName | aBlock value:fileName value:true]
- box := n parameter.
- box addButton:(Button label:'Append'
- action:[doAppend := true. box okPressed]).
- n proceed.
- ] do:[
- file := Dialog requestFileName:question default:'file.wsp'.
- ].
- file isEmptyOrNil ifFalse:[
- aBlock value:file value:doAppend
- ].
+"/ |file doAppend|
+"/
+"/ doAppend := false.
+"/ Dialog aboutToOpenBoxNotificationSignal handle:[:n |
+"/ |box|
+"/
+"/ box := n parameter.
+"/ box addButton:(Button label:'Append' action:[doAppend := true. box okPressed]).
+"/ n proceed.
+"/ ] do:[
+"/ file := Dialog requestFileName:question default:'file.wsp'.
+"/ ].
+"/ file isEmptyOrNil ifFalse:[
+"/ aBlock value:file value:doAppend
+"/ ].
!
askIfAnyModified:question yesButton:yesButtonText
@@ -1564,5 +1570,5 @@
!WorkspaceApplication class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libtool/WorkspaceApplication.st,v 1.58 2003-02-21 10:23:17 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libtool/WorkspaceApplication.st,v 1.59 2003-02-25 14:43:00 cg Exp $'
! !