ModelingAssistantProvider problem [message #81700] |
Wed, 29 November 2006 09:46  |
Eclipse User |
|
|
|
Originally posted by: zuegg.hotmail.it
Hi,
I've a problem with my ModelAssistantProvider: I have changed the
getTypesForTarget method to add the entries for my EditParts, and this
works fine, but when I create the connection with a new part, it creates
2 instance of that part, one connected and one not. I have no idea where
to start debugging, hope someone help me
Thanks,
M.
|
|
|
Re: ModelingAssistantProvider problem [message #81774 is a reply to message #81700] |
Wed, 29 November 2006 14:05   |
Eclipse User |
|
|
|
M,
As long as you are using the same types that would also work when using
creation tools from the palette, this should work as is.
I would suggest you add a breakpoint to
CreateViewAndOptionallyElementCommand.doExecuteWithResult(). This is
the command that should create the view and new element for your target.
When this breakpoint is hit you can also add one to the constructor
in CreateCommand. This is the command to create the view. You should
only get one CreateCommand constructed to create the view for your
target. I am guessing you will get two and you might be able to figure
out why from here.
Good luck!
- Cherie
d3K4!n wrote:
> Hi,
> I've a problem with my ModelAssistantProvider: I have changed the
> getTypesForTarget method to add the entries for my EditParts, and this
> works fine, but when I create the connection with a new part, it creates
> 2 instance of that part, one connected and one not. I have no idea where
> to start debugging, hope someone help me
>
> Thanks,
> M.
|
|
|
Re: ModelingAssistantProvider problem [message #82567 is a reply to message #81700] |
Mon, 04 December 2006 11:06  |
Eclipse User |
|
|
|
Hello d3K4!n,
It looks like a probles with generated ??CanonicalEditPolicy. I suppose that
second element (not connected one) will be created by it. You can check it
debugging generated ??CanonicalEditPolicy for the contaner of newly created
element.
-----------------
Alex Shatalin
|
|
|
Powered by
FUDForum. Page generated in 0.03753 seconds