issue_id
int64 2.04k
425k
| title
stringlengths 9
251
| body
stringlengths 4
32.8k
⌀ | status
stringclasses 6
values | after_fix_sha
stringlengths 7
7
| project_name
stringclasses 6
values | repo_url
stringclasses 6
values | repo_name
stringclasses 6
values | language
stringclasses 1
value | issue_url
null | before_fix_sha
null | pull_url
null | commit_datetime
timestamp[us, tz=UTC] | report_datetime
timestamp[us, tz=UTC] | updated_file
stringlengths 23
187
| chunk_content
stringlengths 1
22k
|
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
private static void addNatureToProject(IProject proj, String natureId, IProgressMonitor monitor) throws CoreException {
IProjectDescription description = proj.getDescription();
String[] prevNatures= description.getNatureIds();
String[] newNatures= new String[prevNatures.length + 1];
System.arraycopy(prevNatures, 0, newNatures, 0, prevNatures.length);
newNatures[prevNatures.length]= natureId;
description.setNatureIds(newNatures);
proj.setDescription(description, monitor);
}
private IContainer chooseContainer() {
Class[] acceptedClasses= new Class[] { IProject.class, IFolder.class };
ISelectionValidator validator= new TypedElementSelectionValidator(acceptedClasses, false);
IProject[] allProjects= fWorkspaceRoot.getProjects();
ArrayList rejectedElements= new ArrayList(allProjects.length);
IProject currProject= fCurrJProject.getProject();
for (int i= 0; i < allProjects.length; i++) {
if (!allProjects[i].equals(currProject)) {
rejectedElements.add(allProjects[i]);
}
}
ViewerFilter filter= new TypedViewerFilter(acceptedClasses, rejectedElements.toArray());
ILabelProvider lp= new WorkbenchLabelProvider();
ITreeContentProvider cp= new WorkbenchContentProvider();
IResource initSelection= null;
if (fOutputLocationPath != null) {
initSelection= fWorkspaceRoot.findMember(fOutputLocationPath);
}
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/BuildPathsBlock.java
|
ElementTreeSelectionDialog dialog= new ElementTreeSelectionDialog(getShell(), lp, cp);
dialog.setTitle(NewWizardMessages.getString("BuildPathsBlock.ChooseOutputFolderDialog.title"));
dialog.setValidator(validator);
dialog.setMessage(NewWizardMessages.getString("BuildPathsBlock.ChooseOutputFolderDialog.description"));
dialog.addFilter(filter);
dialog.setInput(fWorkspaceRoot);
dialog.setInitialSelection(initSelection);
if (dialog.open() == dialog.OK) {
return (IContainer)dialog.getFirstResult();
}
return null;
}
private void tabChanged(Widget widget) {
if (widget instanceof TabItem) {
BuildPathBasePage newPage= (BuildPathBasePage) ((TabItem) widget).getData();
if (fCurrPage != null) {
List selection= fCurrPage.getSelection();
if (!selection.isEmpty()) {
newPage.setSelection(selection);
}
}
fCurrPage= newPage;
}
}
}
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
/*
* (c) Copyright IBM Corp. 2000, 2001.
* All Rights Reserved.
*/
package org.eclipse.jdt.internal.ui.wizards.buildpaths;
import java.io.File;
import java.io.IOException;
import java.lang.reflect.InvocationTargetException;
import java.net.MalformedURLException;
import java.net.URL;
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
import java.util.ArrayList;
import java.util.zip.ZipFile;
import org.eclipse.core.resources.IFile;
import org.eclipse.core.resources.IResource;
import org.eclipse.core.resources.IWorkspaceRoot;
import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.Path;
import org.eclipse.swt.SWT;
import org.eclipse.swt.custom.CLabel;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.DirectoryDialog;
import org.eclipse.swt.widgets.FileDialog;
import org.eclipse.swt.widgets.Label;
import org.eclipse.swt.widgets.Shell;
import org.eclipse.jface.dialogs.MessageDialog;
import org.eclipse.jface.operation.IRunnableWithProgress;
import org.eclipse.jface.viewers.ILabelProvider;
import org.eclipse.jface.viewers.ITreeContentProvider;
import org.eclipse.jface.viewers.ViewerFilter;
import org.eclipse.ui.help.WorkbenchHelp;
import org.eclipse.ui.model.WorkbenchContentProvider;
import org.eclipse.ui.model.WorkbenchLabelProvider;
import org.eclipse.jdt.core.IClasspathEntry;
import org.eclipse.jdt.core.IJavaProject;
import org.eclipse.jdt.core.JavaCore;
import org.eclipse.jdt.core.JavaModelException;
import org.eclipse.jdt.internal.corext.javadoc.JavaDocLocations;
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
import org.eclipse.jdt.internal.ui.IJavaHelpContextIds;
import org.eclipse.jdt.internal.ui.JavaPlugin;
import org.eclipse.jdt.internal.ui.dialogs.ElementTreeSelectionDialog;
import org.eclipse.jdt.internal.ui.dialogs.ISelectionValidator;
import org.eclipse.jdt.internal.ui.dialogs.StatusInfo;
import org.eclipse.jdt.internal.ui.dialogs.StatusUtil;
import org.eclipse.jdt.internal.ui.util.PixelConverter;
import org.eclipse.jdt.internal.ui.wizards.IStatusChangeListener;
import org.eclipse.jdt.internal.ui.wizards.NewWizardMessages;
import org.eclipse.jdt.internal.ui.wizards.TypedElementSelectionValidator;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.DialogField;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.IDialogFieldListener;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.IStringButtonAdapter;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.SelectionButtonDialogField;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.StringButtonDialogField;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.layout.GridLayout;
/**
* UI to set the source attachment archive and root.
* Same implementation for both setting attachments for libraries from
* variable entries and for normal (internal or external) jar.
*/
public class SourceAttachmentBlock {
private IStatusChangeListener fContext;
private StringButtonDialogField fFileNameField;
private SelectionButtonDialogField fInternalButtonField;
private StringButtonDialogField fPrefixField;
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
private StringButtonDialogField fJavaDocField;
private boolean fIsVariableEntry;
private IStatus fNameStatus;
private IStatus fPrefixStatus;
private IStatus fJavaDocStatus;
private IPath fJARPath;
/**
* The file to which the archive path points to.
* Only set when the file exists.
*/
private File fResolvedFile;
/**
* The path to which the archive variable points.
* Null if invalid path or not resolvable. Must not exist.
*/
private IPath fFileVariablePath;
private URL fJavaDocLocation;
private IWorkspaceRoot fRoot;
private Control fSWTWidget;
private CLabel fFullPathResolvedLabel;
private CLabel fPrefixResolvedLabel;
private IClasspathEntry fOldEntry;
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
public SourceAttachmentBlock(IWorkspaceRoot root, IStatusChangeListener context, IClasspathEntry oldEntry) {
fContext= context;
fRoot= root;
fOldEntry= oldEntry;
fIsVariableEntry= (oldEntry.getEntryKind() == IClasspathEntry.CPE_VARIABLE);
fNameStatus= new StatusInfo();
fPrefixStatus= new StatusInfo();
fJavaDocStatus= new StatusInfo();
fJARPath= (oldEntry != null) ? oldEntry.getPath() : Path.EMPTY;
SourceAttachmentAdapter adapter= new SourceAttachmentAdapter();
if (fIsVariableEntry) {
fFileNameField= new VariablePathDialogField(adapter);
fFileNameField.setDialogFieldListener(adapter);
fFileNameField.setLabelText(NewWizardMessages.getString("SourceAttachmentBlock.filename.varlabel"));
fFileNameField.setButtonLabel(NewWizardMessages.getString("SourceAttachmentBlock.filename.external.varbutton"));
((VariablePathDialogField)fFileNameField).setVariableButtonLabel(NewWizardMessages.getString("SourceAttachmentBlock.filename.variable.button"));
fPrefixField= new VariablePathDialogField(adapter);
fPrefixField.setDialogFieldListener(adapter);
fPrefixField.setLabelText(NewWizardMessages.getString("SourceAttachmentBlock.prefix.varlabel"));
fPrefixField.setButtonLabel(NewWizardMessages.getString("SourceAttachmentBlock.prefix.varbutton"));
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
((VariablePathDialogField)fPrefixField).setVariableButtonLabel(NewWizardMessages.getString("SourceAttachmentBlock.prefix.variable.button"));
} else {
fFileNameField= new StringButtonDialogField(adapter);
fFileNameField.setDialogFieldListener(adapter);
fFileNameField.setLabelText(NewWizardMessages.getString("SourceAttachmentBlock.filename.label"));
fFileNameField.setButtonLabel(NewWizardMessages.getString("SourceAttachmentBlock.filename.external.button"));
fInternalButtonField= new SelectionButtonDialogField(SWT.PUSH);
fInternalButtonField.setDialogFieldListener(adapter);
fInternalButtonField.setLabelText(NewWizardMessages.getString("SourceAttachmentBlock.filename.internal.button"));
fPrefixField= new StringButtonDialogField(adapter);
fPrefixField.setDialogFieldListener(adapter);
fPrefixField.setLabelText(NewWizardMessages.getString("SourceAttachmentBlock.prefix.label"));
fPrefixField.setButtonLabel(NewWizardMessages.getString("SourceAttachmentBlock.prefix.button"));
}
fJavaDocField= new StringButtonDialogField(adapter);
fJavaDocField.setDialogFieldListener(adapter);
fJavaDocField.setLabelText(NewWizardMessages.getString("SourceAttachmentBlock.javadoc.label"));
fJavaDocField.setButtonLabel(NewWizardMessages.getString("SourceAttachmentBlock.javadoc.button"));
setDefaults();
}
public void setDefaults() {
if (fOldEntry != null && fOldEntry.getSourceAttachmentPath() != null) {
fFileNameField.setText(fOldEntry.getSourceAttachmentPath().toString());
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
} else {
fFileNameField.setText("");
}
if (fOldEntry != null && fOldEntry.getSourceAttachmentRootPath() != null) {
fPrefixField.setText(fOldEntry.getSourceAttachmentRootPath().toString());
} else {
fPrefixField.setText("");
}
String jdocText= "";
if (fOldEntry != null) {
IPath path= fJARPath;
if (path != null && fIsVariableEntry) {
path= getResolvedPath(path);
}
if (path != null) {
URL jdocLocation= JavaDocLocations.getJavadocLocation(path);
if (jdocLocation != null) {
jdocText= jdocLocation.toExternalForm();
}
}
}
fJavaDocField.setText(jdocText);
}
/**
* Gets the source attachment path chosen by the user
*/
public IPath getSourceAttachmentPath() {
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
if (fFileNameField.getText().length() == 0) {
return null;
}
return new Path(fFileNameField.getText());
}
/**
* Gets the source attachment root chosen by the user
*/
public IPath getSourceAttachmentRootPath() {
if (getSourceAttachmentPath() == null) {
return null;
} else {
return new Path(fPrefixField.getText());
}
}
/**
* Gets the Javadoc location chosen by the user
*/
public URL getJavadocLocation() {
return fJavaDocLocation;
}
/**
* Creates the control
*/
public Control createControl(Composite parent) {
PixelConverter converter= new PixelConverter(parent);
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
fSWTWidget= parent;
Composite composite= new Composite(parent, SWT.NONE);
GridLayout layout= new GridLayout();
layout.marginHeight= 0;
layout.marginWidth= 0;
layout.numColumns= 4;
composite.setLayout(layout);
int widthHint= converter.convertWidthInCharsToPixels(fIsVariableEntry ? 50 : 60);
GridData gd= new GridData(GridData.HORIZONTAL_ALIGN_FILL);
gd.horizontalSpan= 4;
Label message= new Label(composite, SWT.LEFT);
message.setLayoutData(gd);
message.setText(NewWizardMessages.getFormattedString("SourceAttachmentBlock.message", fJARPath.lastSegment()));
if (fIsVariableEntry) {
DialogField.createEmptySpace(composite, 1);
gd= new GridData(GridData.HORIZONTAL_ALIGN_FILL);
gd.widthHint= widthHint;
gd.horizontalSpan= 2;
Label desc= new Label(composite, SWT.LEFT + SWT.WRAP);
desc.setText(NewWizardMessages.getString("SourceAttachmentBlock.filename.description"));
desc.setLayoutData(gd);
DialogField.createEmptySpace(composite, 1);
}
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
fFileNameField.doFillIntoGrid(composite, 4);
gd= (GridData)fFileNameField.getTextControl(null).getLayoutData();
gd.widthHint= widthHint;
if (!fIsVariableEntry) {
DialogField.createEmptySpace(composite, 3);
fInternalButtonField.doFillIntoGrid(composite, 1);
} else {
DialogField.createEmptySpace(composite, 1);
fFullPathResolvedLabel= new CLabel(composite, SWT.LEFT);
fFullPathResolvedLabel.setText(getResolvedLabelString(fFileNameField.getText(), true));
fFullPathResolvedLabel.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_FILL));
DialogField.createEmptySpace(composite, 2);
}
DialogField.createEmptySpace(composite, 1);
gd= new GridData(GridData.HORIZONTAL_ALIGN_FILL);
gd.widthHint= widthHint;
gd.horizontalSpan= 2;
Label desc= new Label(composite, SWT.LEFT + SWT.WRAP);
desc.setText(NewWizardMessages.getString("SourceAttachmentBlock.prefix.description"));
desc.setLayoutData(gd);
DialogField.createEmptySpace(composite, 1);
fPrefixField.doFillIntoGrid(composite, 4);
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
gd= (GridData)fPrefixField.getTextControl(null).getLayoutData();
gd.widthHint= widthHint;
if (fIsVariableEntry) {
DialogField.createEmptySpace(composite, 1);
fPrefixResolvedLabel= new CLabel(composite, SWT.LEFT);
fPrefixResolvedLabel.setText(getResolvedLabelString(fPrefixField.getText(), false));
fPrefixResolvedLabel.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_FILL));
DialogField.createEmptySpace(composite, 2);
}
fFileNameField.postSetFocusOnDialogField(parent.getDisplay());
DialogField.createEmptySpace(composite, 1);
gd= new GridData(GridData.HORIZONTAL_ALIGN_FILL);
gd.widthHint= widthHint;
gd.horizontalSpan= 2;
desc= new Label(composite, SWT.LEFT + SWT.WRAP);
desc.setText(NewWizardMessages.getString("SourceAttachmentBlock.javadoc.description"));
desc.setLayoutData(gd);
DialogField.createEmptySpace(composite, 1);
fJavaDocField.doFillIntoGrid(composite, 4);
WorkbenchHelp.setHelp(composite, IJavaHelpContextIds.SOURCE_ATTACHMENT_BLOCK);
return composite;
}
private class SourceAttachmentAdapter implements IStringButtonAdapter, IDialogFieldListener {
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
public void changeControlPressed(DialogField field) {
attachmentChangeControlPressed(field);
}
public void dialogFieldChanged(DialogField field) {
attachmentDialogFieldChanged(field);
}
}
private void attachmentChangeControlPressed(DialogField field) {
if (field == fFileNameField) {
IPath jarFilePath= chooseExtJarFile();
if (jarFilePath != null) {
fFileNameField.setText(jarFilePath.toString());
}
} else if (field == fPrefixField) {
IPath prefixPath= choosePrefix();
if (prefixPath != null) {
fPrefixField.setText(prefixPath.toString());
}
} else if (field == fJavaDocField) {
URL jdocURL= chooseJavaDocLocation();
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
if (jdocURL != null) {
fJavaDocField.setText(jdocURL.toExternalForm());
}
}
}
private void attachmentDialogFieldChanged(DialogField field) {
if (field == fFileNameField) {
fNameStatus= updateFileNameStatus();
} else if (field == fInternalButtonField) {
IPath jarFilePath= chooseInternalJarFile(fFileNameField.getText());
if (jarFilePath != null) {
fFileNameField.setText(jarFilePath.toString());
}
return;
} else if (field == fPrefixField) {
fPrefixStatus= updatePrefixStatus();
} else if (field == fJavaDocField) {
fJavaDocStatus= updateJavaDocLocationStatus();
}
doStatusLineUpdate();
}
private void doStatusLineUpdate() {
fPrefixField.enableButton(canBrowsePrefix());
fFileNameField.enableButton(canBrowseFileName());
if (fFullPathResolvedLabel != null) {
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
fFullPathResolvedLabel.setText(getResolvedLabelString(fFileNameField.getText(), true));
}
if (fPrefixResolvedLabel != null) {
fPrefixResolvedLabel.setText(getResolvedLabelString(fPrefixField.getText(), false));
}
IStatus status= StatusUtil.getMostSevere(new IStatus[] { fNameStatus, fPrefixStatus, fJavaDocStatus });
fContext.statusChanged(status);
}
private boolean canBrowseFileName() {
if (!fIsVariableEntry) {
return true;
}
if (fFileVariablePath != null) {
return fFileVariablePath.toFile().isDirectory();
}
return false;
}
private boolean canBrowsePrefix() {
if (fResolvedFile != null) {
if (fIsVariableEntry) {
return fPrefixStatus.isOK() && fPrefixField.getText().length() > 0;
}
return true;
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
}
return false;
}
private String getResolvedLabelString(String path, boolean osPath) {
IPath resolvedPath= getResolvedPath(new Path(path));
if (resolvedPath != null) {
if (osPath) {
return resolvedPath.toOSString();
} else {
return resolvedPath.toString();
}
}
return "";
}
private IPath getResolvedPath(IPath path) {
if (path != null) {
String varName= path.segment(0);
if (varName != null) {
IPath varPath= JavaCore.getClasspathVariable(varName);
if (varPath != null) {
return varPath.append(path.removeFirstSegments(1));
}
}
}
return null;
}
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
private IStatus updatePrefixStatus() {
StatusInfo status= new StatusInfo();
String prefix= fPrefixField.getText();
if (prefix.length() == 0) {
return status;
} else {
if (!Path.EMPTY.isValidPath(prefix)) {
status.setError(NewWizardMessages.getString("SourceAttachmentBlock.prefix.error.notvalid"));
return status;
}
IPath path= new Path(prefix);
if (fIsVariableEntry) {
IPath resolvedPath= getResolvedPath(path);
if (resolvedPath == null) {
status.setError(NewWizardMessages.getString("SourceAttachmentBlock.prefix.error.varnotexists"));
return status;
}
if (resolvedPath.getDevice() != null) {
status.setError(NewWizardMessages.getString("SourceAttachmentBlock.prefix.error.deviceinvar"));
return status;
}
} else {
if (path.getDevice() != null) {
status.setError(NewWizardMessages.getString("SourceAttachmentBlock.prefix.error.deviceinpath"));
return status;
}
}
}
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
return status;
}
private IStatus updateFileNameStatus() {
StatusInfo status= new StatusInfo();
fResolvedFile= null;
fFileVariablePath= null;
String fileName= fFileNameField.getText();
if (fileName.length() == 0) {
return status;
} else {
if (!Path.EMPTY.isValidPath(fileName)) {
status.setError(NewWizardMessages.getString("SourceAttachmentBlock.filename.error.notvalid"));
return status;
}
IPath filePath= new Path(fileName);
IPath resolvedPath;
if (fIsVariableEntry) {
if (filePath.getDevice() != null) {
status.setError(NewWizardMessages.getString("SourceAttachmentBlock.filename.error.deviceinpath"));
return status;
}
String varName= filePath.segment(0);
if (varName == null) {
status.setError(NewWizardMessages.getString("SourceAttachmentBlock.filename.error.notvalid"));
return status;
}
fFileVariablePath= JavaCore.getClasspathVariable(varName);
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
if (fFileVariablePath == null) {
status.setError(NewWizardMessages.getString("SourceAttachmentBlock.filename.error.varnotexists"));
return status;
}
resolvedPath= fFileVariablePath.append(filePath.removeFirstSegments(1));
if (resolvedPath.isEmpty()) {
status.setWarning(NewWizardMessages.getString("SourceAttachmentBlock.filename.warning.varempty"));
return status;
}
File file= resolvedPath.toFile();
if (!file.isFile()) {
String message= NewWizardMessages.getFormattedString("SourceAttachmentBlock.filename.error.filenotexists", resolvedPath.toOSString());
status.setWarning(message);
return status;
}
fResolvedFile= file;
} else {
File file= filePath.toFile();
IResource res= fRoot.findMember(filePath);
if (res != null) {
file= res.getLocation().toFile();
}
if (!file.isFile()) {
String message= NewWizardMessages.getFormattedString("SourceAttachmentBlock.filename.error.filenotexists", filePath.toString());
status.setError(message);
return status;
}
fResolvedFile= file;
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
}
}
return status;
}
private IStatus updateJavaDocLocationStatus() {
StatusInfo status= new StatusInfo();
fJavaDocLocation= null;
String jdocLocation= fJavaDocField.getText();
if (!"".equals(jdocLocation)) {
try {
URL url= new URL(jdocLocation);
if ("file".equals(url.getProtocol())) {
File dir= new File(url.getFile());
if (!dir.isDirectory()) {
status.setError(NewWizardMessages.getString("SourceAttachmentBlock.javadoc.error.notafolder"));
return status;
} else {
File packagesFile= new File(dir, "package-list");
if (!packagesFile.exists()) {
status.setWarning(NewWizardMessages.getString("SourceAttachmentBlock.javadoc.warning.packagelist"));
}
}
}
fJavaDocLocation= url;
} catch (MalformedURLException e) {
status.setError(NewWizardMessages.getFormattedString("SourceAttachmentBlock.javadoc.error.malformed", e.getLocalizedMessage()));
return status;
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
}
}
return status;
}
/*
* Opens a dialog to choose a jar from the file system.
*/
private IPath chooseExtJarFile() {
IPath currPath= new Path(fFileNameField.getText());
if (currPath.isEmpty()) {
currPath= fJARPath;
}
IPath resolvedPath= currPath;
if (fIsVariableEntry) {
resolvedPath= getResolvedPath(currPath);
if (resolvedPath == null) {
resolvedPath= Path.EMPTY;
}
}
if (ArchiveFileFilter.isArchivePath(resolvedPath)) {
resolvedPath= resolvedPath.removeLastSegments(1);
}
FileDialog dialog= new FileDialog(getShell());
dialog.setText(NewWizardMessages.getString("SourceAttachmentBlock.extjardialog.text"));
dialog.setFilterExtensions(new String[] {"*.jar;*.zip"});
dialog.setFilterPath(resolvedPath.toOSString());
String res= dialog.open();
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
if (res != null) {
IPath returnPath= new Path(res).makeAbsolute();
if (fIsVariableEntry) {
returnPath= modifyPath(returnPath, currPath.segment(0));
}
return returnPath;
}
return null;
}
/*
* Opens a dialog to choose an internal jar.
*/
private IPath chooseInternalJarFile(String initSelection) {
Class[] acceptedClasses= new Class[] { IFile.class };
ISelectionValidator validator= new TypedElementSelectionValidator(acceptedClasses, false);
ViewerFilter filter= new ArchiveFileFilter(null);
ILabelProvider lp= new WorkbenchLabelProvider();
ITreeContentProvider cp= new WorkbenchContentProvider();
IResource initSel= fRoot.findMember(new Path(initSelection));
if (initSel == null) {
initSel= fRoot.findMember(fJARPath);
}
ElementTreeSelectionDialog dialog= new ElementTreeSelectionDialog(getShell(), lp, cp);
dialog.setAllowMultiple(false);
dialog.setValidator(validator);
dialog.addFilter(filter);
dialog.setTitle(NewWizardMessages.getString("SourceAttachmentBlock.intjardialog.title"));
dialog.setMessage(NewWizardMessages.getString("SourceAttachmentBlock.intjardialog.message"));
dialog.setInput(fRoot);
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
dialog.setInitialSelection(initSel);
if (dialog.open() == dialog.OK) {
IFile file= (IFile) dialog.getFirstResult();
return file.getFullPath();
}
return null;
}
/*
* Opens a dialog to choose path in a zip file.
*/
private IPath choosePrefix() {
if (fResolvedFile != null) {
IPath currPath= new Path(fPrefixField.getText());
String initSelection= null;
if (fIsVariableEntry) {
IPath resolvedPath= getResolvedPath(currPath);
if (resolvedPath != null) {
initSelection= resolvedPath.toString();
}
} else {
initSelection= currPath.toString();
}
try {
ZipFile zipFile= new ZipFile(fResolvedFile);
ZipContentProvider contentProvider= new ZipContentProvider();
contentProvider.setInitialInput(zipFile);
ElementTreeSelectionDialog dialog= new ElementTreeSelectionDialog(getShell(), new ZipLabelProvider(), contentProvider);
dialog.setAllowMultiple(false);
dialog.setTitle(NewWizardMessages.getString("SourceAttachmentBlock.prefixdialog.title"));
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
dialog.setMessage(NewWizardMessages.getString("SourceAttachmentBlock.prefixdialog.message"));
dialog.setInput(zipFile);
dialog.setInitialSelection(contentProvider.getSelectedNode(initSelection));
if (dialog.open() == dialog.OK) {
Object obj= dialog.getFirstResult();
IPath path= new Path(obj.toString());
if (fIsVariableEntry) {
path= modifyPath(path, currPath.segment(0));
}
return path;
}
} catch (IOException e) {
String title= NewWizardMessages.getString("SourceAttachmentBlock.prefixdialog.error.title");
String message= NewWizardMessages.getFormattedString("SourceAttachmentBlock.prefixdialog.error.message", fResolvedFile.getPath());
MessageDialog.openError(getShell(), title, message);
JavaPlugin.log(e);
}
}
return null;
}
/*
* Opens a dialog to choose a root in the file system.
*/
private URL chooseJavaDocLocation() {
String initPath= "";
if (fJavaDocLocation != null && "file".equals(fJavaDocLocation.getProtocol())) {
initPath= (new File(fJavaDocLocation.getFile())).getPath();
}
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
DirectoryDialog dialog= new DirectoryDialog(getShell());
dialog.setText(NewWizardMessages.getString("SourceAttachmentBlock.jdocdialog.text"));
dialog.setMessage(NewWizardMessages.getString("SourceAttachmentBlock.jdocdialog.message"));
dialog.setFilterPath(initPath);
String res= dialog.open();
if (res != null) {
try {
return (new File(res)).toURL();
} catch (MalformedURLException e) {
JavaPlugin.log(e);
}
}
return null;
}
private Shell getShell() {
if (fSWTWidget != null) {
return fSWTWidget.getShell();
}
return JavaPlugin.getActiveWorkbenchShell();
}
/**
* Takes a path and replaces the beginning with a variable name
* (if the beginning matches with the variables value)
*/
private IPath modifyPath(IPath path, String varName) {
if (varName == null || path == null) {
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
return null;
}
if (path.isEmpty()) {
return new Path(varName);
}
IPath varPath= JavaCore.getClasspathVariable(varName);
if (varPath != null) {
if (varPath.isPrefixOf(path)) {
path= path.removeFirstSegments(varPath.segmentCount());
} else {
path= new Path(path.lastSegment());
}
} else {
path= new Path(path.lastSegment());
}
return new Path(varName).append(path);
}
/**
* Creates a runnable that sets the source attachment by modifying the project's classpath.
*/
public IRunnableWithProgress getRunnable(final IJavaProject jproject, final Shell shell) {
return new IRunnableWithProgress() {
public void run(IProgressMonitor monitor) throws InvocationTargetException {
try {
boolean isExported= fOldEntry != null ? fOldEntry.isExported() : false;
IClasspathEntry newEntry;
if (fIsVariableEntry) {
newEntry= JavaCore.newVariableEntry(fJARPath, getSourceAttachmentPath(), getSourceAttachmentRootPath(), isExported);
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
} else {
newEntry= JavaCore.newLibraryEntry(fJARPath, getSourceAttachmentPath(), getSourceAttachmentRootPath(), isExported);
}
IClasspathEntry[] entries= modifyClasspath(jproject, newEntry, shell);
if (entries != null) {
jproject.setRawClasspath(entries, monitor);
}
IPath path= fJARPath;
if (path != null && fIsVariableEntry) {
path= getResolvedPath(path);
}
if (path != null) {
JavaDocLocations.setJavadocLocation(path, getJavadocLocation());
}
} catch (JavaModelException e) {
throw new InvocationTargetException(e);
}
}
};
}
private IClasspathEntry[] modifyClasspath(IJavaProject jproject, IClasspathEntry newEntry, Shell shell) throws JavaModelException{
IClasspathEntry[] oldClasspath= jproject.getRawClasspath();
int nEntries= oldClasspath.length;
ArrayList newEntries= new ArrayList(nEntries + 1);
int entryKind= newEntry.getEntryKind();
IPath jarPath= newEntry.getPath();
boolean found= false;
for (int i= 0; i < nEntries; i++) {
IClasspathEntry curr= oldClasspath[i];
if (curr.getEntryKind() == entryKind && curr.getPath().equals(jarPath)) {
|
11,814 |
Bug 11814 OpenExternalJavadoc action should not call findElement on JAR
|
This causes an exception: Java Model Exception: Java Model Status [Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.] at org.eclipse.jdt.internal.core.JavaProject.findElement(JavaProject.java:435) at org.eclipse.jdt.internal.ui.actions.OpenExternalJavadocAction.run(OpenExternalJavadocAction.java:102) at org.eclipse.ui.texteditor.RetargetTextEditorAction.run(RetargetTextEditorAction.java:103) at org.eclipse.jface.action.Action.runWithEvent(Action.java:473) 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.notifyListeners(Widget.java(Compiled Code)) at org.eclipse.swt.widgets.Display.runDeferredEvents(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:698) at org.eclipse.core.internal.boot.InternalBootLoader.run(InternalBootLoader.java:777) at org.eclipse.core.boot.BootLoader.run(BootLoader.java:319) at java.lang.reflect.Method.invoke(Native Method) at org.eclipse.core.launcher.Main.basicRun(Main.java:196) at org.eclipse.core.launcher.Main.run(Main.java:555) at org.eclipse.core.launcher.UIMain.main(UIMain.java:52) 4 org.eclipse.jdt.core 979 Invalid path: C:/Java/IBM1.3/jre/lib/rt.jar.
|
resolved fixed
|
a05d335
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-21T15:30:34Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/wizards/buildpaths/SourceAttachmentBlock.java
|
newEntries.add(newEntry);
found= true;
} else {
newEntries.add(curr);
}
}
if (!found) {
if (newEntry.getSourceAttachmentPath() == null || !putJarOnClasspathDialog(shell)) {
return null;
}
newEntries.add(newEntry);
}
return (IClasspathEntry[]) newEntries.toArray(new IClasspathEntry[newEntries.size()]);
}
private boolean putJarOnClasspathDialog(Shell shell) {
final boolean[] result= new boolean[1];
shell.getDisplay().syncExec(new Runnable() {
public void run() {
String title= NewWizardMessages.getString("SourceAttachmentBlock.putoncpdialog.title");
String message= NewWizardMessages.getString("SourceAttachmentBlock.putoncpdialog.message");
result[0]= MessageDialog.openQuestion(JavaPlugin.getActiveWorkbenchShell(), title, message);
}
});
return result[0];
}
}
|
11,795 |
Bug 11795 java browsing: members type shows imports strangely
|
give this code: package p; import java.util.List; public class A { class D{ } } i see the import container as a child of both A and D strange
|
resolved fixed
|
7ec8f37
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:53:28Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaElementContentProvider.java
|
/*
* (c) Copyright IBM Corp. 2000, 2001.
* All Rights Reserved.
*/
package org.eclipse.jdt.internal.ui.browsing;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collection;
import java.util.Iterator;
import java.util.List;
import org.eclipse.swt.widgets.Control;
import org.eclipse.jface.viewers.AbstractTreeViewer;
import org.eclipse.jface.viewers.IBasicPropertyConstants;
import org.eclipse.jface.viewers.ListViewer;
import org.eclipse.jface.viewers.StructuredViewer;
import org.eclipse.jface.viewers.TableViewer;
import org.eclipse.jface.viewers.Viewer;
import org.eclipse.jdt.core.ElementChangedEvent;
|
11,795 |
Bug 11795 java browsing: members type shows imports strangely
|
give this code: package p; import java.util.List; public class A { class D{ } } i see the import container as a child of both A and D strange
|
resolved fixed
|
7ec8f37
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:53:28Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaElementContentProvider.java
|
import org.eclipse.jdt.core.IClassFile;
import org.eclipse.jdt.core.ICompilationUnit;
import org.eclipse.jdt.core.IElementChangedListener;
import org.eclipse.jdt.core.IImportContainer;
import org.eclipse.jdt.core.IJavaElement;
import org.eclipse.jdt.core.IJavaElementDelta;
import org.eclipse.jdt.core.IJavaProject;
import org.eclipse.jdt.core.IMember;
import org.eclipse.jdt.core.IPackageDeclaration;
import org.eclipse.jdt.core.IPackageFragment;
import org.eclipse.jdt.core.IPackageFragmentRoot;
import org.eclipse.jdt.core.IParent;
import org.eclipse.jdt.core.ISourceReference;
import org.eclipse.jdt.core.IType;
import org.eclipse.jdt.core.IWorkingCopy;
import org.eclipse.jdt.core.JavaCore;
import org.eclipse.jdt.core.JavaModelException;
import org.eclipse.jdt.internal.ui.JavaPlugin;
import org.eclipse.jdt.internal.ui.javaeditor.EditorUtility;
import org.eclipse.jdt.internal.ui.viewsupport.BaseJavaElementContentProvider;
class JavaElementContentProvider extends BaseJavaElementContentProvider implements IElementChangedListener {
private StructuredViewer fViewer;
private Object fInput;
private JavaBrowsingPart fBrowsingPart;
public JavaElementContentProvider(boolean provideMembers, JavaBrowsingPart browsingPart) {
super(provideMembers, false);
fBrowsingPart= browsingPart;
fViewer= fBrowsingPart.getViewer();
|
11,795 |
Bug 11795 java browsing: members type shows imports strangely
|
give this code: package p; import java.util.List; public class A { class D{ } } i see the import container as a child of both A and D strange
|
resolved fixed
|
7ec8f37
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:53:28Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaElementContentProvider.java
|
JavaCore.addElementChangedListener(this);
}
public Object[] getChildren(Object element) {
if (!exists(element))
return NO_CHILDREN;
try {
if (element instanceof Collection) {
Collection elements= (Collection)element;
if (elements.isEmpty())
return NO_CHILDREN;
Object[] result= new Object[0];
Iterator iter= ((Collection)element).iterator();
while (iter.hasNext()) {
Object[] children= getChildren(iter.next());
if (children != NO_CHILDREN)
result= concatenate(result, children);
}
return result;
}
if (element instanceof IPackageFragment)
return getPackageContents((IPackageFragment)element);
if (fProvideMembers && element instanceof IType)
return withImportAndPackageDeclarations((IType)element);
if (fProvideMembers && element instanceof ISourceReference && element instanceof IParent)
return removeImportAndPackageDeclarations(super.getChildren(element));
if (element instanceof IJavaProject)
return getPackageFragmentRoots((IJavaProject)element);
return super.getChildren(element);
} catch (JavaModelException e) {
|
11,795 |
Bug 11795 java browsing: members type shows imports strangely
|
give this code: package p; import java.util.List; public class A { class D{ } } i see the import container as a child of both A and D strange
|
resolved fixed
|
7ec8f37
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:53:28Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaElementContentProvider.java
|
return NO_CHILDREN;
}
}
private Object[] getPackageContents(IPackageFragment fragment) throws JavaModelException {
ISourceReference[] sourceRefs;
if (fragment.getKind() == IPackageFragmentRoot.K_SOURCE) {
sourceRefs= fragment.getCompilationUnits();
if (getProvideWorkingCopy()) {
for (int i= 0; i < sourceRefs.length; i++) {
IWorkingCopy wc= EditorUtility.getWorkingCopy((ICompilationUnit)sourceRefs[i]);
if (wc != null)
sourceRefs[i]= (ICompilationUnit)wc;
}
}
}
else {
IClassFile[] classFiles= fragment.getClassFiles();
List topLevelClassFile= new ArrayList();
for (int i= 0; i < classFiles.length; i++) {
IType type= classFiles[i].getType();
if (type != null && type.getDeclaringType() == null)
topLevelClassFile.add(classFiles[i]);
}
sourceRefs= (ISourceReference[])topLevelClassFile.toArray(new ISourceReference[topLevelClassFile.size()]);
}
Object[] result= new Object[0];
for (int i= 0; i < sourceRefs.length; i++)
result= concatenate(result, removeImportAndPackageDeclarations(getChildren(sourceRefs[i])));
return concatenate(result, fragment.getNonJavaResources());
}
|
11,795 |
Bug 11795 java browsing: members type shows imports strangely
|
give this code: package p; import java.util.List; public class A { class D{ } } i see the import container as a child of both A and D strange
|
resolved fixed
|
7ec8f37
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:53:28Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaElementContentProvider.java
|
private Object[] removeImportAndPackageDeclarations(Object[] members) {
ArrayList tempResult= new ArrayList(members.length);
for (int i= 0; i < members.length; i++)
if (!(members[i] instanceof IImportContainer) && !(members[i] instanceof IPackageDeclaration))
tempResult.add(members[i]);
return tempResult.toArray();
}
private Object[] withImportAndPackageDeclarations(IType type) throws JavaModelException{
IParent parent;
if (type.isBinary())
parent= type.getClassFile();
else {
parent= type.getCompilationUnit();
if (getProvideWorkingCopy()) {
IWorkingCopy wc= EditorUtility.getWorkingCopy((ICompilationUnit)parent);
if (wc != null) {
parent= (IParent)wc;
IMember wcType= EditorUtility.getWorkingCopy(type);
if (wcType != null)
type= (IType)wcType;
}
}
}
IJavaElement[] members= parent.getChildren();
ArrayList tempResult= new ArrayList(members.length);
for (int i= 0; i < members.length; i++)
if ((members[i] instanceof IImportContainer))
tempResult.add(members[i]);
tempResult.addAll(Arrays.asList(type.getChildren()));
return tempResult.toArray();
|
11,795 |
Bug 11795 java browsing: members type shows imports strangely
|
give this code: package p; import java.util.List; public class A { class D{ } } i see the import container as a child of both A and D strange
|
resolved fixed
|
7ec8f37
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:53:28Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaElementContentProvider.java
|
}
private Object[] getPackageFragmentRoots(IJavaProject project) throws JavaModelException {
if (!project.getProject().isOpen())
return NO_CHILDREN;
IPackageFragmentRoot[] roots= project.getPackageFragmentRoots();
List list= new ArrayList(roots.length);
for (int i= 0; i < roots.length; i++) {
IPackageFragmentRoot root= (IPackageFragmentRoot)roots[i];
if (!root.isExternal()) {
Object[] children= root.getChildren();
for (int k= 0; k < children.length; k++)
list.add(children[k]);
}
else if (hasChildren(root)) {
list.add(root);
}
}
return concatenate(list.toArray(), project.getNonJavaResources());
}
/* (non-Javadoc)
* Method declared on IContentProvider.
*/
public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
super.inputChanged(viewer, oldInput, newInput);
if (newInput instanceof Collection) {
|
11,795 |
Bug 11795 java browsing: members type shows imports strangely
|
give this code: package p; import java.util.List; public class A { class D{ } } i see the import container as a child of both A and D strange
|
resolved fixed
|
7ec8f37
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:53:28Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaElementContentProvider.java
|
Collection col= (Collection)newInput;
if (!col.isEmpty())
newInput= col.iterator().next();
else
newInput= null;
}
fInput= newInput;
}
/* (non-Javadoc)
* Method declared on IContentProvider.
*/
public void dispose() {
super.dispose();
JavaCore.removeElementChangedListener(this);
}
/* (non-Javadoc)
* Method declared on IElementChangedListener.
*/
public void elementChanged(final ElementChangedEvent event) {
try {
processDelta(event.getDelta());
} catch(JavaModelException e) {
JavaPlugin.getDefault().log(e.getStatus());
}
}
/**
* Processes a delta recursively. When more than two children are affected the
* tree is fully refreshed starting at this node. The delta is processed in the
|
11,795 |
Bug 11795 java browsing: members type shows imports strangely
|
give this code: package p; import java.util.List; public class A { class D{ } } i see the import container as a child of both A and D strange
|
resolved fixed
|
7ec8f37
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:53:28Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaElementContentProvider.java
|
* current thread but the viewer updates are posted to the UI thread.
*/
protected void processDelta(IJavaElementDelta delta) throws JavaModelException {
int kind= delta.getKind();
int flags= delta.getFlags();
IJavaElement element= delta.getElement();
if (!getProvideWorkingCopy() && element instanceof IWorkingCopy && ((IWorkingCopy)element).isWorkingCopy()) {
return;
}
if (((flags & IJavaElementDelta.F_CLOSED) != 0) || ((flags & IJavaElementDelta.F_OPENED) != 0)) {
postRefresh(element);
return;
}
if (kind == IJavaElementDelta.REMOVED) {
Object parent= internalGetParent(element);
if (fBrowsingPart.isValidElement(element)) {
if (element instanceof IClassFile) {
postRemove(((IClassFile)element).getType());
} else if (element instanceof ICompilationUnit && !((ICompilationUnit)element).isWorkingCopy()) {
if (!getProvideWorkingCopy())
postRefresh(null);
} else if (parent instanceof ICompilationUnit && getProvideWorkingCopy() && !((ICompilationUnit)parent).isWorkingCopy()) {
} else
postRemove(element);
}
if (fBrowsingPart.isAncestorOf(element, fInput))
postAdjustInputAndSetSelection(null);
|
11,795 |
Bug 11795 java browsing: members type shows imports strangely
|
give this code: package p; import java.util.List; public class A { class D{ } } i see the import container as a child of both A and D strange
|
resolved fixed
|
7ec8f37
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:53:28Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaElementContentProvider.java
|
return;
}
if (kind == IJavaElementDelta.ADDED) {
if (fBrowsingPart.isValidElement(element)) {
Object parent= internalGetParent(element);
if (element instanceof IClassFile) {
postAdd(parent, ((IClassFile)element).getType());
} else if (element instanceof ICompilationUnit && !((ICompilationUnit)element).isWorkingCopy()) {
if (!getProvideWorkingCopy())
postAdd(parent, ((ICompilationUnit)element).getAllTypes());
} else if (parent instanceof ICompilationUnit && getProvideWorkingCopy() && !((ICompilationUnit)parent).isWorkingCopy()) {
} else
postAdd(parent, element);
} else if (fInput == null) {
IJavaElement newInput= fBrowsingPart.findInputForJavaElement(element);
if (newInput != null)
postAdjustInputAndSetSelection(element);
}
return;
}
if (element instanceof IType && fBrowsingPart.isValidInput(element))
postRefresh(null);
if (isClassPathChange(delta))
postRefresh(null);
IJavaElementDelta[] affectedChildren= delta.getAffectedChildren();
|
11,795 |
Bug 11795 java browsing: members type shows imports strangely
|
give this code: package p; import java.util.List; public class A { class D{ } } i see the import container as a child of both A and D strange
|
resolved fixed
|
7ec8f37
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:53:28Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaElementContentProvider.java
|
if (affectedChildren.length > 1) {
if (element instanceof IPackageFragment) {
IJavaElement parent= (IJavaElement)internalGetParent(element);
if (element.equals(fInput)) {
postRefresh(element);
} else {
postRefresh(parent);
}
}
if (element instanceof IPackageFragmentRoot && fBrowsingPart.isValidElement(element)) {
postRefresh(skipProjectPackageFragmentRoot((IPackageFragmentRoot)element));
return;
}
}
for (int i= 0; i < affectedChildren.length; i++) {
processDelta(affectedChildren[i]);
}
}
/**
* Updates the package icon
*/
private void updatePackageIcon(final IJavaElement element) {
postRunnable(new Runnable() {
public void run() {
Control ctrl= fViewer.getControl();
if (ctrl != null && !ctrl.isDisposed())
|
11,795 |
Bug 11795 java browsing: members type shows imports strangely
|
give this code: package p; import java.util.List; public class A { class D{ } } i see the import container as a child of both A and D strange
|
resolved fixed
|
7ec8f37
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:53:28Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaElementContentProvider.java
|
fViewer.update(element, new String[]{IBasicPropertyConstants.P_IMAGE});
}
});
}
private void postRefresh(final Object root) {
postRunnable(new Runnable() {
public void run() {
Control ctrl= fViewer.getControl();
if (ctrl != null && !ctrl.isDisposed())
fViewer.refresh(root);
}
});
}
private void postAdd(final Object parent, final Object element) {
postAdd(parent, new Object[] {element});
}
private void postAdd(final Object parent, final Object[] elements) {
if (elements.length <= 0)
return;
postRunnable(new Runnable() {
public void run() {
Control ctrl= fViewer.getControl();
if (ctrl != null && !ctrl.isDisposed()) {
ctrl.setRedraw(false);
if (fViewer instanceof AbstractTreeViewer) {
if (fViewer.testFindItem(parent) == null) {
Object root= ((AbstractTreeViewer)fViewer).getInput();
|
11,795 |
Bug 11795 java browsing: members type shows imports strangely
|
give this code: package p; import java.util.List; public class A { class D{ } } i see the import container as a child of both A and D strange
|
resolved fixed
|
7ec8f37
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:53:28Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaElementContentProvider.java
|
if (root != null)
((AbstractTreeViewer)fViewer).add(root, elements);
}
else
((AbstractTreeViewer)fViewer).add(parent, elements);
}
else if (fViewer instanceof ListViewer)
((ListViewer)fViewer).add(elements);
else if (fViewer instanceof TableViewer)
((TableViewer)fViewer).add(elements);
if (fViewer.testFindItem(elements[0]) != null)
fBrowsingPart.adjustInputAndSetSelection((IJavaElement)elements[0]);
ctrl.setRedraw(true);
}
}
});
}
private void postRemove(final Object element) {
postRemove(new Object[] {element});
}
private void postRemove(final Object[] elements) {
if (elements.length <= 0)
return;
postRunnable(new Runnable() {
public void run() {
Control ctrl= fViewer.getControl();
if (ctrl != null && !ctrl.isDisposed()) {
ctrl.setRedraw(false);
if (fViewer instanceof AbstractTreeViewer)
|
11,795 |
Bug 11795 java browsing: members type shows imports strangely
|
give this code: package p; import java.util.List; public class A { class D{ } } i see the import container as a child of both A and D strange
|
resolved fixed
|
7ec8f37
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:53:28Z | 2002-03-20T10:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaElementContentProvider.java
|
((AbstractTreeViewer)fViewer).remove(elements);
else if (fViewer instanceof ListViewer)
((ListViewer)fViewer).remove(elements);
else if (fViewer instanceof TableViewer)
((TableViewer)fViewer).remove(elements);
ctrl.setRedraw(true);
}
}
});
}
private void postAdjustInputAndSetSelection(final Object element) {
postRunnable(new Runnable() {
public void run() {
Control ctrl= fViewer.getControl();
if (ctrl != null && !ctrl.isDisposed()) {
ctrl.setRedraw(false);
fBrowsingPart.adjustInputAndSetSelection((IJavaElement)element);
ctrl.setRedraw(true);
}
}
});
}
private void postRunnable(final Runnable r) {
Control ctrl= fViewer.getControl();
if (ctrl != null && !ctrl.isDisposed()) {
ctrl.getDisplay().asyncExec(r);
}
}
}
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
/*
* (c) Copyright IBM Corp. 2000, 2001.
* All Rights Reserved.
*/
package org.eclipse.jdt.internal.ui.browsing;
import java.util.Collection;
import java.util.Comparator;
import org.eclipse.core.resources.IContainer;
import org.eclipse.core.resources.IFile;
import org.eclipse.core.resources.IResource;
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
import org.eclipse.core.runtime.IAdaptable;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.KeyAdapter;
import org.eclipse.swt.events.KeyEvent;
import org.eclipse.swt.graphics.Image;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.Menu;
import org.eclipse.swt.widgets.Shell;
import org.eclipse.jface.action.Action;
import org.eclipse.jface.action.IMenuListener;
import org.eclipse.jface.action.IMenuManager;
import org.eclipse.jface.action.IStatusLineManager;
import org.eclipse.jface.action.IToolBarManager;
import org.eclipse.jface.action.MenuManager;
import org.eclipse.jface.action.Separator;
import org.eclipse.jface.text.ITextSelection;
import org.eclipse.jface.util.Assert;
import org.eclipse.jface.viewers.DecoratingLabelProvider;
import org.eclipse.jface.viewers.DoubleClickEvent;
import org.eclipse.jface.viewers.IDoubleClickListener;
import org.eclipse.jface.viewers.ILabelDecorator;
import org.eclipse.jface.viewers.ILabelProvider;
import org.eclipse.jface.viewers.ISelection;
import org.eclipse.jface.viewers.ISelectionChangedListener;
import org.eclipse.jface.viewers.ISelectionProvider;
import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.jface.viewers.SelectionChangedEvent;
import org.eclipse.jface.viewers.StructuredSelection;
import org.eclipse.jface.viewers.StructuredViewer;
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
import org.eclipse.ui.IActionBars;
import org.eclipse.ui.IEditorInput;
import org.eclipse.ui.IEditorPart;
import org.eclipse.ui.IFileEditorInput;
import org.eclipse.ui.IMemento;
import org.eclipse.ui.IPartListener;
import org.eclipse.ui.ISelectionListener;
import org.eclipse.ui.IViewSite;
import org.eclipse.ui.IWorkbenchActionConstants;
import org.eclipse.ui.IWorkbenchPage;
import org.eclipse.ui.IWorkbenchPart;
import org.eclipse.ui.IWorkbenchPartSite;
import org.eclipse.ui.PartInitException;
import org.eclipse.ui.PlatformUI;
import org.eclipse.ui.actions.NewWizardMenu;
import org.eclipse.ui.actions.OpenPerspectiveMenu;
import org.eclipse.ui.actions.OpenWithMenu;
import org.eclipse.ui.actions.RefreshAction;
import org.eclipse.ui.dialogs.PropertyDialogAction;
import org.eclipse.ui.part.ViewPart;
import org.eclipse.ui.views.internal.framelist.BackAction;
import org.eclipse.ui.views.internal.framelist.ForwardAction;
import org.eclipse.ui.views.internal.framelist.GoIntoAction;
import org.eclipse.ui.views.internal.framelist.UpAction;
import org.eclipse.jdt.core.IClassFile;
import org.eclipse.jdt.core.ICompilationUnit;
import org.eclipse.jdt.core.IJavaElement;
import org.eclipse.jdt.core.IMember;
import org.eclipse.jdt.core.IType;
import org.eclipse.jdt.core.IWorkingCopy;
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
import org.eclipse.jdt.core.JavaModelException;
import org.eclipse.jdt.ui.IContextMenuConstants;
import org.eclipse.jdt.ui.IWorkingCopyManager;
import org.eclipse.jdt.ui.JavaElementLabelProvider;
import org.eclipse.jdt.ui.JavaElementSorter;
import org.eclipse.jdt.internal.core.JavaElement;
import org.eclipse.jdt.internal.corext.util.JavaModelUtil;
import org.eclipse.jdt.internal.ui.JavaPlugin;
import org.eclipse.jdt.internal.ui.actions.ContextMenuGroup;
import org.eclipse.jdt.internal.ui.actions.GenerateGroup;
import org.eclipse.jdt.internal.ui.javaeditor.EditorUtility;
import org.eclipse.jdt.internal.ui.javaeditor.IClassFileEditorInput;
import org.eclipse.jdt.internal.ui.javaeditor.JarEntryEditorInput;
import org.eclipse.jdt.internal.ui.packageview.BuildGroup;
import org.eclipse.jdt.internal.ui.packageview.OpenResourceAction;
import org.eclipse.jdt.internal.ui.packageview.PackagesMessages;
import org.eclipse.jdt.internal.ui.packageview.ShowInNavigatorAction;
import org.eclipse.jdt.internal.ui.refactoring.actions.IRefactoringAction;
import org.eclipse.jdt.internal.ui.refactoring.actions.RefactoringGroup;
import org.eclipse.jdt.internal.ui.reorg.ReorgGroup;
import org.eclipse.jdt.internal.ui.search.JavaSearchGroup;
import org.eclipse.jdt.internal.ui.util.JavaUIHelp;
import org.eclipse.jdt.internal.ui.util.OpenTypeHierarchyUtil;
import org.eclipse.jdt.internal.ui.viewsupport.BaseJavaElementContentProvider;
import org.eclipse.jdt.internal.ui.viewsupport.IProblemChangedListener;
import org.eclipse.jdt.internal.ui.viewsupport.JavaElementImageProvider;
import org.eclipse.jdt.internal.ui.viewsupport.ProblemTableViewer;
import org.eclipse.jdt.internal.ui.viewsupport.StandardJavaUILabelProvider;
import org.eclipse.jdt.internal.ui.viewsupport.StatusBarUpdater;
abstract class JavaBrowsingPart extends ViewPart implements IMenuListener, ISelectionListener {
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
private ILabelProvider fLabelProvider;
private ILabelProvider fTitleProvider;
private StructuredViewer fViewer;
private IMemento fMemento;
private JavaElementTypeComparator fTypeComparator;
private ContextMenuGroup[] fStandardGroups;
private Menu fContextMenu;
private OpenResourceAction fOpenCUAction;
private Action fOpenToAction;
private Action fShowNavigatorAction;
private PropertyDialogAction fPropertyDialogAction;
private IRefactoringAction fDeleteAction;
private RefreshAction fRefreshAction;
private BackAction fBackAction;
private ForwardAction fForwardAction;
private GoIntoAction fZoomInAction;
private UpAction fUpAction;
private IWorkbenchPart fPreviousSelectionProvider;
private Image fOriginalTitleImage;
/*
* Ensure selection changed events being processed only if
* initiated by user interaction with this part.
*/
private boolean fProcessSelectionEvents= true;
private IPartListener fPartListener= new IPartListener() {
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
public void partActivated(IWorkbenchPart part) {
setSelectionFromEditor(part);
}
public void partBroughtToTop(IWorkbenchPart part) {
}
public void partClosed(IWorkbenchPart part) {
}
public void partDeactivated(IWorkbenchPart part) {
}
public void partOpened(IWorkbenchPart part) {
}
};
/*
* Implements method from IViewPart.
*/
public void init(IViewSite site, IMemento memento) throws PartInitException {
super.init(site, memento);
fMemento= memento;
}
/*
* Implements method from IViewPart.
*/
public void saveState(IMemento memento) {
if (fViewer == null) {
if (fMemento != null)
memento.putMemento(fMemento);
return;
}
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
}
/**
* Creates the search list inner viewer.
*/
public void createPartControl(Composite parent) {
Assert.isTrue(fViewer == null);
if (fMemento != null)
fMemento= null;
fTypeComparator= new JavaElementTypeComparator();
fViewer= createViewer(parent);
fLabelProvider= createLabelProvider();
ILabelDecorator decorationMgr= PlatformUI.getWorkbench().getDecoratorManager();
fViewer.setLabelProvider(new DecoratingLabelProvider(fLabelProvider, decorationMgr));
fViewer.setSorter(new JavaElementSorter());
fViewer.setUseHashlookup(true);
JavaPlugin.getDefault().getProblemMarkerManager().addListener((IProblemChangedListener)fViewer);
fTitleProvider= createTitleProvider();
MenuManager menuMgr= new MenuManager("#PopupMenu");
menuMgr.setRemoveAllWhenShown(true);
menuMgr.addMenuListener(this);
fContextMenu= menuMgr.createContextMenu(fViewer.getControl());
fViewer.getControl().setMenu(fContextMenu);
getSite().registerContextMenu(menuMgr, fViewer);
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
createActions();
addKeyListener();
getSite().setSelectionProvider(fViewer);
IStatusLineManager slManager= getViewSite().getActionBars().getStatusLineManager();
fViewer.addSelectionChangedListener(new StatusBarUpdater(slManager));
hookViewerListeners();
fViewer.setContentProvider(createContentProvider());
setInitialInput();
setInitialSelection();
addFilters();
fillToolBar(getViewSite().getActionBars().getToolBarManager());
getViewSite().getWorkbenchWindow().getSelectionService().addSelectionListener(this);
getViewSite().getPage().addPartListener(fPartListener);
setHelp();
}
public void setFocus() {
fViewer.getControl().setFocus();
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
}
public void dispose() {
if (fViewer != null) {
JavaPlugin.getDefault().getProblemMarkerManager().removeListener((IProblemChangedListener)fViewer);
getViewSite().getWorkbenchWindow().getSelectionService().removeSelectionListener(this);
getViewSite().getPage().removePartListener(fPartListener);
fViewer= null;
}
super.dispose();
}
/**
* Adds the KeyListener
*/
protected void addKeyListener() {
fViewer.getControl().addKeyListener(new KeyAdapter() {
public void keyReleased(KeyEvent event) {
handleKeyReleased(event);
}
});
}
protected void handleKeyReleased(KeyEvent event) {
if (event.stateMask != 0)
return;
int key= event.keyCode;
if (key == SWT.F5) {
fRefreshAction.selectionChanged(
(IStructuredSelection) fViewer.getSelection());
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
if (fRefreshAction.isEnabled())
fRefreshAction.run();
} else if (key == SWT.F4) {
OpenTypeHierarchyUtil.open(getSelectionProvider().getSelection(), getSite().getWorkbenchWindow());
} else if (key == SWT.F3) {
fOpenCUAction.update();
if (fOpenCUAction.isEnabled())
fOpenCUAction.run();
}
else if (event.character == SWT.DEL) {
fDeleteAction.update();
if (fDeleteAction.isEnabled())
fDeleteAction.run();
}
}
protected void fillToolBar(IToolBarManager tbm) {
}
/**
* Called when the context menu is about to open.
* Override to add your own context dependent menu contributions.
*/
public void menuAboutToShow(IMenuManager menu) {
JavaPlugin.createStandardGroups(menu);
IStructuredSelection selection= (IStructuredSelection) fViewer.getSelection();
fPropertyDialogAction.selectionChanged(selection);
MenuManager newMenu= new MenuManager(PackagesMessages.getString("PackageExplorer.new"));
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
menu.appendToGroup(IContextMenuConstants.GROUP_NEW, newMenu);
new NewWizardMenu(newMenu, getSite().getWorkbenchWindow(), false);
fOpenCUAction.update();
if (fOpenCUAction.isEnabled())
menu.appendToGroup(IContextMenuConstants.GROUP_OPEN, fOpenCUAction);
addOpenWithMenu(menu, selection);
addOpenToMenu(menu, selection);
addRefactoring(menu);
ContextMenuGroup.add(menu, fStandardGroups, fViewer);
menu.appendToGroup(IContextMenuConstants.GROUP_BUILD, fRefreshAction);
fRefreshAction.selectionChanged(selection);
menu.add(new Separator());
if (fPropertyDialogAction.isApplicableForSelection())
menu.appendToGroup(IContextMenuConstants.GROUP_PROPERTIES, fPropertyDialogAction);
}
private void addRefactoring(IMenuManager menu){
MenuManager refactoring= new MenuManager(PackagesMessages.getString("PackageExplorer.refactoringTitle"));
ContextMenuGroup.add(refactoring, new ContextMenuGroup[] { new RefactoringGroup() }, fViewer);
if (!refactoring.isEmpty())
menu.appendToGroup(IContextMenuConstants.GROUP_REORGANIZE, refactoring);
}
private void createActions() {
ISelectionProvider provider= getSelectionProvider();
fOpenCUAction= new OpenResourceAction(provider);
fPropertyDialogAction= new PropertyDialogAction(getShell(), provider);
fShowNavigatorAction= new ShowInNavigatorAction(provider);
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
fStandardGroups= new ContextMenuGroup[] {
new BuildGroup(),
new ReorgGroup(),
new GenerateGroup(),
new JavaSearchGroup()
};
fDeleteAction= ReorgGroup.createDeleteAction(provider);
fRefreshAction= new RefreshAction(getShell());
IActionBars actionService= getViewSite().getActionBars();
actionService.setGlobalActionHandler(IWorkbenchActionConstants.DELETE, fDeleteAction);
ReorgGroup.addGlobalReorgActions(actionService, provider);
}
private void addOpenToMenu(IMenuManager menu, IStructuredSelection selection) {
if (selection.size() != 1)
return;
IAdaptable element= (IAdaptable) selection.getFirstElement();
IResource resource= (IResource)element.getAdapter(IResource.class);
if ((resource instanceof IContainer)) {
MenuManager submenu = new MenuManager(PackagesMessages.getString("PackageExplorer.openPerspective"));
submenu.add(new OpenPerspectiveMenu(getSite().getWorkbenchWindow(), resource));
menu.appendToGroup(IContextMenuConstants.GROUP_OPEN, submenu);
}
OpenTypeHierarchyUtil.addToMenu(getSite().getWorkbenchWindow(), menu, element);
}
private void addOpenWithMenu(IMenuManager menu, IStructuredSelection selection) {
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
if (selection.size() != 1)
return;
IAdaptable element= (IAdaptable)selection.getFirstElement();
Object resource= element.getAdapter(IResource.class);
if (!(resource instanceof IFile))
return;
MenuManager submenu= new MenuManager(PackagesMessages.getString("PackageExplorer.openWith"));
submenu.add(new OpenWithMenu(getSite().getPage(), (IFile) resource));
menu.appendToGroup(IContextMenuConstants.GROUP_OPEN, submenu);
}
/**
* Returns the shell to use for opening dialogs.
* Used in this class, and in the actions.
*/
private Shell getShell() {
return fViewer.getControl().getShell();
}
protected final Display getDisplay() {
return fViewer.getControl().getDisplay();
}
/**
* Returns the selection provider.
*/
private ISelectionProvider getSelectionProvider() {
return fViewer;
}
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
/**
* Answers if the given <code>element</code> is a valid
* input for this part.
*
* @param element the object to test
* @return <true> if the given element is a valid input
*/
abstract protected boolean isValidInput(Object element);
/**
* Answers if the given <code>element</code> is a valid
* element for this part.
*
* @param element the object to test
* @return <true> if the given element is a valid element
*/
protected boolean isValidElement(Object element) {
if (element == null)
return false;
element= getSuitableJavaElement(element);
if (element == null)
return false;
Object input= getViewer().getInput();
if (input == null)
return false;
if (input instanceof Collection)
return ((Collection)input).contains(element);
else
return input.equals(element);
}
private boolean isInputResetBy(Object newInput, Object input, IWorkbenchPart part) {
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
if (newInput == null)
return part == fPreviousSelectionProvider;
if (input instanceof IJavaElement && newInput instanceof IJavaElement)
return getTypeComparator().compare(newInput, input) > 0;
else
return false;
}
protected boolean isAncestorOf(Object ancestor, Object element) {
if (element instanceof IJavaElement && ancestor instanceof IJavaElement)
return !element.equals(ancestor) && internalIsAncestorOf((IJavaElement)ancestor, (IJavaElement)element);
return false;
}
private boolean internalIsAncestorOf(IJavaElement ancestor, IJavaElement element) {
if (element != null)
return element.equals(ancestor) || internalIsAncestorOf(ancestor, element.getParent());
else
return false;
}
public void selectionChanged(IWorkbenchPart part, ISelection selection) {
if (!fProcessSelectionEvents || part == this || !(selection instanceof IStructuredSelection))
return;
if (selection.isEmpty() && part instanceof JavaBrowsingPart && !(part instanceof ProjectsView))
return;
Object newInput= getElementFromSingleSelection(selection);
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
Object currentInput= (IJavaElement)getViewer().getInput();
if (newInput != null && newInput.equals(currentInput)) {
IJavaElement elementToSelect= findElementToSelect(getElementFromSingleSelection(selection));
if (elementToSelect != null && getTypeComparator().compare(newInput, elementToSelect) < 0)
setSelection(new StructuredSelection(elementToSelect), true);
fPreviousSelectionProvider= part;
return;
}
if (part != fPreviousSelectionProvider && newInput != null && !newInput.equals(currentInput) && isInputResetBy(newInput, currentInput, part)) {
if (!isAncestorOf(newInput, currentInput))
setInput(null);
fPreviousSelectionProvider= part;
return;
} else if (newInput == null && part == fPreviousSelectionProvider) {
setInput(null);
fPreviousSelectionProvider= part;
return;
}
fPreviousSelectionProvider= part;
if (newInput instanceof IJavaElement)
adjustInputAndSetSelection((IJavaElement)newInput);
else
setSelection(StructuredSelection.EMPTY, true);
}
protected void setInput(Object input) {
if (input == null)
setTitleImage(fOriginalTitleImage);
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
else if (input instanceof Collection) {
if (((Collection)input).isEmpty())
setTitleImage(fOriginalTitleImage);
else {
Object firstElement= ((Collection)input).iterator().next();
setTitleImage(fTitleProvider.getImage(firstElement));
}
} else
setTitleImage(fTitleProvider.getImage(input));
setViewerInput(input);
}
private void setViewerInput(Object input) {
fProcessSelectionEvents= false;
fViewer.setInput(input);
fProcessSelectionEvents= true;
}
/**
* Sets or clears the title image of this part and
* store the orignal image on the first call.
*/
protected void setTitleImage(Image titleImage) {
if (fOriginalTitleImage == null)
fOriginalTitleImage= getTitleImage();
if (titleImage == null)
titleImage= fOriginalTitleImage;
super.setTitleImage(titleImage);
}
protected final StructuredViewer getViewer() {
return fViewer;
}
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
protected ILabelProvider createLabelProvider() {
return new StandardJavaUILabelProvider(
StandardJavaUILabelProvider.DEFAULT_TEXTFLAGS,
StandardJavaUILabelProvider.DEFAULT_IMAGEFLAGS | JavaElementImageProvider.SMALL_ICONS,
StandardJavaUILabelProvider.getAdornmentProviders(true, null)
);
}
protected ILabelProvider createTitleProvider() {
return new JavaElementLabelProvider(JavaElementLabelProvider.SHOW_BASICS | JavaElementLabelProvider.SHOW_SMALL_ICONS);
}
protected final ILabelProvider getLabelProvider() {
return fLabelProvider;
}
protected final ILabelProvider getTitleProvider() {
return fTitleProvider;
}
/**
* Creates the the viewer of this part.
*
* @param parent the parent for the viewer
*/
protected StructuredViewer createViewer(Composite parent) {
return new ProblemTableViewer(parent, SWT.SINGLE);
}
protected int getLabelProviderFlags() {
return JavaElementLabelProvider.SHOW_BASICS | JavaElementLabelProvider.SHOW_OVERLAY_ICONS |
JavaElementLabelProvider.SHOW_SMALL_ICONS | JavaElementLabelProvider.SHOW_VARIABLE | JavaElementLabelProvider.SHOW_PARAMETERS;
}
/**
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
* Adds filters the viewer of this part.
*/
protected void addFilters() {
}
/**
* Creates the the content provider of this part.
*/
protected BaseJavaElementContentProvider createContentProvider() {
return new JavaElementContentProvider(true, this);
}
protected void setInitialInput() {
ISelection selection= getSite().getPage().getSelection();
Object input= getElementFromSingleSelection(selection);
if (!(input instanceof IJavaElement)) {
input= getSite().getPage().getInput();
if (!(input instanceof IJavaElement) && input instanceof IAdaptable)
input= ((IAdaptable)input).getAdapter(IJavaElement.class);
}
setInput(findInputForJavaElement((JavaElement)input));
}
protected void setInitialSelection() {
Object input;
ISelection selection= getSite().getPage().getSelection();
if (selection != null && !selection.isEmpty())
input= getElementFromSingleSelection(selection);
else {
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
input= getSite().getPage().getInput();
if (!(input instanceof IJavaElement) && input instanceof IAdaptable)
input= ((IAdaptable)input).getAdapter(IJavaElement.class);
else
return;
}
if (findElementToSelect((IJavaElement)input) != null)
adjustInputAndSetSelection((IJavaElement)input);
}
final protected void setHelp() {
JavaUIHelp.setHelp(fViewer, getHelpContextId());
}
/**
* Returns the context ID for the Help system
*
* @return the string used as ID for the Help context
*/
abstract protected String getHelpContextId();
/**
* Adds additional listeners to this view.
*/
protected void hookViewerListeners() {
fViewer.addSelectionChangedListener(new ISelectionChangedListener() {
public void selectionChanged(SelectionChangedEvent event) {
if (!fProcessSelectionEvents)
return;
if (JavaBrowsingPreferencePage.openEditorOnSingleClick())
new ShowInEditorAction().run(event.getSelection(), getSite().getPage());
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
else
linkToEditor((IStructuredSelection)event.getSelection());
}
});
fViewer.addDoubleClickListener(new IDoubleClickListener() {
public void doubleClick(DoubleClickEvent event) {
if (fProcessSelectionEvents && !JavaBrowsingPreferencePage.openEditorOnSingleClick())
new ShowInEditorAction().run(event.getSelection(), getSite().getPage());
}
});
}
void adjustInputAndSetSelection(IJavaElement je) {
je= getSuitableJavaElement(je);
IJavaElement elementToSelect= findElementToSelect(je);
IJavaElement newInput= findInputForJavaElement(je);
if (elementToSelect == null && !isValidInput(newInput))
setInput(null);
else if (elementToSelect == null || getViewer().testFindItem(elementToSelect) == null)
setInput(findInputForJavaElement(je));
if (elementToSelect != null)
setSelection(new StructuredSelection(elementToSelect), true);
else
setSelection(StructuredSelection.EMPTY, true);
}
/**
* Finds the closest Java element which can be used as input for
* this part and has the given Java element as child
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
*
* @param je the Java element for which to search the closest input
* @return the closest Java element used as input for this part
*/
protected IJavaElement findInputForJavaElement(IJavaElement je) {
if (je == null)
return null;
if (isValidInput(je))
return je;
return findInputForJavaElement(je.getParent());
}
final protected IJavaElement findElementToSelect(Object obj) {
if (obj instanceof IJavaElement)
return findElementToSelect((IJavaElement)obj);
return null;
}
/**
* Finds the element which has to be selected in this part.
*
* @param je the Java element which has the focus
*/
abstract protected IJavaElement findElementToSelect(IJavaElement je);
private Object getElementFromSingleSelection(ISelection selection) {
if (selection instanceof StructuredSelection
&& ((StructuredSelection)selection).size() == 1)
return ((StructuredSelection)selection).getFirstElement();
return null;
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
}
/**
* Gets the typeComparator.
* @return Returns a JavaElementTypeComparator
*/
protected Comparator getTypeComparator() {
return fTypeComparator;
}
/**
* Links to editor (if option enabled)
*/
private void linkToEditor(IStructuredSelection selection) {
if (selection == null || selection.isEmpty())
return;
Object obj= selection.getFirstElement();
Object element= null;
if (selection.size() == 1) {
if (obj instanceof IJavaElement) {
IJavaElement cu= JavaModelUtil.findElementOfKind((IJavaElement)obj, IJavaElement.COMPILATION_UNIT);
if (cu != null)
element= getResourceFor(cu);
if (element == null)
element= JavaModelUtil.findElementOfKind((IJavaElement)obj, IJavaElement.CLASS_FILE);
}
else if (obj instanceof IFile)
element= obj;
if (element == null)
return;
IWorkbenchPage page= getSite().getPage();
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
IEditorPart editorArray[]= page.getEditors();
for (int i= 0; i < editorArray.length; ++i) {
IEditorPart editor= editorArray[i];
Object input= getElementOfInput(editor.getEditorInput());
if (input != null && input.equals(element)) {
page.bringToTop(editor);
if (obj instanceof IJavaElement)
EditorUtility.revealInEditor(editor, (IJavaElement) obj);
return;
}
}
}
}
private void setSelectionFromEditor(IWorkbenchPart part) {
if (part == null)
return;
IWorkbenchPartSite site= part.getSite();
if (site == null)
return;
ISelectionProvider provider= site.getSelectionProvider();
if (provider != null)
setSelectionFromEditor(part, provider.getSelection());
}
private void setSelectionFromEditor(IWorkbenchPart part, ISelection selection) {
if (part instanceof IEditorPart && JavaBrowsingPreferencePage.linkViewSelectionToEditor()) {
IEditorInput ei= ((IEditorPart)part).getEditorInput();
if (selection instanceof ITextSelection) {
int offset= ((ITextSelection)selection).getOffset();
IJavaElement element= getElementForInputAt(ei, offset);
if (element != null) {
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
adjustInputAndSetSelection(element);
return;
}
}
if (ei instanceof IFileEditorInput) {
IFile file= ((IFileEditorInput)ei).getFile();
IJavaElement je= (IJavaElement)file.getAdapter(IJavaElement.class);
if (je == null) {
setSelection(null, false);
return;
}
adjustInputAndSetSelection(je);
} else if (ei instanceof IClassFileEditorInput) {
IClassFile cf= ((IClassFileEditorInput)ei).getClassFile();
adjustInputAndSetSelection(cf);
}
return;
}
}
/**
* Returns the element contained in the EditorInput
*/
Object getElementOfInput(IEditorInput input) {
if (input instanceof IClassFileEditorInput)
return ((IClassFileEditorInput)input).getClassFile();
else if (input instanceof IFileEditorInput)
return ((IFileEditorInput)input).getFile();
else if (input instanceof JarEntryEditorInput)
return ((JarEntryEditorInput)input).getStorage();
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
return null;
}
private IResource getResourceFor(Object element) {
if (element instanceof IJavaElement) {
if (element instanceof IWorkingCopy) {
IWorkingCopy wc= (IWorkingCopy)element;
IJavaElement original= wc.getOriginalElement();
if (original != null)
element= original;
}
try {
element= ((IJavaElement)element).getUnderlyingResource();
} catch (JavaModelException e) {
return null;
}
}
if (!(element instanceof IResource) || ((IResource)element).isPhantom()) {
return null;
}
return (IResource)element;
}
private void setSelection(ISelection selection, boolean reveal) {
if (selection != null && selection.equals(fViewer.getSelection()))
return;
fProcessSelectionEvents= false;
fViewer.setSelection(selection, reveal);
fProcessSelectionEvents= true;
}
/**
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
* Tries to find the given element in a workingcopy.
*/
protected static IJavaElement getWorkingCopy(IJavaElement input) {
try {
if (input instanceof ICompilationUnit)
return EditorUtility.getWorkingCopy((ICompilationUnit)input);
else
return EditorUtility.getWorkingCopy(input, true);
} catch (JavaModelException ex) {
}
return null;
}
/**
* Returns the original element from which the specified working copy
* element was created from. This is a handle only method, the
* returned element may or may not exist.
*
* @param workingCopy the element for which to get the original
* @return the original Java element or <code>null</code> if this is not a working copy element
*/
protected static IJavaElement getOriginal(IJavaElement workingCopy) {
ICompilationUnit cu= getCompilationUnit(workingCopy);
if (cu != null)
return ((IWorkingCopy)cu).getOriginal(workingCopy);
return null;
}
/**
* Returns the compilation unit for the given java element.
*
* @param element the java element whose compilation unit is searched for
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
* @return the compilation unit of the given java element
*/
protected static ICompilationUnit getCompilationUnit(IJavaElement element) {
if (element == null)
return null;
if (element instanceof IMember)
return ((IMember) element).getCompilationUnit();
int type= element.getElementType();
if (IJavaElement.COMPILATION_UNIT == type)
return (ICompilationUnit) element;
if (IJavaElement.CLASS_FILE == type)
return null;
return getCompilationUnit(element.getParent());
}
/**
* Converts the given Java element to one which is suitable for this
* view. It takes into account wether the view shows working copies or not.
*
* @param element the Java element to be converted
* @return an element suitable for this view
*/
protected IJavaElement getSuitableJavaElement(Object obj) {
if (!(obj instanceof IJavaElement))
return null;
IJavaElement element= (IJavaElement)obj;
if (fTypeComparator.compare(element, IJavaElement.COMPILATION_UNIT) > 0)
return element;
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
if (element.getElementType() == IJavaElement.CLASS_FILE)
return element;
if (((BaseJavaElementContentProvider)getViewer().getContentProvider()).getProvideWorkingCopy()) {
IJavaElement wc= getWorkingCopy(element);
if (wc != null)
element= wc;
return element;
}
else {
ICompilationUnit cu= getCompilationUnit(element);
if (cu != null && ((IWorkingCopy)cu).isWorkingCopy())
return ((IWorkingCopy)cu).getOriginal(element);
else
return element;
}
}
/**
* @see JavaEditor#getElementAt(int)
*/
protected IJavaElement getElementForInputAt(IEditorInput input, int offset) {
if (input instanceof IClassFileEditorInput) {
try {
return ((IClassFileEditorInput)input).getClassFile().getElementAt(offset);
} catch (JavaModelException ex) {
return null;
}
}
IWorkingCopyManager manager= JavaPlugin.getDefault().getWorkingCopyManager();
ICompilationUnit unit= manager.getWorkingCopy(input);
if (unit != null)
|
12,053 |
Bug 12053 Allow mutli selection for all browsers
|
This should clear downstream
|
resolved fixed
|
740a438
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:40Z | 2002-03-21T17:00:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
synchronized (unit) {
try {
unit.reconcile(null);
return unit.getElementAt(offset);
} catch (JavaModelException x) {
}
}
return null;
}
protected IType getTypeForCU(ICompilationUnit cu) {
cu= (ICompilationUnit)getSuitableJavaElement(cu);
IType primaryType= JavaModelUtil.findPrimaryType(cu);
if (primaryType != null)
return primaryType;
try {
IType[] types= cu.getTypes();
if (types.length > 0)
return types[0];
else
return null;
} catch (JavaModelException ex) {
return null;
}
}
}
|
12,102 |
Bug 12102 AddImport in editor does not work for empty selection
|
Code resolve now works in that case and all actions must be adjusted
|
resolved fixed
|
0c19239
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:41Z | 2002-03-22T12:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/javaeditor/AddImportOnSelectionAction.java
|
package org.eclipse.jdt.internal.ui.javaeditor;
/*
* (c) Copyright IBM Corp. 2000, 2001.
* All Rights Reserved.
*/
import java.lang.reflect.InvocationTargetException;
import java.util.ArrayList;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.swt.widgets.Shell;
import org.eclipse.jface.action.Action;
|
12,102 |
Bug 12102 AddImport in editor does not work for empty selection
|
Code resolve now works in that case and all actions must be adjusted
|
resolved fixed
|
0c19239
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:41Z | 2002-03-22T12:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/javaeditor/AddImportOnSelectionAction.java
|
import org.eclipse.jface.dialogs.ErrorDialog;
import org.eclipse.jface.dialogs.MessageDialog;
import org.eclipse.jface.dialogs.ProgressMonitorDialog;
import org.eclipse.jface.text.BadLocationException;
import org.eclipse.jface.text.IDocument;
import org.eclipse.jface.text.ITextSelection;
import org.eclipse.jface.viewers.ISelection;
import org.eclipse.ui.help.WorkbenchHelp;
import org.eclipse.ui.texteditor.ITextEditor;
import org.eclipse.ui.texteditor.IUpdate;
import org.eclipse.jdt.core.ICompilationUnit;
import org.eclipse.jdt.core.IJavaElement;
import org.eclipse.jdt.core.IType;
import org.eclipse.jdt.core.Signature;
import org.eclipse.jdt.core.search.IJavaSearchConstants;
import org.eclipse.jdt.core.search.IJavaSearchScope;
import org.eclipse.jdt.core.search.ITypeNameRequestor;
import org.eclipse.jdt.core.search.SearchEngine;
import org.eclipse.jdt.ui.IWorkingCopyManager;
import org.eclipse.jdt.internal.corext.codemanipulation.AddImportsOperation;
import org.eclipse.jdt.internal.corext.codemanipulation.CodeGenerationSettings;
import org.eclipse.jdt.internal.corext.util.TypeInfo;
import org.eclipse.jdt.internal.corext.util.TypeInfoRequestor;
import org.eclipse.jdt.internal.ui.IJavaHelpContextIds;
import org.eclipse.jdt.internal.ui.JavaPlugin;
import org.eclipse.jdt.internal.ui.actions.WorkbenchRunnableAdapter;
import org.eclipse.jdt.internal.ui.dialogs.ElementListSelectionDialog;
import org.eclipse.jdt.internal.ui.preferences.JavaPreferencesSettings;
import org.eclipse.jdt.internal.ui.util.TypeInfoLabelProvider;
public class AddImportOnSelectionAction extends Action implements IUpdate {
|
12,102 |
Bug 12102 AddImport in editor does not work for empty selection
|
Code resolve now works in that case and all actions must be adjusted
|
resolved fixed
|
0c19239
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:41Z | 2002-03-22T12:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/javaeditor/AddImportOnSelectionAction.java
|
private ITextEditor fEditor;
public AddImportOnSelectionAction(ITextEditor editor) {
super(JavaEditorMessages.getString("AddImportOnSelection.label"));
setToolTipText(JavaEditorMessages.getString("AddImportOnSelection.tooltip"));
setDescription(JavaEditorMessages.getString("AddImportOnSelection.description"));
fEditor= editor;
WorkbenchHelp.setHelp(this, IJavaHelpContextIds.ADD_IMPORT_ON_SELECTION_ACTION);
}
public AddImportOnSelectionAction() {
this(null);
}
public void setContentEditor(ITextEditor editor) {
fEditor= editor;
}
public void update() {
boolean isEnabled= false;
ISelection selection= fEditor.getSelectionProvider().getSelection();
if (selection instanceof ITextSelection) {
isEnabled= (((ITextSelection)selection).getLength() > 0);
}
setEnabled(isEnabled);
}
|
12,102 |
Bug 12102 AddImport in editor does not work for empty selection
|
Code resolve now works in that case and all actions must be adjusted
|
resolved fixed
|
0c19239
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:41Z | 2002-03-22T12:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/javaeditor/AddImportOnSelectionAction.java
|
private ICompilationUnit getCompilationUnit () {
IWorkingCopyManager manager= JavaPlugin.getDefault().getWorkingCopyManager();
return manager.getWorkingCopy(fEditor.getEditorInput());
}
/**
* @see IAction#actionPerformed
*/
public void run() {
ICompilationUnit cu= getCompilationUnit();
if (cu != null) {
ISelection s= fEditor.getSelectionProvider().getSelection();
IDocument doc= fEditor.getDocumentProvider().getDocument(fEditor.getEditorInput());
ITextSelection selection= (ITextSelection) s;
if (selection.getLength() > 0 && doc != null) {
try {
int selStart= selection.getOffset();
int nameStart= getNameStart(doc, selStart);
int len= selStart - nameStart + selection.getLength();
String name= doc.get(nameStart, len).trim();
String simpleName= Signature.getSimpleName(name);
String containerName= Signature.getQualifier(name);
IJavaSearchScope searchScope= SearchEngine.createJavaSearchScope(new IJavaElement[] { cu.getJavaProject() });
TypeInfo[] types= findAllTypes(simpleName, searchScope, null);
if (types.length== 0) {
|
12,102 |
Bug 12102 AddImport in editor does not work for empty selection
|
Code resolve now works in that case and all actions must be adjusted
|
resolved fixed
|
0c19239
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:41Z | 2002-03-22T12:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/javaeditor/AddImportOnSelectionAction.java
|
getShell().getDisplay().beep();
return;
}
TypeInfo chosen= selectResult(types, containerName, getShell());
if (chosen == null) {
return;
}
IType type= chosen.resolveType(searchScope);
if (type == null) {
JavaPlugin.logErrorMessage("AddImportOnSelectionAction: Failed to resolve TypeRef: " + chosen.toString());
MessageDialog.openError(getShell(), JavaEditorMessages.getString("AddImportOnSelection.error.title"), JavaEditorMessages.getString("AddImportOnSelection.error.notresolved.message"));
return;
}
removeQualification(doc, nameStart, chosen);
CodeGenerationSettings settings= JavaPreferencesSettings.getCodeGenerationSettings();
AddImportsOperation op= new AddImportsOperation(cu, new IJavaElement[] { type }, settings, false);
ProgressMonitorDialog dialog= new ProgressMonitorDialog(getShell());
try {
dialog.run(false, true, new WorkbenchRunnableAdapter(op));
} catch (InvocationTargetException e) {
JavaPlugin.log(e);
MessageDialog.openError(getShell(), JavaEditorMessages.getString("AddImportOnSelection.error.title"), e.getTargetException().getMessage());
} catch (InterruptedException e) {
}
return;
} catch (CoreException e) {
JavaPlugin.log(e);
|
12,102 |
Bug 12102 AddImport in editor does not work for empty selection
|
Code resolve now works in that case and all actions must be adjusted
|
resolved fixed
|
0c19239
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:41Z | 2002-03-22T12:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/javaeditor/AddImportOnSelectionAction.java
|
ErrorDialog.openError(getShell(), JavaEditorMessages.getString("AddImportOnSelection.error.title"), null, e.getStatus());
} catch (BadLocationException e) {
JavaPlugin.log(e);
MessageDialog.openError(getShell(), JavaEditorMessages.getString("AddImportOnSelection.error.title"), e.getMessage());
}
}
}
}
private int getNameStart(IDocument doc, int pos) throws BadLocationException {
if (pos > 0 && doc.getChar(pos - 1) == '.') {
pos--;
while (pos > 0) {
char ch= doc.getChar(pos - 1);
if (!Character.isJavaIdentifierPart(ch) && ch != '.') {
return pos;
}
pos--;
}
}
return pos;
}
private void removeQualification(IDocument doc, int nameStart, TypeInfo typeInfo) throws BadLocationException {
String containerName= typeInfo.getTypeContainerName();
int containerLen= containerName.length();
if (containerLen > 0) {
for (int k= 0; k < containerLen; k++) {
if (doc.getChar(nameStart + k) != containerName.charAt(k)) {
return;
|
12,102 |
Bug 12102 AddImport in editor does not work for empty selection
|
Code resolve now works in that case and all actions must be adjusted
|
resolved fixed
|
0c19239
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:41Z | 2002-03-22T12:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/javaeditor/AddImportOnSelectionAction.java
|
}
}
doc.replace(nameStart, containerLen + 1, "");
}
}
/**
* Finds a type by the simple name.
*/
private static TypeInfo[] findAllTypes(String simpleTypeName, IJavaSearchScope searchScope, IProgressMonitor monitor) throws CoreException {
SearchEngine searchEngine= new SearchEngine();
ArrayList typeRefsFound= new ArrayList(10);
ITypeNameRequestor requestor= new TypeInfoRequestor(typeRefsFound);
searchEngine.searchAllTypeNames(
JavaPlugin.getWorkspace(),
null,
simpleTypeName.toCharArray(),
IJavaSearchConstants.EXACT_MATCH,
IJavaSearchConstants.CASE_SENSITIVE,
IJavaSearchConstants.TYPE,
searchScope,
requestor,
IJavaSearchConstants.WAIT_UNTIL_READY_TO_SEARCH,
monitor);
return (TypeInfo[]) typeRefsFound.toArray(new TypeInfo[typeRefsFound.size()]);
}
private Shell getShell() {
return fEditor.getSite().getShell();
|
12,102 |
Bug 12102 AddImport in editor does not work for empty selection
|
Code resolve now works in that case and all actions must be adjusted
|
resolved fixed
|
0c19239
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T14:59:41Z | 2002-03-22T12:26:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/javaeditor/AddImportOnSelectionAction.java
|
}
private TypeInfo selectResult(TypeInfo[] results, String containerName, Shell shell) {
int nResults= results.length;
if (nResults == 0) {
return null;
} else if (nResults == 1) {
return results[0];
}
if (containerName.length() != 0) {
for (int i= 0; i < nResults; i++) {
TypeInfo curr= (TypeInfo) results[i];
if (containerName.equals(curr.getTypeContainerName())) {
return curr;
}
}
}
ElementListSelectionDialog dialog= new ElementListSelectionDialog(getShell(), new TypeInfoLabelProvider(TypeInfoLabelProvider.SHOW_FULLYQUALIFIED));
dialog.setTitle(JavaEditorMessages.getString("AddImportOnSelection.dialog.title"));
dialog.setMessage(JavaEditorMessages.getString("AddImportOnSelection.dialog.message"));
dialog.setElements(results);
if (dialog.open() == dialog.OK) {
return (TypeInfo) dialog.getFirstResult();
}
return null;
}
}
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
/*
* (c) Copyright IBM Corp. 2000, 2001.
* All Rights Reserved.
*/
package org.eclipse.jdt.ui.wizards;
import java.lang.reflect.InvocationTargetException;
import java.util.ArrayList;
import java.util.List;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.NullProgressMonitor;
import org.eclipse.core.runtime.SubProgressMonitor;
import org.eclipse.swt.SWT;
import org.eclipse.swt.graphics.Image;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.layout.GridLayout;
import org.eclipse.swt.widgets.Button;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
import org.eclipse.jface.operation.IRunnableWithProgress;
import org.eclipse.jface.viewers.LabelProvider;
import org.eclipse.jdt.core.Flags;
import org.eclipse.jdt.core.IBuffer;
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
import org.eclipse.jdt.core.ICompilationUnit;
import org.eclipse.jdt.core.IJavaElement;
import org.eclipse.jdt.core.IJavaProject;
import org.eclipse.jdt.core.IMethod;
import org.eclipse.jdt.core.IPackageFragment;
import org.eclipse.jdt.core.IPackageFragmentRoot;
import org.eclipse.jdt.core.ISourceRange;
import org.eclipse.jdt.core.IType;
import org.eclipse.jdt.core.ITypeHierarchy;
import org.eclipse.jdt.core.JavaConventions;
import org.eclipse.jdt.core.JavaModelException;
import org.eclipse.jdt.core.Signature;
import org.eclipse.jdt.core.search.IJavaSearchConstants;
import org.eclipse.jdt.core.search.IJavaSearchScope;
import org.eclipse.jdt.core.search.SearchEngine;
import org.eclipse.jdt.ui.JavaElementLabelProvider;
import org.eclipse.jdt.internal.compiler.env.IConstants;
import org.eclipse.jdt.internal.corext.codemanipulation.CodeGenerationSettings;
import org.eclipse.jdt.internal.corext.codemanipulation.IImportsStructure;
import org.eclipse.jdt.internal.corext.codemanipulation.ImportsStructure;
import org.eclipse.jdt.internal.corext.codemanipulation.StubUtility;
import org.eclipse.jdt.internal.corext.template.Template;
import org.eclipse.jdt.internal.corext.template.Templates;
import org.eclipse.jdt.internal.corext.template.java.JavaContext;
import org.eclipse.jdt.internal.corext.util.JavaModelUtil;
import org.eclipse.jdt.internal.ui.JavaPlugin;
import org.eclipse.jdt.internal.ui.JavaPluginImages;
import org.eclipse.jdt.internal.ui.dialogs.ElementListSelectionDialog;
import org.eclipse.jdt.internal.ui.dialogs.StatusInfo;
import org.eclipse.jdt.internal.ui.dialogs.TypeSelectionDialog;
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
import org.eclipse.jdt.internal.ui.javaeditor.EditorUtility;
import org.eclipse.jdt.internal.ui.preferences.CodeGenerationPreferencePage;
import org.eclipse.jdt.internal.ui.preferences.ImportOrganizePreferencePage;
import org.eclipse.jdt.internal.ui.preferences.JavaPreferencesSettings;
import org.eclipse.jdt.internal.ui.util.SWTUtil;
import org.eclipse.jdt.internal.ui.wizards.NewWizardMessages;
import org.eclipse.jdt.internal.ui.wizards.SuperInterfaceSelectionDialog;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.DialogField;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.IDialogFieldListener;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.IListAdapter;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.IStringButtonAdapter;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.LayoutUtil;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.ListDialogField;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.SelectionButtonDialogField;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.SelectionButtonDialogFieldGroup;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.Separator;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.StringButtonDialogField;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.StringButtonStatusDialogField;
import org.eclipse.jdt.internal.ui.wizards.dialogfields.StringDialogField;
/**
* <code>NewTypeWizardPage</code> contains controls and validation routines for a 'New Type WizardPage'
* Implementors decide which components to add and to enable. Implementors can also
* customize the validation code.
* <code>NewTypeWizardPage</code> is intended to serve as base class of all wizards that create types.
* Applets, Servlets, Classes, Interfaces...
* See <code>NewClassWizardPage</code> or <code>NewInterfaceWizardPage</code> for an
* example usage of NewTypeWizardPage.
* @since 2.0
*/
public abstract class NewTypeWizardPage extends NewContainerWizardPage {
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
private final static String PAGE_NAME= "NewTypeWizardPage";
protected final static String PACKAGE= PAGE_NAME + ".package";
protected final static String ENCLOSING= PAGE_NAME + ".enclosing";
protected final static String ENCLOSINGSELECTION= ENCLOSING + ".selection";
protected final static String TYPENAME= PAGE_NAME + ".typename";
protected final static String SUPER= PAGE_NAME + ".superclass";
protected final static String INTERFACES= PAGE_NAME + ".interfaces";
protected final static String MODIFIERS= PAGE_NAME + ".modifiers";
protected final static String METHODS= PAGE_NAME + ".methods";
private class InterfacesListLabelProvider extends LabelProvider {
private Image fInterfaceImage;
public InterfacesListLabelProvider() {
super();
fInterfaceImage= JavaPluginImages.get(JavaPluginImages.IMG_OBJS_INTERFACE);
}
public Image getImage(Object element) {
return fInterfaceImage;
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
}
}
private StringButtonStatusDialogField fPackageDialogField;
private SelectionButtonDialogField fEnclosingTypeSelection;
private StringButtonDialogField fEnclosingTypeDialogField;
private boolean fCanModifyPackage;
private boolean fCanModifyEnclosingType;
private IPackageFragment fCurrPackage;
private IType fCurrEnclosingType;
private StringDialogField fTypeNameDialogField;
private StringButtonDialogField fSuperClassDialogField;
private ListDialogField fSuperInterfacesDialogField;
private IType fSuperClass;
private SelectionButtonDialogFieldGroup fAccMdfButtons;
private SelectionButtonDialogFieldGroup fOtherMdfButtons;
private IType fCreatedType;
protected IStatus fEnclosingTypeStatus;
protected IStatus fPackageStatus;
protected IStatus fTypeNameStatus;
protected IStatus fSuperClassStatus;
protected IStatus fModifierStatus;
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
protected IStatus fSuperInterfacesStatus;
private boolean fIsClass;
private int fStaticMdfIndex;
private final int PUBLIC_INDEX= 0, DEFAULT_INDEX= 1, PRIVATE_INDEX= 2, PROTECTED_INDEX= 3;
private final int ABSTRACT_INDEX= 0, FINAL_INDEX= 1;
public NewTypeWizardPage(boolean isClass, String pageName) {
super(pageName);
fCreatedType= null;
fIsClass= isClass;
TypeFieldsAdapter adapter= new TypeFieldsAdapter();
fPackageDialogField= new StringButtonStatusDialogField(adapter);
fPackageDialogField.setDialogFieldListener(adapter);
fPackageDialogField.setLabelText(NewWizardMessages.getString("NewTypeWizardPage.package.label"));
fPackageDialogField.setButtonLabel(NewWizardMessages.getString("NewTypeWizardPage.package.button"));
fPackageDialogField.setStatusWidthHint(NewWizardMessages.getString("NewTypeWizardPage.default"));
fEnclosingTypeSelection= new SelectionButtonDialogField(SWT.CHECK);
fEnclosingTypeSelection.setDialogFieldListener(adapter);
fEnclosingTypeSelection.setLabelText(NewWizardMessages.getString("NewTypeWizardPage.enclosing.selection.label"));
fEnclosingTypeDialogField= new StringButtonDialogField(adapter);
fEnclosingTypeDialogField.setDialogFieldListener(adapter);
fEnclosingTypeDialogField.setButtonLabel(NewWizardMessages.getString("NewTypeWizardPage.enclosing.button"));
fTypeNameDialogField= new StringDialogField();
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
fTypeNameDialogField.setDialogFieldListener(adapter);
fTypeNameDialogField.setLabelText(NewWizardMessages.getString("NewTypeWizardPage.typename.label"));
fSuperClassDialogField= new StringButtonDialogField(adapter);
fSuperClassDialogField.setDialogFieldListener(adapter);
fSuperClassDialogField.setLabelText(NewWizardMessages.getString("NewTypeWizardPage.superclass.label"));
fSuperClassDialogField.setButtonLabel(NewWizardMessages.getString("NewTypeWizardPage.superclass.button"));
String[] addButtons= new String[] {
NewWizardMessages.getString("NewTypeWizardPage.interfaces.add"),
null,
NewWizardMessages.getString("NewTypeWizardPage.interfaces.remove")
};
fSuperInterfacesDialogField= new ListDialogField(adapter, addButtons, new InterfacesListLabelProvider());
fSuperInterfacesDialogField.setDialogFieldListener(adapter);
String interfaceLabel= fIsClass ? NewWizardMessages.getString("NewTypeWizardPage.interfaces.class.label") : NewWizardMessages.getString("NewTypeWizardPage.interfaces.ifc.label");
fSuperInterfacesDialogField.setLabelText(interfaceLabel);
fSuperInterfacesDialogField.setRemoveButtonIndex(2);
String[] buttonNames1= new String[] {
NewWizardMessages.getString("NewTypeWizardPage.modifiers.public"),
NewWizardMessages.getString("NewTypeWizardPage.modifiers.default"),
NewWizardMessages.getString("NewTypeWizardPage.modifiers.private"),
NewWizardMessages.getString("NewTypeWizardPage.modifiers.protected")
};
fAccMdfButtons= new SelectionButtonDialogFieldGroup(SWT.RADIO, buttonNames1, 4);
fAccMdfButtons.setDialogFieldListener(adapter);
fAccMdfButtons.setLabelText(NewWizardMessages.getString("NewTypeWizardPage.modifiers.acc.label"));
fAccMdfButtons.setSelection(0, true);
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
String[] buttonNames2;
if (fIsClass) {
buttonNames2= new String[] {
NewWizardMessages.getString("NewTypeWizardPage.modifiers.abstract"),
NewWizardMessages.getString("NewTypeWizardPage.modifiers.final"),
NewWizardMessages.getString("NewTypeWizardPage.modifiers.static")
};
fStaticMdfIndex= 2;
} else {
buttonNames2= new String[] {
NewWizardMessages.getString("NewTypeWizardPage.modifiers.static")
};
fStaticMdfIndex= 0;
}
fOtherMdfButtons= new SelectionButtonDialogFieldGroup(SWT.CHECK, buttonNames2, 4);
fOtherMdfButtons.setDialogFieldListener(adapter);
fAccMdfButtons.enableSelectionButton(PRIVATE_INDEX, false);
fAccMdfButtons.enableSelectionButton(PROTECTED_INDEX, false);
fOtherMdfButtons.enableSelectionButton(fStaticMdfIndex, false);
fPackageStatus= new StatusInfo();
fEnclosingTypeStatus= new StatusInfo();
fCanModifyPackage= true;
fCanModifyEnclosingType= true;
updateEnableState();
fTypeNameStatus= new StatusInfo();
fSuperClassStatus= new StatusInfo();
fSuperInterfacesStatus= new StatusInfo();
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
fModifierStatus= new StatusInfo();
}
/**
* Initializes all fields provided by the type page with a given
* Java element as selection. To implement a different selection strategy do not call this
* method or overwrite it.
* @param elem The initial selection of this page or null if no
* selection was available
*/
protected void initTypePage(IJavaElement elem) {
String initSuperclass= "java.lang.Object";
ArrayList initSuperinterfaces= new ArrayList(5);
IPackageFragment pack= null;
IType enclosingType= null;
if (elem != null) {
pack= (IPackageFragment) JavaModelUtil.findElementOfKind(elem, IJavaElement.PACKAGE_FRAGMENT);
IType typeInCU= (IType) JavaModelUtil.findElementOfKind(elem, IJavaElement.TYPE);
if (typeInCU != null) {
if (typeInCU.getCompilationUnit() != null) {
enclosingType= typeInCU;
}
} else {
ICompilationUnit cu= (ICompilationUnit) JavaModelUtil.findElementOfKind(elem, IJavaElement.COMPILATION_UNIT);
if (cu != null) {
enclosingType= JavaModelUtil.findPrimaryType(cu);
}
}
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
try {
IType type= null;
if (elem.getElementType() == IJavaElement.TYPE) {
type= (IType)elem;
if (type.exists()) {
String superName= JavaModelUtil.getFullyQualifiedName(type);
if (type.isInterface()) {
initSuperinterfaces.add(superName);
} else {
initSuperclass= superName;
}
}
}
} catch (JavaModelException e) {
JavaPlugin.log(e);
}
}
setPackageFragment(pack, true);
setEnclosingType(enclosingType, true);
setEnclosingTypeSelection(false, true);
setTypeName("", true);
setSuperClass(initSuperclass, true);
setSuperInterfaces(initSuperinterfaces, true);
}
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
/**
* Creates a separator line. Expects a GridLayout with at least 1 column.
* @param composite The parent composite
* @param nColumns Number of columns to span
*/
protected void createSeparator(Composite composite, int nColumns) {
(new Separator(SWT.SEPARATOR | SWT.HORIZONTAL)).doFillIntoGrid(composite, nColumns, convertHeightInCharsToPixels(1));
}
/**
* Creates the controls for the package name field. Expects a GridLayout with at least 4 columns.
* @param composite The parent composite
* @param nColumns Number of columns to span
*/
protected void createPackageControls(Composite composite, int nColumns) {
fPackageDialogField.doFillIntoGrid(composite, nColumns);
LayoutUtil.setWidthHint(fPackageDialogField.getTextControl(null), getMaxFieldWidth());
LayoutUtil.setHorizontalGrabbing(fPackageDialogField.getTextControl(null));
}
/**
* Creates the controls for the enclosing type name field. Expects a GridLayout with at least 4 columns.
* @param composite The parent composite
* @param nColumns Number of columns to span
*/
protected void createEnclosingTypeControls(Composite composite, int nColumns) {
Composite tabGroup= new Composite(composite, SWT.NONE);
GridLayout layout= new GridLayout();
layout.marginWidth= 0;
layout.marginHeight= 0;
tabGroup.setLayout(layout);
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
fEnclosingTypeSelection.doFillIntoGrid(tabGroup, 1);
Control c= fEnclosingTypeDialogField.getTextControl(composite);
GridData gd= new GridData(GridData.FILL_HORIZONTAL);
gd.widthHint= getMaxFieldWidth();
gd.horizontalSpan= 2;
c.setLayoutData(gd);
Button button= fEnclosingTypeDialogField.getChangeControl(composite);
gd= new GridData(GridData.HORIZONTAL_ALIGN_FILL);
gd.heightHint = SWTUtil.getButtonHeigthHint(button);
gd.widthHint = SWTUtil.getButtonWidthHint(button);
button.setLayoutData(gd);
}
/**
* Creates the controls for the type name field. Expects a GridLayout with at least 2 columns.
* @param composite The parent composite
* @param nColumns Number of columns to span
*/
protected void createTypeNameControls(Composite composite, int nColumns) {
fTypeNameDialogField.doFillIntoGrid(composite, nColumns - 1);
DialogField.createEmptySpace(composite);
LayoutUtil.setWidthHint(fTypeNameDialogField.getTextControl(null), getMaxFieldWidth());
}
/**
* Creates the controls for the modifiers radio/ceckbox buttons. Expects a GridLayout with at least 3 columns.
* @param composite The parent composite
* @param nColumns Number of columns to span
*/
protected void createModifierControls(Composite composite, int nColumns) {
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
LayoutUtil.setHorizontalSpan(fAccMdfButtons.getLabelControl(composite), 1);
Control control= fAccMdfButtons.getSelectionButtonsGroup(composite);
GridData gd= new GridData(GridData.HORIZONTAL_ALIGN_FILL);
gd.horizontalSpan= nColumns - 2;
control.setLayoutData(gd);
DialogField.createEmptySpace(composite);
DialogField.createEmptySpace(composite);
control= fOtherMdfButtons.getSelectionButtonsGroup(composite);
gd= new GridData(GridData.HORIZONTAL_ALIGN_FILL);
gd.horizontalSpan= nColumns - 2;
control.setLayoutData(gd);
DialogField.createEmptySpace(composite);
}
/**
* Creates the controls for the superclass name field. Expects a GridLayout with at least 3 columns.
* @param composite The parent composite
* @param nColumns Number of columns to span
*/
protected void createSuperClassControls(Composite composite, int nColumns) {
fSuperClassDialogField.doFillIntoGrid(composite, nColumns);
LayoutUtil.setWidthHint(fSuperClassDialogField.getTextControl(null), getMaxFieldWidth());
}
/**
* Creates the controls for the superclass name field. Expects a GridLayout with at least 3 columns.
* @param composite The parent composite
* @param nColumns Number of columns to span
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
*/
protected void createSuperInterfacesControls(Composite composite, int nColumns) {
fSuperInterfacesDialogField.doFillIntoGrid(composite, nColumns);
GridData gd= (GridData)fSuperInterfacesDialogField.getListControl(null).getLayoutData();
if (fIsClass) {
gd.heightHint= convertHeightInCharsToPixels(3);
} else {
gd.heightHint= convertHeightInCharsToPixels(6);
}
gd.grabExcessVerticalSpace= false;
gd.widthHint= getMaxFieldWidth();
}
/**
* Sets the focus on the type name.
*/
protected void setFocus() {
fTypeNameDialogField.setFocus();
}
private class TypeFieldsAdapter implements IStringButtonAdapter, IDialogFieldListener, IListAdapter {
public void changeControlPressed(DialogField field) {
typePageChangeControlPressed(field);
}
public void customButtonPressed(DialogField field, int index) {
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
typePageCustomButtonPressed(field, index);
}
public void selectionChanged(DialogField field) {}
public void dialogFieldChanged(DialogField field) {
typePageDialogFieldChanged(field);
}
}
private void typePageChangeControlPressed(DialogField field) {
if (field == fPackageDialogField) {
IPackageFragment pack= choosePackage();
if (pack != null) {
fPackageDialogField.setText(pack.getElementName());
}
} else if (field == fEnclosingTypeDialogField) {
IType type= chooseEnclosingType();
if (type != null) {
fEnclosingTypeDialogField.setText(JavaModelUtil.getFullyQualifiedName(type));
}
} else if (field == fSuperClassDialogField) {
IType type= chooseSuperType();
if (type != null) {
fSuperClassDialogField.setText(JavaModelUtil.getFullyQualifiedName(type));
}
}
}
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
private void typePageCustomButtonPressed(DialogField field, int index) {
if (field == fSuperInterfacesDialogField) {
chooseSuperInterfaces();
}
}
/*
* A field on the type has changed. The fields' status and all dependend
* status are updated.
*/
private void typePageDialogFieldChanged(DialogField field) {
String fieldName= null;
if (field == fPackageDialogField) {
fPackageStatus= packageChanged();
updatePackageStatusLabel();
fTypeNameStatus= typeNameChanged();
fSuperClassStatus= superClassChanged();
fieldName= PACKAGE;
} else if (field == fEnclosingTypeDialogField) {
fEnclosingTypeStatus= enclosingTypeChanged();
fTypeNameStatus= typeNameChanged();
fSuperClassStatus= superClassChanged();
fieldName= ENCLOSING;
} else if (field == fEnclosingTypeSelection) {
updateEnableState();
boolean isEnclosedType= isEnclosingTypeSelected();
if (!isEnclosedType) {
if (fAccMdfButtons.isSelected(PRIVATE_INDEX) || fAccMdfButtons.isSelected(PROTECTED_INDEX)) {
fAccMdfButtons.setSelection(PRIVATE_INDEX, false);
fAccMdfButtons.setSelection(PROTECTED_INDEX, false);
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
fAccMdfButtons.setSelection(PUBLIC_INDEX, true);
}
if (fOtherMdfButtons.isSelected(fStaticMdfIndex)) {
fOtherMdfButtons.setSelection(fStaticMdfIndex, false);
}
}
fAccMdfButtons.enableSelectionButton(PRIVATE_INDEX, isEnclosedType && fIsClass);
fAccMdfButtons.enableSelectionButton(PROTECTED_INDEX, isEnclosedType && fIsClass);
fOtherMdfButtons.enableSelectionButton(fStaticMdfIndex, isEnclosedType);
fTypeNameStatus= typeNameChanged();
fSuperClassStatus= superClassChanged();
fieldName= ENCLOSINGSELECTION;
} else if (field == fTypeNameDialogField) {
fTypeNameStatus= typeNameChanged();
fieldName= TYPENAME;
} else if (field == fSuperClassDialogField) {
fSuperClassStatus= superClassChanged();
fieldName= SUPER;
} else if (field == fSuperInterfacesDialogField) {
fSuperInterfacesStatus= superInterfacesChanged();
fieldName= INTERFACES;
} else if (field == fOtherMdfButtons) {
fModifierStatus= modifiersChanged();
fieldName= MODIFIERS;
} else {
fieldName= METHODS;
}
handleFieldChanged(fieldName);
}
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
/**
* Called whenever a content of a field has changed.
* Implementors of NewTypeWizardPage can hook in.
* @see ContainerPage#handleFieldChanged
*/
protected void handleFieldChanged(String fieldName) {
super.handleFieldChanged(fieldName);
if (fieldName == CONTAINER) {
fPackageStatus= packageChanged();
fEnclosingTypeStatus= enclosingTypeChanged();
fTypeNameStatus= typeNameChanged();
fSuperClassStatus= superClassChanged();
fSuperInterfacesStatus= superInterfacesChanged();
}
}
/**
* Gets the text of package field.
*/
public String getPackageText() {
return fPackageDialogField.getText();
}
/**
* Gets the text of enclosing type field.
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
*/
public String getEnclosingTypeText() {
return fEnclosingTypeDialogField.getText();
}
/**
* Returns the package fragment corresponding to the current input.
* @return Returns <code>null</code> if the input could not be resolved.
*/
public IPackageFragment getPackageFragment() {
if (!isEnclosingTypeSelected()) {
return fCurrPackage;
} else {
if (fCurrEnclosingType != null) {
return fCurrEnclosingType.getPackageFragment();
}
}
return null;
}
/**
* Sets the package fragment.
* This will update model and the text of the control.
* @param canBeModified Selects if the package fragment can be changed by the user
*/
public void setPackageFragment(IPackageFragment pack, boolean canBeModified) {
fCurrPackage= pack;
fCanModifyPackage= canBeModified;
String str= (pack == null) ? "" : pack.getElementName();
|
12,108 |
Bug 12108 NewTypeWizardPage hard to use in non-existing java project
|
I use the NewTypeWizardPage to create a type in a java project that does not exist. To achieve this, I override methods containerChanged() and packageChanged() with implementations that only return new Status(). Note that hthis class is in an internal package. I would like to validate the package name that the user enters, but for non-existing java projects, packageChanged() always logs the following exception: 4 org.eclipse.jdt.ui 1 Internal Error Java Model Exception: Java Model Status [B does not exist.] Stack trace: java/lang/Throwable.<init>()V java/lang/Throwable.<init>(Ljava/lang/String;)V org/eclipse/core/runtime/CoreException.<init>(Lorg/eclipse/core/runtime/IStatus;)V org/eclipse/jdt/core/JavaModelException.<init>(Lorg/eclipse/jdt/core/IJavaModelStatus;)V org/eclipse/jdt/internal/core/JavaElement.newNotPresentException()Lorg/eclipse/jdt/core/JavaModelException; org/eclipse/jdt/internal/core/JavaProject.openWhenClosed(Lorg/eclipse/core/runtime/IProgressMonitor;Lorg/eclipse/jdt/core/IBuffer;)V org/eclipse/jdt/internal/core/JavaElement.openHierarchy()V org/eclipse/jdt/internal/core/JavaElement.getElementInfo()Lorg/eclipse/jdt/internal/core/JavaElementInfo; org/eclipse/jdt/internal/core/JavaProject.getJavaProjectElementInfo()Lorg/eclipse/jdt/internal/core/JavaProjectElementInfo; org/eclipse/jdt/internal/core/JavaProject.getOutputLocation()Lorg/eclipse/core/runtime/IPath; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.packageChanged()Lorg/eclipse/core/runtime/IStatus; org/eclipse/jdt/ui/wizards/NewTypeWizardPage.handleFieldChanged(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.containerDialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.access$1(Lorg/eclipse/jdt/ui/wizards/NewContainerWizardPage;Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage$ContainerFieldAdapter.dialogFieldChanged(Lorg/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField;)V org/eclipse/jdt/internal/ui/wizards/dialogfields/DialogField.dialogFieldChanged()V org/eclipse/jdt/internal/ui/wizards/dialogfields/StringDialogField.setText(Ljava/lang/String;)V org/eclipse/jdt/ui/wizards/NewContainerWizardPage.setPackageFragmentRoot(Lorg/eclipse/jdt/core/IPackageFragmentRoot;Z)V com/ibm/ive/jxe/newwizards/InnerClassCreationPage.setProject(Lorg/eclipse/jdt/core/IJavaProject;)V com/ibm/ive/midp/wizard/MIDletSuitePage.projectUpdated()V com/ibm/ive/midp/wizard/MIDletSuitePage.access$0(Lcom/ibm/ive/midp/wizard/MIDletSuitePage;)V com/ibm/ive/midp/wizard/MIDletSuitePage$1.modifyText(Lorg/eclipse/swt/events/ModifyEvent;)V org/eclipse/swt/widgets/TypedListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.sendEvent(I)V org/eclipse/swt/widgets/Text.wmCommandChild(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.WM_COMMAND(II)Lorg/eclipse/swt/internal/win32/LRESULT; org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.CallWindowProcW(IIIII)I org/eclipse/swt/internal/win32/OS.CallWindowProc(IIIII)I org/eclipse/swt/widgets/Text.callWindowProc(III)I org/eclipse/swt/widgets/Control.windowProc(III)I org/eclipse/swt/widgets/Display.windowProc(IIII)I org/eclipse/swt/internal/win32/OS.DispatchMessageW(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/internal/win32/OS.DispatchMessage(Lorg/eclipse/swt/internal/win32/MSG;)I org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/jface/window/Window.runEventLoop(Lorg/eclipse/swt/widgets/Shell;)V org/eclipse/jface/window/Window.open()I org/eclipse/ui/actions/NewWizardAction.run()V org/eclipse/ui/internal/NewWizardDropDownAction.run()V org/eclipse/jface/action/Action.runWithEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetSelection(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.handleWidgetEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem.access$0(Lorg/eclipse/jface/action/ActionContributionItem;Lorg/eclipse/swt/widgets/Event;)V org/eclipse/jface/action/ActionContributionItem$ActionListener.handleEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/EventTable.sendEvent(Lorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Widget.notifyListeners(ILorg/eclipse/swt/widgets/Event;)V org/eclipse/swt/widgets/Display.runDeferredEvents()Z org/eclipse/swt/widgets/Display.readAndDispatch()Z org/eclipse/ui/internal/Workbench.runEventLoop()V org/eclipse/ui/internal/Workbench.run(Ljava/lang/Object;)Ljava/lang/Object; org/eclipse/core/internal/boot/InternalBootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; org/eclipse/core/boot/BootLoader.run(Ljava/lang/String;Ljava/net/URL;Ljava/lang/String;[Ljava/lang/String;)Ljava/lang/Object; EclipseRuntimeLauncher.main([Ljava/lang/String;)V 4 org.eclipse.jdt.core 969 B does not exist.
|
resolved fixed
|
24b70db
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-03-22T16:27:53Z | 2002-03-22T15:13:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/wizards/NewTypeWizardPage.java
|
fPackageDialogField.setText(str);
updateEnableState();
}
/**
* Returns the enclosing type corresponding to the current input.
* @return Returns <code>null</code> if enclosing type is not selected or the input could not
* be resolved.
*/
public IType getEnclosingType() {
if (isEnclosingTypeSelected()) {
return fCurrEnclosingType;
}
return null;
}
/**
* Sets the enclosing type.
* This will update model and the text of the control.
* @param canBeModified Selects if the enclosing type can be changed by the user
*/
public void setEnclosingType(IType type, boolean canBeModified) {
fCurrEnclosingType= type;
fCanModifyEnclosingType= canBeModified;
String str= (type == null) ? "" : JavaModelUtil.getFullyQualifiedName(type);
fEnclosingTypeDialogField.setText(str);
updateEnableState();
}
/**
* Returns <code>true</code> if the enclosing type selection check box is enabled.
*/
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.