Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » GEF » how to response model elements relation changes
how to response model elements relation changes [message #178656] Thu, 21 April 2005 07:45 Go to next message
memorialday is currently offline memorialdayFriend
Messages: 37
Registered: July 2009
Member
here is an example:

editpartA(figureA) ->modelelementA
editpartB(figureB) ->modelelementB
modelelementA and modelelementB are the same level emelents

how should editparts response when elementA becomes a child of elementB
(dragging figure into figureB)?

should i give up the old editparts and recreate all the editparts again?
if it's not the right way, how should i do?
Re: how to response model elements relation changes [message #178769 is a reply to message #178656] Thu, 21 April 2005 21:02 Go to previous message
Pratik Shah is currently offline Pratik ShahFriend
Messages: 1077
Registered: July 2009
Senior Member
You don't have to worry about creating/disposing editparts. When modelB
becomes a child of modelA, modelA should fire a notification. editPartA,
when it gets notified of this, should call refreshChildren(). If you've
properly implemented editPartA's getModelChildren() method, everything
should just work for you.

"unknown" <iunknown918@hotmail.com> wrote in message
news:fd0a0e512393dd587ae82868abbd3394$1@www.eclipse.org...
> here is an example:
>
> editpartA(figureA) ->modelelementA
> editpartB(figureB) ->modelelementB
> modelelementA and modelelementB are the same level emelents
>
> how should editparts response when elementA becomes a child of elementB
> (dragging figure into figureB)?
>
> should i give up the old editparts and recreate all the editparts again?
> if it's not the right way, how should i do?
>
>
>
>
Previous Topic:How to update the name of a GraphicalEditor ?
Next Topic:Initializing the viewport scroll to location in a scrollable compartment
Goto Forum:
  


Current Time: Thu Mar 28 20:16:08 GMT 2024

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

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

Back to the top