WACollectionTag>>isSelected:

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

WACollectionTag>>isSelected:

Damien Cassou-3
Hi,

here is the current #isSelected: code from WACollectionTag:

isSelected: anObject
  ^ self isMultiple
   ifTrue: [ selected includes: anObject ]
   ifFalse: [ selected = anObject ].

If the user did not have selected anything (nor the programmer have
choosen a default selection), this method will call #includes: on
UndefinedObject.

You may want to verify selected is not nil before sending it #includes:.

Bye

--
Damien Cassou
_______________________________________________
Seaside mailing list
[hidden email]
http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside