Closing and Opening an Editor [message #190215] |
Tue, 02 August 2005 21:31 |
Eclipse User |
|
|
|
Originally posted by: cleversons.gmail.com
Hi,
I'm having some problems after closing and re-open an editor on my
application.
The application has a open button which opens my editor by calling:
IDE.openEditor(PlatformUI.getWorkbench().getActiveWorkbenchW indow().getActivePage(),
MyInputEditor, MyEditor.ID);
And a close button which calls:
IEditorPart editor =
PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActi vePage().getActiveEditor();
PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActi vePage().closeEditor(editor,
false);
When the close button is pressed, the editor is closed as expected. But if
the user presses start again, the changes on the model do not take effect
in the editor anymore. It remains empty no matter how many changes are
made on the model.
Is there any kind of finalization I must do when closing the editor?
Thank you
|
|
|
Re: Closing and Opening an Editor [message #190396 is a reply to message #190215] |
Wed, 03 August 2005 18:04 |
Eclipse User |
|
|
|
Originally posted by: none.unknown.com
Sounds like you have a stale model in memory.
"Cleverson Schmidt" <cleversons@gmail.com> wrote in message
news:d7a06872070d861d1e2f3beff14a4a4e$1@www.eclipse.org...
> Hi,
>
> I'm having some problems after closing and re-open an editor on my
> application.
>
> The application has a open button which opens my editor by calling:
>
>
IDE.openEditor(PlatformUI.getWorkbench().getActiveWorkbenchW indow().getActiv
ePage(),
> MyInputEditor, MyEditor.ID);
>
> And a close button which calls:
>
> IEditorPart editor =
>
PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActi vePage().getActi
veEditor();
>
PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActi vePage().closeEd
itor(editor,
> false);
>
> When the close button is pressed, the editor is closed as expected. But if
> the user presses start again, the changes on the model do not take effect
> in the editor anymore. It remains empty no matter how many changes are
> made on the model.
>
> Is there any kind of finalization I must do when closing the editor?
>
> Thank you
>
|
|
|
Powered by
FUDForum. Page generated in 0.05191 seconds