Bug 19361 - ClassCastException performing gotoline
Summary: ClassCastException performing gotoline
Status: RESOLVED FIXED
Alias: None
Product: PDE
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 2.0   Edit
Hardware: PC All
: P4 normal (vote)
Target Milestone: 3.0 M9   Edit
Assignee: Wassim Melhem CLA
QA Contact:
URL:
Whiteboard:
Keywords: readme
Depends on:
Blocks:
 
Reported: 2002-06-05 12:09 EDT by Randy Giffen CLA
Modified: 2004-05-03 03:40 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Randy Giffen CLA 2002-06-05 12:09:08 EDT
F2

1) Open a plugin.xml file
2) Goto the source tab
3) Edit>Go to Line
4) Enter a valid line number
5) You get an error dialog saying "An error has occured when activating this view" 
6) The following is in the log, note that the other retarget actions (find, etc.
work ok)

!MESSAGE Problems occurred when invoking code from plug-in: "org.eclipse.ui".
!STACK 0
java.lang.ClassCastException:
org.eclipse.pde.internal.ui.editor.manifest.ManifestSourcePage
	at
org.eclipse.pde.internal.ui.editor.PDEEditorContributor.setActiveEditor(PDEEditorContributor.java:209)
	at org.eclipse.ui.internal.EditorActionBars.partChanged(EditorActionBars.java:121)
	at org.eclipse.ui.internal.WorkbenchPage$2.run(WorkbenchPage.java:349)
	at
org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java(Compiled
Code))
	at org.eclipse.core.runtime.Platform.run(Platform.java(Compiled Code))
	at org.eclipse.ui.internal.WorkbenchPage.activatePart(WorkbenchPage.java:341)
	at org.eclipse.ui.internal.WorkbenchPage.setActivePart(WorkbenchPage.java:2028)
	at org.eclipse.ui.internal.WorkbenchPage.activate(WorkbenchPage.java:330)
	at org.eclipse.ui.texteditor.GotoLineAction.gotoLine(GotoLineAction.java:135)
	at org.eclipse.ui.texteditor.GotoLineAction.run(GotoLineAction.java:170)
	at
org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:127)
	at org.eclipse.jface.action.Action.runWithEvent(Action.java:749)
	at
org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:407)
	at
org.eclipse.jface.action.ActionContributionItem.handleWidgetEvent(ActionContributionItem.java(Compiled
Code))
	at
org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent(ActionContributionItem.java(Compiled
Code))
	at
org.eclipse.jface.action.ActionContributionItem$ActionListener.handleEvent(ActionContributionItem.java(Compiled
Code))
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java(Compiled Code))
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Compiled Code))
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java(Compiled Code))
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java(Compiled Code))
	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java(Compiled Code))
	at org.eclipse.ui.internal.Workbench.run(Workbench.java:1160)
	at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:739)
	at org.eclipse.core.boot.BootLoader.run(BootLoader.java:462)
	at java.lang.reflect.Method.invoke(Native Method)
	at org.eclipse.core.launcher.Main.basicRun(Main.java:244)
	at org.eclipse.core.launcher.Main.run(Main.java:693)
	at org.eclipse.core.launcher.Main.main(Main.java:526)
Comment 1 Dejan Glozic CLA 2002-06-06 22:08:24 EDT
ClassCastException fixed (GoToLineAction thinks that the source page is 
actually a standalone editor but ManifestEditor begs to differ :-).

There is still a problem of grayed-out outline view (which is empty anyway) but 
we will handle that post-2.0.
Comment 2 Randy Giffen CLA 2002-06-13 11:16:05 EDT
F3 XP

Gotoline works but it causes the outline to dissappear.
Comment 3 Dejan Glozic CLA 2003-01-24 11:25:31 EST
Kai, here is another example where text support has a dependency on the text 
editor being the root (simple), as opposed to being a page of the multi-page 
editor.
Comment 4 Wassim Melhem CLA 2004-05-03 03:40:20 EDT
Fixed in the new editor.