AdapterFactoryTreeEditor or IUpdateableItemText not notifying editor of change [message #417475] |
Wed, 12 March 2008 10:37  |
Eclipse User |
|
|
|
I'm trying to use the AdapterFactoryTreeEditor to change the names of
items in my tree.
I've got as far as implementing the IUpdateableItemText in my ItemProvider
(together with adding IUpdateableItemText to the supportedTypes in my
ItemProviderAdapterFactory).
Whilst I can now edit the names in the tree, the editor doesn't seem to be
notified of any change, so the save menu item isn't enabled (the save As
menu item is enabled however).
Does anyone know if there's something else I need to add/change?
|
|
|
|
|
Re: AdapterFactoryTreeEditor or IUpdateableItemText not notifying editor of chan [message #417499 is a reply to message #417490] |
Thu, 13 March 2008 08:26  |
Eclipse User |
|
|
|
Gemma,
Yes, if you are going through a property descriptor's implementation, it
should properly construct a command and execute it.
Gemma Bowers wrote:
> Hi Ed,
>
> After some further investigation I think I might have found the problem.
> Previously in my setText method (in my ItemProvider) I was doing
> something like:
> public void setText(Object object, String text) {
> object.setName(text);
> }
> whereas I've now changed it to:
> public void setText(Object object, String text) {
> setPropertyValue(object, "Name", text);
> }
> Am I right in that by doing this I'm triggering the necessary command
> you mentioned?
>
|
|
|
Powered by
FUDForum. Page generated in 0.04869 seconds