Community
Participate
Working Groups
Build Identifier: 3.6.1 with latest swtbot from update site SWTBotEclipseEditor provides neat ways of invoking Quick Assists and Auto completion. This works well for normal editors implementing ITextEditor. But it fails when the editor is instance 'MultiPageEditor' with 2 or more ITextEditors in it. Reproducible: Always Steps to Reproduce: 1. Using SWTBot open an editor which extends MultipageEditor 2. Get the SWTBotEcliseEditor and execute editor.getQuickFixes(); 3. No output 4. Because of ClassCastException in SWTBotEclipseEditor#invokeAction (Since my editor is MultiPageEditor). Suggested solution(May be:) Can you make invokeAction method's access specifier to 'protected' so that I can extend and override and cast it to proper editor? type.
Could you please provide a stacktrace that points to the problem?
There is no stacktrace. The exception gets caught in quickFixAppears method. The problem is in the line --> "final IAction action = ((ITextEditor) partReference.getEditor(false)).getAction(actionId);" in invokeAction method of SWTBotEclipseEditor. partReference.getEditor(false) returns an instance of MultiPageEditor in my application which cannot be casted to ITextEditor. (ClassCastException when i debugged to that line) (In reply to comment #1) > Could you please provide a stacktrace that points to the problem?