REQ_DELETE [message #98756] |
Sat, 11 October 2003 18:54  |
Eclipse User |
|
|
|
Originally posted by: ThisisFake.Fakeness.xyz
The delete action creates the delete request and that request contains
nothing but the type RequestConstants.REQ_DELETE. This is passed into the
EditPart and onto the componentEditPolicy. This component editpolicy
passes the Request along to the getDeleteCommand method but it does not do
the same thing for the getOrphanCommand method which is void.
Why does delete pass along a request, casting it to a GroupRequest no
less, when that request is basically empty as orphan seems to understand?
I think this should be changed. Is their a new GEF out that has some
fixes in it or something? can I be part of the team that makes changes or
submits patches or something?
I understand what is happening now, and can feel my way around it (mainly
by overriding the edit part to pass around the events in a consistent
fashion). But I imagine such inconsistencies could be very hard on
newcomers, as they were on me.
Anyway I can help on this project?
CL
|
|
|
|
Re: REQ_DELETE [message #99188 is a reply to message #98979] |
Mon, 13 October 2003 06:28  |
Eclipse User |
|
|
|
Originally posted by: ThisisFake.Fakeness.xyz
The ORPHAN command is created and implemented by the application. So
every app will need one right?
My point was that ORPHAN and DELETE work the same way in GEF. So why are
they implemented differently. The last app I worked with, DELETE was the
final straw where you could release resources. in GEF, they are the same
though. You press DELETE, your part gets DELETED, but it could return
into existance at any time from an undo command.
I am looking for a method that is called maybe by the CommandStack when it
dumps its stacked commands, so it lets me know I can eliminate my part.
I'd hate to use finalize, besides, finalize only says the class is
destroyed, not necessarily not required anymore...
CL
On Sun, 12 Oct 2003 22:04:25 -0400, Randy Hudson wrote:
> Most applications don't need to do anything in response to ORPHAN.
> Generally, only the containers are involved. Delete is different. It is
> much more common that the item being deleted must contribute to the
> delete. We can add this method, but it could confuse new users who
> recognize they have to contribute commands to DELETE, but they don't
> understand what they should do for orphan.
>
|
|
|
Powered by
FUDForum. Page generated in 0.03094 seconds