--- a/Toggle.st Fri Dec 14 11:55:56 2001 +0100
+++ b/Toggle.st Fri Dec 14 11:57:30 2001 +0100
@@ -10,6 +10,8 @@
hereby transferred.
"
+"{ Package: 'stx:libwidg' }"
+
Button subclass:#Toggle
instanceVariableNames:'showLamp lampColor lampWidth lampHeight'
classVariableNames:'DefaultShowLamp DefaultLampColor LampInset'
@@ -528,15 +530,7 @@
|val|
(model notNil and:[aspectMsg notNil]) ifTrue:[
- aspectMsg == #value ifTrue:[
- val := model value
- ] ifFalse:[
- aspectMsg numArgs == 0 ifTrue:[
- val := model perform:aspectMsg
- ] ifFalse:[
- val := model perform:aspectMsg with:self
- ].
- ].
+ val := model perform:aspectMsg withOptionalArgument:self.
val == true ifTrue:[ "allowing nil - treat as false"
self turnOn
] ifFalse:[
@@ -634,5 +628,5 @@
!Toggle class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libwidg/Toggle.st,v 1.47 2000-03-01 14:11:45 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libwidg/Toggle.st,v 1.48 2001-12-14 10:57:11 cg Exp $'
! !