hi glenn

were are you located?
Because if you are around lille you should come to hack with us :)

Stef
On 05 Feb 2014, at 11:54, Glenn Cavarlé <gl...@cavarle.fr> wrote:

> Hi,
> I have looked at the TreeModel class and it's not exactly that i seek.
> The idea is rather something like that :
> 
> MyListModel>>initializeWidgets
>    title := self newLabel.
>    manager := self newListManager.
>    manager model:#MyDummyItemModel
> 
> MyListModel class>>defaultSpec
>    ^SpecLayout composed
>        newColumn:[:mainCol|
>            mainCol add: #title;
>                        add: #manager
>        ];
>        yourself
> 
> MyDummyItemModel>>initializeWidgets
>    image := self newImage.
>    address := self newLabel.
>    zipCode := self newLabel.
>    city := self newLabel.
>    editBtn := self newButton.
>    delBtn := self newButton.
> 
> MyDummyItemModel class>>defaultSpec:
>    ^SpecLayout composed
>        newRow:[:mainRow|
>            mainRow add: #image;
>                    newColumn:[:addrCol|
>                        addrCol add: #address;
>                                   add: #zipCode;
>                                   add: #city
>                    ];
>                    newColumn:[:btnCol|
>                        btnCol add: #editBtn;
>                                  add: #delBtn
>                    ];   
>        ];
>        yourself
> 
> 
> mlm := MyListModel new.
> mlm openWithSpec.
> mlm title value: 'I am a list'.
> mlm manager items: aCollectionOfDummyObjects 
> 
> 
> it seem there isn't such implementation in Spec.
> What would be the best way to implement it (if it's possible)? a mix between
> ListModel and TabManager ?
> 
> Regards,
> Glenn
> 
> 
> 
> -----
> Glenn Cavarlé
> --
> View this message in context: 
> http://forum.world.st/Spec-question-tp4741608p4741681.html
> Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
> 


Reply via email to