Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » visibility feature doesnt change
visibility feature doesnt change [message #494659] Mon, 02 November 2009 00:08 Go to next message
spyro  is currently offline spyro Friend
Messages: 18
Registered: July 2009
Junior Member
Hello,
in some cases i need to hide some connections in my editor but i cant get it going...
i tried the following:

SetRequest setRequest = new SetRequest(getEditingDomain(), editPartView, NotationPackage.eINSTANCE.getView_Visible() , new Boolean(false));
this.getViewer().getEditDomain().getCommandStack().execute(n ew ICommandProxy(new SetValueCommand(setRequest)));


this seems correct to me but it still doesnt change the value of "visible:" to false.

any idea how can i deal with my issue?

help would be greatly appreciated!!
best regards,
spyro
Re: visibility feature doesnt change [message #495026 is a reply to message #494659] Tue, 03 November 2009 14:58 Go to previous messageGo to next message
Artur Kronenberg is currently offline Artur KronenbergFriend
Messages: 159
Registered: August 2009
Senior Member
Do you only need to hide connections or also the Editparts to that connections?

Because if you hide the nodes the connections in between or without source/target get hidden too.

Unfortunatelly I never tried your approach but I think I managed to hide connections (and edit Parts) like this:

new AbstractEmfOperation(editingDomain, title, options){

doExecute(monitor) {

//call getNotationView().setVisible(false)

}

}
However I only called this on connections that would have been hidden anyway, so I am not sure if this would hide ONLY connections without the according edit parts.

Artur
Re: visibility feature doesnt change [message #495161 is a reply to message #495026] Tue, 03 November 2009 23:04 Go to previous message
spyro  is currently offline spyro Friend
Messages: 18
Registered: July 2009
Junior Member
thank you for the reply Artur... my problem was that i could hide the nodes but then the connections were still there if either target or source node wasnt hidden. i fixed my error - i realized that i was asking the command stack to execute 2 concurrent commands which seems to be wrong.
i will try your way too .. is always good to have alternatives Smile

thank you and regards,
spyro
Previous Topic:Get in a figure event notifications from other figure
Next Topic:Problem with Custom Decorations in newer versions of GMF
Goto Forum:
  


Current Time: Fri Apr 26 09:29:56 GMT 2024

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

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

Back to the top