Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » How to stop closing a perspective ???
How to stop closing a perspective ??? [message #48351] Mon, 26 May 2003 15:22 Go to next message
Xavi Alcalde is currently offline Xavi AlcaldeFriend
Messages: 3
Registered: July 2009
Junior Member
We are developing a perspective that contains some views and an editor. We
need to give that perspective of such a behavior that allows the user to
stop the closing of the perspective once it has been triggered is
something wrong happens.

Perspective closing routines evaluate whether the editor is dirty or not
and will show the user a dialog offering the chance to save the content or
quit the closing. The user can choose between saving content (if needed) &
close or cancel that.

If you choose to save the content of the editor, and something strange
happens (say, commit of data to a DB fails), it seems to us that you
CANNOT stop the closing of the view. We need to give the user the chance
to make some changes on the content and then be able to safely exit the
perspective.

Dispose allows us to do things before closing is complete, but it seems
like closing is definitive, no further possibility to stop it if there's a
big problem there...

Can anyone give us a hint on how to fix this ??? Do we need to listen to a
particular event before dispose() is called ???

Thanks in advance...

Greetins from Barcelona,

XAVI
Re: How to stop closing a perspective ??? [message #48381 is a reply to message #48351] Mon, 26 May 2003 16:15 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: simon.ibm.oti.lab

That bug has been fixed in the latest integration builds.

Simon :-)

"Xavi Alcalde" <xavi.alcalde@es.ibm.com> wrote in message
news:batbfo$8u9$1@rogue.oti.com...
> We are developing a perspective that contains some views and an editor. We
> need to give that perspective of such a behavior that allows the user to
> stop the closing of the perspective once it has been triggered is
> something wrong happens.
>
> Perspective closing routines evaluate whether the editor is dirty or not
> and will show the user a dialog offering the chance to save the content or
> quit the closing. The user can choose between saving content (if needed) &
> close or cancel that.
>
> If you choose to save the content of the editor, and something strange
> happens (say, commit of data to a DB fails), it seems to us that you
> CANNOT stop the closing of the view. We need to give the user the chance
> to make some changes on the content and then be able to safely exit the
> perspective.
>
> Dispose allows us to do things before closing is complete, but it seems
> like closing is definitive, no further possibility to stop it if there's a
> big problem there...
>
> Can anyone give us a hint on how to fix this ??? Do we need to listen to a
> particular event before dispose() is called ???
>
> Thanks in advance...
>
> Greetins from Barcelona,
>
> XAVI
>
>
>
Re: How to stop closing a perspective ??? [message #310503 is a reply to message #48351] Wed, 06 December 2006 10:15 Go to previous message
Eclipse UserFriend
Originally posted by: eclipse.ahoegger.ch

Probably it helps someone in future:

PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActi vePage().closePerspective(IPerspectiveDesctription,
true, false);


Xavi Alcalde wrote:
> We are developing a perspective that contains some views and an editor. We
> need to give that perspective of such a behavior that allows the user to
> stop the closing of the perspective once it has been triggered is
> something wrong happens.
>
> Perspective closing routines evaluate whether the editor is dirty or not
> and will show the user a dialog offering the chance to save the content or
> quit the closing. The user can choose between saving content (if needed) &
> close or cancel that.
>
> If you choose to save the content of the editor, and something strange
> happens (say, commit of data to a DB fails), it seems to us that you
> CANNOT stop the closing of the view. We need to give the user the chance
> to make some changes on the content and then be able to safely exit the
> perspective.
>
> Dispose allows us to do things before closing is complete, but it seems
> like closing is definitive, no further possibility to stop it if there's a
> big problem there...
>
> Can anyone give us a hint on how to fix this ??? Do we need to listen to a
> particular event before dispose() is called ???
>
> Thanks in advance...
>
> Greetins from Barcelona,
>
> XAVI
>
>
>
Previous Topic:How to get existing projects which are synchronized
Next Topic:Proxy problem StandaloneUpdate?
Goto Forum:
  


Current Time: Sat Nov 09 03:39:32 GMT 2024

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

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

Back to the top