In Eclipse RCP, I am creating views for the Perspective using IPageLayout.addView(...)
But this way I don’t have a reference to the view. Therefore I don’t know how I can tell ViewA to update ViewB.
What’s the best pattern to use here?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Besides what VonC has mentioned above, you can also use
ISourceProviderListenerif the changes you need are not triggered by selection.ViewBimplementsISourceProviderListenerISourceProviderand register it in the servicesViewAget theISourceProviderand update it to trigger the changes inViewBRead the documentation on those interfaces along with
IServiceLocatorandISourceProviderServiceto get better idea how it all plays out.You can also see this Lars Vogel’s tutorial which has some example how to use the
ISourceProvider