Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » Notifications between two table viewers
Notifications between two table viewers [message #509587] Sat, 23 January 2010 11:46 Go to next message
Timothy Marc is currently offline Timothy MarcFriend
Messages: 547
Registered: July 2009
Senior Member
Hi all,

it's a long time ago, since i've programmed with RCP UI elements the
last time. So, i think this is really a beginner's question, but
however, it took me half a working day with no success:

I have a ViewPage with two TableViewers inside. By selecting one element
in the first viewer, i want the second one to be notified, that the
selection has changed, to reset the input for the second one. Which
listeners must be registered by the second TableViewer and what kind of
notification must the first one fire?

Any hints will be appreciated and help me a) to make some progress and
b) to remind myself how communication between Viewers and ViewParts are
realized.

Thanks a lot in advance

Timothy
Re: Notifications between two table viewers [message #509624 is a reply to message #509587] Sat, 23 January 2010 13:32 Go to previous message
Christian is currently offline ChristianFriend
Messages: 72
Registered: July 2009
Member
Am 23.01.2010 12:46, schrieb Timothy Marc:
> Hi all,
>
> it's a long time ago, since i've programmed with RCP UI elements the
> last time. So, i think this is really a beginner's question, but
> however, it took me half a working day with no success:
>
> I have a ViewPage with two TableViewers inside. By selecting one element
> in the first viewer, i want the second one to be notified, that the
> selection has changed, to reset the input for the second one. Which
> listeners must be registered by the second TableViewer and what kind of
> notification must the first one fire?
>
> Any hints will be appreciated and help me a) to make some progress and
> b) to remind myself how communication between Viewers and ViewParts are
> realized.
>
> Thanks a lot in advance
>
> Timothy


to listen for selections use a selection changed listener:
tableViewera.addPostSelectionChangedListener(listener)

In this listener take the selection and set the input in the second
appropriately..

By your description I see no need for any kind of selection listening
that needs to be done in the second viewer... therefore no listener there.

Christian
Previous Topic:[Mac] Refreshing window does not work well after resize or maximize
Next Topic:Nominate for Best RCP Application by Jan. 29
Goto Forum:
  


Current Time: Fri Nov 21 08:36:09 GMT 2014

Powered by FUDForum. Page generated in 0.02953 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software