[Seaside] Can I do this with a select list?

Keith Hodges keith_hodges at yahoo.co.uk
Fri Oct 6 05:52:15 UTC 2006


have a look in the image for users of #select and see how they do it.
I think that what you are looking for is #labels:

I found this example from Magritte which I have loaded in my image.

renderEditorSelectedOn: html
    html select
        attributes: self attributes;
        size: 6; style: 'width: 150px';
        list: self selectedList;
        selected: self selectedSelected;
        callback: [ :value | self selectedSelected: value ];
        labels: [ :value | self description toString: value ]

also this example from WAConfigurationEditor

visitBooleanAttribute: anAttribute with: html
    html select
        list: (Array with: true with: false);
        selected: (configuration valueForAttribute: anAttribute);
        callback: [:v | configuration takeValue: v forAttribute: 
        labels: [ :b | b ifTrue: [ 'true' ] ifFalse: [ 'false' ] ]

best regards


All new Yahoo! Mail "The new Interface is stunning in its simplicity and ease of use." - PC Magazine 

More information about the Seaside mailing list