Eclipse Community Forums - RDF feed
https://www.eclipse.org/forums/
Eclipse Community ForumsWhat should I do to bind CheckboxTreeViewer to my list model?
https://www.eclipse.org/forums/index.php/mv/msg/175274/558412/#msg_558412
ViewersObservables.observeCheckedElements(...)
to get observable set of a CheckboxTreeViewer and bind it to my underlying model. However, the data in my model is a List not a Set.
say, myModel.getCities() returns a List object.
And,
bindingContext.bindSet( checkedObjTypes, new ListToSetAdapter( list ) );
seems not work.
So, what am I suppose to do to realize it? Thanks.]]>Frank2010-09-12T14:45:20-00:00Re: What should I do to bind CheckboxTreeViewer to my list model?
https://www.eclipse.org/forums/index.php/mv/msg/175274/558427/#msg_558427
snippet we can use to reproduce your problem?
Tom
Am 12.09.10 16:45, schrieb Frank:
> Hello, I'm going to use
> ViewersObservables.observeCheckedElements(...)
>
> to get observable set of a CheckboxTreeViewer and bind it to my
> underlying model. However, the data in my model is a List not a Set.
>
> say, myModel.getCities() returns a List object.
>
> And,
> bindingContext.bindSet( checkedObjTypes, new ListToSetAdapter( list ) );
>
> seems not work.
>
> So, what am I suppose to do to realize it? Thanks.]]>Thomas Schindl2010-09-12T18:47:54-00:00Re: What should I do to bind CheckboxTreeViewer to my list model?
https://www.eclipse.org/forums/index.php/mv/msg/175274/558484/#msg_558484
I found the real reason it does't wok is that there are more than one object type in my tree viewer. (content provider returns various typed children)
I want to bind the checked item of specified object type in the tree viewer to my underlying model.