Login | Register
My pages Projects Community openCollabNet

Discussions > dev > RE: Deleting the underlying objet in the Net, with GEF

gef
Discussion topic

Back to topic list

RE: Deleting the underlying objet in the Net, with GEF

Reply

Author "Christensen, Blake" <Blake dot Christensen at dsionline dot com>
Full name "Christensen, Blake" <Blake dot Christensen at dsionline dot com>
Date 2003-02-26 11:55:04 PST
Message Sami,

I use CmdDispose.

I also extend NetNode with my own class that overrides the dispose method to act on my applications model.
My Diagram model extends MutableGraphSupport. I find the default implemenation is a bit sparse and doesn't do a strict model/view/controller separation.
My diagram model calls the old node dispose after the underlying application model is changed.

I know this is a bit sparse, but hopefully there are some hints here.

Blake

-----Original Message-----
From: Sami Dalouche [mailto:samokk at free dot fr]
Sent: Wednesday, February 26, 2003 11:32 AM
To: dev at argouml dot tigris dot org; dev at gef dot tigris dot org
Subject: Deleting the underlying objet in the Net, with GEF


Sorry for the previous post, I didn't want to send it as is.
Here's the full e-mail :

Hi everybody,

I contacted you recently concerning the use of several editors in GEF,
 and I got some interesting answers. Since I've encountered another
problem,
I'm asking for your help again.

I'm trying to use the model of the Editor, which contains some nodes.
The problem is that the CmdDelete command only deletes the graphical
(Figs)
part, And doesn't mind about the editor's graphModel at all.

I looked a bit at the misc. commands and it seems CmdDispose is what I'm
looking for.

    Editor ce = Globals.curEditor();
    SelectionManager sm = ce.getSelectionManager();
    sm.dispose();
    sm.deselectAll();

Sm.dispose() seems to be the way to go, so I looked at the code and it
led me to 3 conclusions
 1) dispose() is not meant to do what I need to
 2) my nodes have to implement the VetoableChangeEventSource interface.
 3) I have to find another way of doing the thing

1) doesn't seem correct, so only 2) and 3) fit.
But what's the VetoableChangeEventSource ? What does it mean, exactly ?
It seems there is no javadoc for this class.

If VetoableChange... Is not the way to go, how would I delete
the nodes from the model in a clean manner ?

Thanks for the help

Sam


--------------------​--------------------​--------------------​---------
To unsubscribe, e-mail: dev-unsubscribe at gef dot tigris dot org
For additional commands, e-mail: dev-help at gef dot tigris dot org


--------------------​--------------------​--------------------​---------
To unsubscribe, e-mail: dev-unsubscribe at gef dot tigris dot org
For additional commands, e-mail: dev-help at gef dot tigris dot org

« Previous message in topic | 1 of 2 | Next message in topic »

Messages

Show all messages in topic

RE: Deleting the underlying objet in the Net, with GEF "Christensen, Blake" <Blake dot Christensen at dsionline dot com> "Christensen, Blake" <Blake dot Christensen at dsionline dot com> 2003-02-26 11:55:04 PST
     RE: Deleting the underlying objet in the Net, with GEF ginkel Martin Ginkel 2003-02-26 14:05:13 PST
Messages per page: