|MultiPageEditor within a MultiPageEditor [message #997197]
||Fri, 04 January 2013 12:37
| Rohan Kapur
Registered: October 2010
I was using eclipse 3.5.2 and had created a MultiPageEditor. In a MultiPageEditor we can add another Editor as a page. This editor could be another MultiPageEditor. Now I have migrated to eclipse 4.2.0. Now when I open my MultiPageEditor I get a ClassCastException. On going through the source code I found the below piece of code in the constructor of MultiPageEditorSite which is called from the org.eclipse.ui.part.MultiPageEditorPart.addPage(IEditorPart editor, IEditorInput input)
method used to add the editor as a page.
PartSite site = (PartSite) multiPageEditor.getSite();
Since the editor that I am adding as a page in the MultiPageEditor the getSite returns an object which is an instance of the MultiPageEditorPart which is not of the type PartSite hence the exception is thrown.
Could someone please help me as to what could be used to open a MultiPageEditor as a page in another MultiPageEditor.
Thanks in anticipation of your help
Powered by FUDForum
. Page generated in 0.01913 seconds