[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.tools.jdt] Current ActivePage.findEditor(IEditorInput input) triggered SafeRunner

Hi all,

Here's my code to find the current editor for the file:
IEditorPart editor = MyPlugin.getActiveWorkbenchWindow().getActivePage().findEditor(new FileEditorInput(file));


When the file is open in an editor which is activated and focused, it will return the IEditorPart. But if the file is open in an editor while the editor is not activated in the current active page, it will trigger the SafeRunner class.

I need to get the IEditorPart even if the open editor is not activated as long as the file is open in it. Can some one point me the way to work around this?

Thanks.
Jing