Skip to main content



      Home
Home » Eclipse Projects » Eclipse Platform » Selection is null when property view is modified
Selection is null when property view is modified [message #286684] Tue, 14 June 2005 17:05
Eclipse UserFriend
Originally posted by: bencomo.us.ibm.com

Hi,

I've created a ViewPart that contains a TreeViewer which is displaying the
contents of my EMF model. I have set the viewer as a Selection provider as
well as added it to listen for selectionChanged. When I navigate the tree,
I can see that the property view displays the attributes for the element
selected. However, when I click on the property view to modify an
attribute, my view gets an selectionChanged event where the part is the
PropertySheet, but the selection is NULL.

I have poked around in PropertySheet, PropertySheetPage and it seems that
there is not a way to obtain what the property sheet page is considering
its selection at that moment. If that is true, then how can I find out
what the property sheet page is displaying?

Ed Merks, from the EMF team, suggested use the code attached in Bug 84119
to access the control with getControl and cast it to a PropertySheetViewer
which has a getSelection. However, I agree with Ed that this situation
doesn't seem right that the selection should be null if there's something
selected. Please let me know if you guys have any other suggestion.

Thank you in advance,
Al.-
Previous Topic:Unit testing SWT plugin
Next Topic:SWT/JFace: "no swt-win32-3064 in java.library.path" driving me nuts...
Goto Forum:
  


Current Time: Sat May 10 08:27:59 EDT 2025

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

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

Back to the top