DialogBox.st
changeset 3357 f00242a1c6cd
parent 3355 abe6b60871f2
child 3382 deb5b2cfea1a
equal deleted inserted replaced
3356:4a1ab6d0be69 3357:f00242a1c6cd
  1472 
  1472 
  1473     aBoolean ifTrue:[
  1473     aBoolean ifTrue:[
  1474         ^ Dialog confirmWithCancel:msg.
  1474         ^ Dialog confirmWithCancel:msg.
  1475     ] ifFalse:[
  1475     ] ifFalse:[
  1476         ^ Dialog confirm:msg.
  1476         ^ Dialog confirm:msg.
       
  1477     ].
       
  1478 
       
  1479     "
       
  1480      Dialog confirm:'really ?' withCancel:false 
       
  1481      Dialog confirm:'really ?' withCancel:true 
       
  1482     "
       
  1483 !
       
  1484 
       
  1485 confirm:msg withCancel:aBoolean default:default
       
  1486     "launch a Dialog, which allows user to enter yes, no and optionally: cancel.
       
  1487      return true for 'yes', false for 'no', nil for 'cancel'"
       
  1488 
       
  1489     aBoolean ifTrue:[
       
  1490         ^ Dialog confirmWithCancel:msg default:default.
       
  1491     ] ifFalse:[
       
  1492         ^ Dialog confirm:msg default:default.
  1477     ].
  1493     ].
  1478 
  1494 
  1479     "
  1495     "
  1480      Dialog confirm:'really ?' withCancel:false 
  1496      Dialog confirm:'really ?' withCancel:false 
  1481      Dialog confirm:'really ?' withCancel:true 
  1497      Dialog confirm:'really ?' withCancel:true 
  8210 ! !
  8226 ! !
  8211 
  8227 
  8212 !DialogBox class methodsFor:'documentation'!
  8228 !DialogBox class methodsFor:'documentation'!
  8213 
  8229 
  8214 version
  8230 version
  8215     ^ '$Header: /cvs/stx/stx/libwidg/DialogBox.st,v 1.250 2006-08-24 09:24:44 cg Exp $'
  8231     ^ '$Header: /cvs/stx/stx/libwidg/DialogBox.st,v 1.251 2006-08-24 09:36:16 cg Exp $'
  8216 ! !
  8232 ! !
  8217 
  8233 
  8218 DialogBox initialize!
  8234 DialogBox initialize!