--- a/DialogBox.st Tue Aug 19 18:44:04 2003 +0200
+++ b/DialogBox.st Tue Aug 19 19:13:05 2003 +0200
@@ -1500,6 +1500,23 @@
"Modified: 8.3.1996 / 21:15:06 / cg"
!
+confirmOKCancel:aString
+ "launch a Dialog, which allows user to enter OK or Cancel.
+ return true for OK, false for Cancel."
+
+ |resources|
+
+ resources := self classResources.
+ ^ self
+ confirm:aString
+ yesLabel:(resources string:'OK')
+ noLabel:(resources string:'Cancel')
+
+ "
+ Dialog confirmOKCancel:'really ?'
+ "
+!
+
confirmWithCancel:aString
"launch a Dialog, which allows user to enter yes, no and cancel.
return true for 'yes', false for 'no', nil for 'cancel'"
@@ -1526,8 +1543,11 @@
^ self
confirmWithCancel:aString
- labels:(self classResources array:#('Cancel' 'No' 'Yes') )
- default:(#(nil false true) indexOf:default ifAbsent:nil)
+ labels:(self classResources array:#('Cancel' 'No' 'Yes') )
+ values:#(nil false true)
+ default:(#(nil false true) indexOf:default ifAbsent:nil)
+ boxLabel:nil
+
"
Dialog confirmWithCancel:'really ?' default:false
Dialog confirmWithCancel:'really ?' default:true
@@ -7815,7 +7835,7 @@
!DialogBox class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libwidg/DialogBox.st,v 1.221 2003-08-19 16:44:04 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libwidg/DialogBox.st,v 1.222 2003-08-19 17:13:05 cg Exp $'
! !
DialogBox initialize!