any ListViews working with ValueHolders?

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

any ListViews working with ValueHolders?

Günther Schmidt
Hi,

are there any ListViews out there that make use of ValueAspectAdaptors
instead of getContentsBlocks?

Or rather where the getContentsBlock returns an ValueAspectAdaptor?

I know that a plain ListView will update itself when either the window
needs to be redrawn or when the underlying listModel has chaned.

But it won't update when a displayed aspect of an item in the list has
changed.

Has anybody here already written a list view this way?

Günther


Reply | Threaded
Open this post in threaded view
|

Re: any ListViews working with ValueHolders?

Schwab,Wilhelm K
Günther,

> are there any ListViews out there that make use of ValueAspectAdaptors
> instead of getContentsBlocks?
>
> Or rather where the getContentsBlock returns an ValueAspectAdaptor?
>
> I know that a plain ListView will update itself when either the window
> needs to be redrawn or when the underlying listModel has chaned.
>
> But it won't update when a displayed aspect of an item in the list has
> changed.

It might be as simple as observing #valueChanged from the adapter and
calling #updateItem: from the handler.  In fact,
#when:send:to:withArguments: might let you do it all inside the event
system.

If it sounds reasonable to you, make a backup and give it a try =:0

Have a good one,

Bill


Reply | Threaded
Open this post in threaded view
|

Re: any ListViews working with ValueHolders?

Günther Schmidt
Hi Bill,

Today I made my first successful attempt of altering the behaviour of
the list view.

It actually worked, I can't believe it!

A column now does update automatically when an items aspect changes!

Aaaaahhhhh!

Günther