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
|
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
17,383 |
Bug 17383 create getter/setter - no explicit hint if getter/setter already exist
|
Create getter/setter seems to know which getter/setters exist already. However, there's no explicit way to show this. I can figure out by selecting the type (only not existing getter/setter are shown). If I select a field, I see all the setter/getter of the type and I loose the information which setter and getter exist already.
|
verified fixed
|
b14dfd0
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T15:11:06Z | 2002-05-23T16:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/AddGetterSetterAction.java
|
cu= fld.getCompilationUnit();
if (cu == null) {
return null;
}
} else if (!cu.equals(fld.getCompilationUnit())) {
return null;
}
try {
if (fld.getDeclaringType().isInterface()) {
return null;
}
} catch (JavaModelException e) {
JavaPlugin.log(e);
return null;
}
res[i]= fld;
} else {
return null;
}
}
return res;
}
return null;
}
private static class GetterSetterEntry {
|
17,383 |
Bug 17383 create getter/setter - no explicit hint if getter/setter already exist
|
Create getter/setter seems to know which getter/setters exist already. However, there's no explicit way to show this. I can figure out by selecting the type (only not existing getter/setter are shown). If I select a field, I see all the setter/getter of the type and I loose the information which setter and getter exist already.
|
verified fixed
|
b14dfd0
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T15:11:06Z | 2002-05-23T16:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/AddGetterSetterAction.java
|
public final IField field;
public final boolean isGetterEntry;
GetterSetterEntry(IField field, boolean isGetterEntry){
this.field= field;
this.isGetterEntry= isGetterEntry;
}
}
private static class AddGetterSetterLabelProvider extends JavaElementLabelProvider{
private final NameProposer fNameProposer;
private static final Image IMAGE= new JavaElementImageProvider().getImageLabel(new JavaElementImageDescriptor(JavaPluginImages.DESC_MISC_PUBLIC, 0, JavaElementImageProvider.BIG_SIZE));
AddGetterSetterLabelProvider(NameProposer nameProposer){
fNameProposer= nameProposer;
}
/*
* @see ILabelProvider#getText(Object)
*/
public String getText(Object element) {
try {
if (! (element instanceof GetterSetterEntry))
return super.getText(element);
GetterSetterEntry entry= (GetterSetterEntry)element;
if (entry.isGetterEntry)
return fNameProposer.proposeGetterSignature(entry.field);
else
return fNameProposer.proposeSetterSignature(entry.field);
|
17,383 |
Bug 17383 create getter/setter - no explicit hint if getter/setter already exist
|
Create getter/setter seems to know which getter/setters exist already. However, there's no explicit way to show this. I can figure out by selecting the type (only not existing getter/setter are shown). If I select a field, I see all the setter/getter of the type and I loose the information which setter and getter exist already.
|
verified fixed
|
b14dfd0
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T15:11:06Z | 2002-05-23T16:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/AddGetterSetterAction.java
|
} catch (JavaModelException e) {
return "";
}
}
/*
* @see ILabelProvider#getImage(Object)
*/
public Image getImage(Object element) {
if (element instanceof GetterSetterEntry)
return IMAGE;
return super.getImage(element);
}
}
private static class AddGetterSetterContentProvider implements ITreeContentProvider{
private static final Object[] EMPTY= new Object[0];
private Map fGetterSetterEntries;
public AddGetterSetterContentProvider(IType type, boolean filterExistingMethods) throws JavaModelException {
IField[] fields= type.getFields();
fGetterSetterEntries= new HashMap();
String[] prefixes= AddGetterSetterAction.getGetterSetterPrefixes();
String[] suffixes= AddGetterSetterAction.getGetterSetterSuffixes();
for (int i= 0; i < fields.length; i++) {
List l= new ArrayList(2);
if ((! filterExistingMethods) || GetterSetterUtil.getGetter(fields[i], prefixes, suffixes) == null)
l.add(new GetterSetterEntry(fields[i], true));
if ((! filterExistingMethods) || GetterSetterUtil.getSetter(fields[i], prefixes, suffixes) == null)
l.add(new GetterSetterEntry(fields[i], false));
if (! l.isEmpty())
|
17,383 |
Bug 17383 create getter/setter - no explicit hint if getter/setter already exist
|
Create getter/setter seems to know which getter/setters exist already. However, there's no explicit way to show this. I can figure out by selecting the type (only not existing getter/setter are shown). If I select a field, I see all the setter/getter of the type and I loose the information which setter and getter exist already.
|
verified fixed
|
b14dfd0
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T15:11:06Z | 2002-05-23T16:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/AddGetterSetterAction.java
|
fGetterSetterEntries.put(fields[i], (GetterSetterEntry[]) l.toArray(new GetterSetterEntry[l.size()]));
}
}
/*
* @see ITreeContentProvider#getChildren(Object)
*/
public Object[] getChildren(Object parentElement) {
if (parentElement instanceof IField)
return (Object[])fGetterSetterEntries.get(parentElement);
return EMPTY;
}
/*
* @see ITreeContentProvider#getParent(Object)
*/
public Object getParent(Object element) {
if (element instanceof IMember)
return ((IMember)element).getDeclaringType();
if (element instanceof GetterSetterEntry)
return ((GetterSetterEntry)element).field;
return null;
}
/*
* @see ITreeContentProvider#hasChildren(Object)
*/
public boolean hasChildren(Object element) {
return getChildren(element).length > 0;
}
/*
* @see IStructuredContentProvider#getElements(Object)
|
17,383 |
Bug 17383 create getter/setter - no explicit hint if getter/setter already exist
|
Create getter/setter seems to know which getter/setters exist already. However, there's no explicit way to show this. I can figure out by selecting the type (only not existing getter/setter are shown). If I select a field, I see all the setter/getter of the type and I loose the information which setter and getter exist already.
|
verified fixed
|
b14dfd0
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T15:11:06Z | 2002-05-23T16:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/AddGetterSetterAction.java
|
*/
public Object[] getElements(Object inputElement) {
try {
IType type= (IType)inputElement;
IField[] fields= type.getFields();
List fieldList= new ArrayList(fields.length);
for (int i = 0; i < fields.length; i++) {
if (fGetterSetterEntries.containsKey(fields[i]))
fieldList.add(fields[i]);
}
return (IField[]) fieldList.toArray(new IField[fieldList.size()]);
} catch (JavaModelException e) {
return EMPTY;
}
}
/*
* @see IContentProvider#dispose()
*/
public void dispose() {
fGetterSetterEntries.clear();
fGetterSetterEntries= null;
}
/*
* @see IContentProvider#inputChanged(Viewer, Object, Object)
*/
public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
}
}
}
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
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 java.util.Iterator;
import org.eclipse.core.resources.IContainer;
import org.eclipse.core.resources.IFile;
import org.eclipse.core.resources.IResource;
import org.eclipse.core.runtime.IAdaptable;
import org.eclipse.core.runtime.IPath;
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;
import org.eclipse.jdt.core.JavaModelException;
import org.eclipse.jdt.internal.ui.JavaPlugin;
import org.eclipse.jdt.internal.ui.actions.CompositeActionGroup;
import org.eclipse.jdt.internal.ui.dnd.DelegatingDragAdapter;
import org.eclipse.jdt.internal.ui.dnd.DelegatingDropAdapter;
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
import org.eclipse.jdt.internal.ui.dnd.LocalSelectionTransfer;
import org.eclipse.jdt.internal.ui.dnd.ResourceTransferDragAdapter;
import org.eclipse.jdt.internal.ui.dnd.TransferDragSourceListener;
import org.eclipse.jdt.internal.ui.dnd.TransferDropTargetListener;
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.PackagesMessages;
import org.eclipse.jdt.internal.ui.packageview.SelectionTransferDragAdapter;
import org.eclipse.jdt.internal.ui.packageview.SelectionTransferDropAdapter;
import org.eclipse.jdt.internal.ui.preferences.JavaBasePreferencePage;
import org.eclipse.jdt.internal.ui.util.JavaUIHelp;
import org.eclipse.jdt.internal.ui.viewsupport.AppearanceAwareLabelProvider;
import org.eclipse.jdt.internal.ui.viewsupport.JavaElementImageProvider;
import org.eclipse.jdt.internal.ui.viewsupport.JavaElementLabels;
import org.eclipse.jdt.internal.ui.viewsupport.ProblemTableViewer;
import org.eclipse.jdt.internal.ui.viewsupport.StatusBarUpdater;
import org.eclipse.jdt.internal.ui.workingsets.WorkingSetFilterActionGroup;
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.ui.JavaUI;
import org.eclipse.jdt.ui.StandardJavaElementContentProvider;
import org.eclipse.jdt.ui.actions.BuildActionGroup;
import org.eclipse.jdt.ui.actions.CCPActionGroup;
import org.eclipse.jdt.ui.actions.CustomFiltersActionGroup;
import org.eclipse.jdt.ui.actions.GenerateActionGroup;
import org.eclipse.jdt.ui.actions.ImportActionGroup;
import org.eclipse.jdt.ui.actions.JavaSearchActionGroup;
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
import org.eclipse.jdt.ui.actions.OpenEditorActionGroup;
import org.eclipse.jdt.ui.actions.OpenViewActionGroup;
import org.eclipse.jdt.ui.actions.RefactorActionGroup;
import org.eclipse.jdt.ui.actions.ShowActionGroup;
import org.eclipse.jface.action.IAction;
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.text.ITextSelection;
import org.eclipse.jface.util.Assert;
import org.eclipse.jface.util.IPropertyChangeListener;
import org.eclipse.jface.util.PropertyChangeEvent;
import org.eclipse.jface.viewers.DecoratingLabelProvider;
import org.eclipse.jface.viewers.ILabelDecorator;
import org.eclipse.jface.viewers.ILabelProvider;
import org.eclipse.jface.viewers.IOpenListener;
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.OpenEvent;
import org.eclipse.jface.viewers.SelectionChangedEvent;
import org.eclipse.jface.viewers.StructuredSelection;
import org.eclipse.jface.viewers.StructuredViewer;
import org.eclipse.swt.SWT;
import org.eclipse.swt.dnd.DND;
import org.eclipse.swt.dnd.DragSource;
import org.eclipse.swt.dnd.DragSourceEvent;
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
import org.eclipse.swt.dnd.Transfer;
import org.eclipse.swt.events.KeyAdapter;
import org.eclipse.swt.events.KeyEvent;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.Menu;
import org.eclipse.swt.widgets.Shell;
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.IWorkbenchPage;
import org.eclipse.ui.IWorkbenchPart;
import org.eclipse.ui.IWorkbenchPartSite;
import org.eclipse.ui.IWorkingSet;
import org.eclipse.ui.IWorkingSetManager;
import org.eclipse.ui.PartInitException;
import org.eclipse.ui.PlatformUI;
import org.eclipse.ui.actions.ActionContext;
import org.eclipse.ui.actions.ActionGroup;
import org.eclipse.ui.actions.NewWizardMenu;
import org.eclipse.ui.part.ResourceTransfer;
import org.eclipse.ui.part.ViewPart;
import org.eclipse.search.ui.ISearchResultView;
abstract class JavaBrowsingPart extends ViewPart implements IMenuListener, ISelectionListener {
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
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 WorkingSetFilterActionGroup fWorkingSetFilterActionGroup;
private boolean fHasWorkingSetFilter= true;
private OpenEditorActionGroup fOpenEditorGroup;
private CCPActionGroup fCCPActionGroup;
private BuildActionGroup fBuildActionGroup;
protected CompositeActionGroup fActionGroups;
private CustomFiltersActionGroup fCustomFiltersActionGroup;
private Menu fContextMenu;
private IWorkbenchPart fPreviousSelectionProvider;
private Object fPreviousSelectedElement;
/*
* Ensure selection changed events being processed only if
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
* initiated by user interaction with this part.
*/
private boolean fProcessSelectionEvents= true;
private IPartListener fPartListener= new IPartListener() {
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)
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
memento.putMemento(fMemento);
return;
}
if (fHasWorkingSetFilter)
fWorkingSetFilterActionGroup.saveState(memento);
fCustomFiltersActionGroup.saveState(memento);
}
protected void restoreState(IMemento memento) {
if (fHasWorkingSetFilter)
fWorkingSetFilterActionGroup.restoreState(memento);
fCustomFiltersActionGroup.restoreState(memento);
}
/**
* Creates the search list inner viewer.
*/
public void createPartControl(Composite parent) {
Assert.isTrue(fViewer == null);
fTypeComparator= new JavaElementTypeComparator();
fViewer= createViewer(parent);
fLabelProvider= createLabelProvider();
ILabelDecorator decorationMgr= PlatformUI.getWorkbench().getDecoratorManager().getLabelDecorator();
fViewer.setLabelProvider(new DecoratingLabelProvider(fLabelProvider, decorationMgr));
fViewer.setSorter(new JavaElementSorter());
fViewer.setUseHashlookup(true);
fTitleProvider= createTitleProvider();
MenuManager menuMgr= new MenuManager("#PopupMenu");
menuMgr.setRemoveAllWhenShown(true);
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
menuMgr.addMenuListener(this);
fContextMenu= menuMgr.createContextMenu(fViewer.getControl());
fViewer.getControl().setMenu(fContextMenu);
getSite().registerContextMenu(menuMgr, fViewer);
getSite().setSelectionProvider(fViewer);
createActions();
addKeyListener();
fCustomFiltersActionGroup= new CustomFiltersActionGroup(this, fViewer);
if (fMemento != null)
restoreState(fMemento);
fMemento= null;
getSite().setSelectionProvider(fViewer);
IStatusLineManager slManager= getViewSite().getActionBars().getStatusLineManager();
fViewer.addSelectionChangedListener(new StatusBarUpdater(slManager));
hookViewerListeners();
addFilters();
fViewer.setContentProvider(createContentProvider());
setInitialInput();
initDragAndDrop();
setInitialSelection();
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
getViewSite().getWorkbenchWindow().getSelectionService().addSelectionListener(this);
getViewSite().getPage().addPartListener(fPartListener);
fillActionBars();
setHelp();
}
private void initDragAndDrop() {
int ops= DND.DROP_COPY | DND.DROP_MOVE | DND.DROP_LINK;
Transfer[] transfers= new Transfer[] {
LocalSelectionTransfer.getInstance(),
ResourceTransfer.getInstance()};
TransferDropTargetListener[] dropListeners= new TransferDropTargetListener[] {
new SelectionTransferDropAdapter(fViewer)
};
fViewer.addDropSupport(ops | DND.DROP_DEFAULT, transfers, new DelegatingDropAdapter(dropListeners));
Control control= fViewer.getControl();
TransferDragSourceListener[] dragListeners= new TransferDragSourceListener[] {
new SelectionTransferDragAdapter(fViewer),
new ResourceTransferDragAdapter(fViewer)
};
DragSource source= new DragSource(control, ops);
source.addDragListener(new DelegatingDragAdapter(dragListeners) {
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
public void dragStart(DragSourceEvent event) {
IStructuredSelection selection= (IStructuredSelection)getSelectionProvider().getSelection();
for (Iterator iter= selection.iterator(); iter.hasNext(); ) {
if (iter.next() instanceof IMember) {
setPossibleListeners(new TransferDragSourceListener[] {new SelectionTransferDragAdapter(fViewer)});
break;
}
}
super.dragStart(event);
}
});
}
protected void fillActionBars() {
IActionBars actionBars= getViewSite().getActionBars();
IToolBarManager toolBar= actionBars.getToolBarManager();
fillToolBar(toolBar);
if (fHasWorkingSetFilter)
fWorkingSetFilterActionGroup.fillActionBars(getViewSite().getActionBars());
actionBars.updateActionBars();
fActionGroups.fillActionBars(actionBars);
fCustomFiltersActionGroup.fillActionBars(actionBars);
}
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
public void setFocus() {
fViewer.getControl().setFocus();
}
public void dispose() {
if (fViewer != null) {
getViewSite().getWorkbenchWindow().getSelectionService().removeSelectionListener(this);
getViewSite().getPage().removePartListener(fPartListener);
fViewer= null;
}
if (fActionGroups != null)
fActionGroups.dispose();
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;
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
int key= event.keyCode;
IAction action;
if (key == SWT.F5) {
action= fBuildActionGroup.getRefreshAction();
if (action.isEnabled())
action.run();
} if (event.character == SWT.DEL) {
action= fCCPActionGroup.getDeleteAction();
if (action.isEnabled())
action.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();
int size= selection.size();
Object element= selection.getFirstElement();
IJavaElement jElement= element instanceof IJavaElement ? (IJavaElement)element : null;
if (size == 0 || (size == 1 && (isNewTarget(jElement) || element instanceof IContainer))) {
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
MenuManager newMenu= new MenuManager(PackagesMessages.getString("PackageExplorer.new"));
menu.appendToGroup(IContextMenuConstants.GROUP_NEW, newMenu);
new NewWizardMenu(newMenu, getSite().getWorkbenchWindow(), false);
}
if (size == 1)
addOpenNewWindowAction(menu, element);
fActionGroups.setContext(new ActionContext(selection));
fActionGroups.fillContextMenu(menu);
fActionGroups.setContext(null);
}
private boolean isNewTarget(IJavaElement element) {
if (element == null)
return false;
int type= element.getElementType();
return type == IJavaElement.JAVA_PROJECT ||
type == IJavaElement.PACKAGE_FRAGMENT_ROOT ||
type == IJavaElement.PACKAGE_FRAGMENT ||
type == IJavaElement.COMPILATION_UNIT ||
type == IJavaElement.TYPE;
}
private void addOpenNewWindowAction(IMenuManager menu, Object element) {
if (element instanceof IJavaElement) {
try {
element= ((IJavaElement)element).getCorrespondingResource();
} catch(JavaModelException e) {
}
}
if (!(element instanceof IContainer))
return;
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
menu.appendToGroup(
IContextMenuConstants.GROUP_OPEN,
new PatchedOpenInNewWindowAction(getSite().getWorkbenchWindow(), (IContainer)element));
}
protected void createActions() {
fActionGroups= new CompositeActionGroup(new ActionGroup[] {
fOpenEditorGroup= new OpenEditorActionGroup(this),
new OpenViewActionGroup(this),
new ShowActionGroup(this),
fCCPActionGroup= new CCPActionGroup(this),
new RefactorActionGroup(this),
new ImportActionGroup(this),
new GenerateActionGroup(this),
fBuildActionGroup= new BuildActionGroup(this),
new JavaSearchActionGroup(this)});
String viewId= getConfigurationElement().getAttribute("id");
Assert.isNotNull(viewId);
IPropertyChangeListener titleUpdater= new IPropertyChangeListener() {
public void propertyChange(PropertyChangeEvent event) {
String property= event.getProperty();
if (IWorkingSetManager.CHANGE_WORKING_SET_NAME_CHANGE.equals(property))
updateTitle();
}
};
if (fHasWorkingSetFilter)
fWorkingSetFilterActionGroup= new WorkingSetFilterActionGroup(fViewer, viewId, getShell(), titleUpdater);
}
/**
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
* 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.
*/
ISelectionProvider getSelectionProvider() {
return fViewer;
}
/**
* 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
*/
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
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) {
if (newInput == null)
return part == fPreviousSelectionProvider;
if (input instanceof IJavaElement && newInput instanceof IJavaElement)
return getTypeComparator().compare(newInput, input) > 0;
else
return false;
}
private boolean isInputResetBy(IWorkbenchPart part) {
if (!(part instanceof JavaBrowsingPart))
return true;
Object thisInput= getViewer().getInput();
Object partInput= ((JavaBrowsingPart)part).getViewer().getInput();
if (thisInput instanceof IJavaElement && partInput instanceof IJavaElement)
return getTypeComparator().compare(partInput, thisInput) > 0;
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
else
return true;
}
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 || part instanceof ISearchResultView || !(selection instanceof IStructuredSelection))
return;
Object selectedElement= getSingleElementFromSelection(selection);
if (selectedElement != null && part.equals(fPreviousSelectionProvider) && selectedElement.equals(fPreviousSelectedElement))
return;
fPreviousSelectedElement= selectedElement;
Object currentInput= (IJavaElement)getViewer().getInput();
if (selectedElement != null && selectedElement.equals(currentInput)) {
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
IJavaElement elementToSelect= findElementToSelect(getSingleElementFromSelection(selection));
if (elementToSelect != null && getTypeComparator().compare(selectedElement, elementToSelect) < 0)
setSelection(new StructuredSelection(elementToSelect), true);
fPreviousSelectionProvider= part;
return;
}
if (part != fPreviousSelectionProvider && selectedElement != null && !selectedElement.equals(currentInput) && isInputResetBy(selectedElement, currentInput, part)) {
if (!isAncestorOf(selectedElement, currentInput))
setInput(null);
fPreviousSelectionProvider= part;
return;
} else if (selection.isEmpty() && !isInputResetBy(part)) {
fPreviousSelectionProvider= part;
return;
} else if (selectedElement == null && part == fPreviousSelectionProvider) {
setInput(null);
fPreviousSelectionProvider= part;
return;
}
fPreviousSelectionProvider= part;
if (selectedElement instanceof IJavaElement)
adjustInputAndSetSelection((IJavaElement)selectedElement);
else
setSelection(StructuredSelection.EMPTY, true);
}
void setHasWorkingSetFilter(boolean state) {
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
fHasWorkingSetFilter= state;
}
protected void setInput(Object input) {
setViewerInput(input);
updateTitle();
}
private void setViewerInput(Object input) {
fProcessSelectionEvents= false;
fViewer.setInput(input);
fProcessSelectionEvents= true;
}
void updateTitle() {
setTitleToolTip(getToolTipText(fViewer.getInput()));
}
/**
* Returns the tool tip text for the given element.
*/
String getToolTipText(Object element) {
String result;
if (!(element instanceof IResource)) {
result= JavaElementLabels.getTextLabel(element, AppearanceAwareLabelProvider.DEFAULT_TEXTFLAGS);
} else {
IPath path= ((IResource) element).getFullPath();
if (path.isRoot()) {
result= getConfigurationElement().getAttribute("name");
} else {
result= path.makeRelative().toString();
}
}
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
if (fWorkingSetFilterActionGroup == null || fWorkingSetFilterActionGroup.getWorkingSet() == null)
return result;
IWorkingSet ws= fWorkingSetFilterActionGroup.getWorkingSet();
String wsstr= JavaBrowsingMessages.getFormattedString("JavaBrowsingPart.toolTip", new String[] { ws.getName() });
if (result.length() == 0)
return wsstr;
return JavaBrowsingMessages.getFormattedString("JavaBrowsingPart.toolTip2", new String[] { result, ws.getName() });
}
public String getTitleToolTip() {
if (fViewer == null)
return super.getTitleToolTip();
return getToolTipText(fViewer.getInput());
}
protected final StructuredViewer getViewer() {
return fViewer;
}
protected ILabelProvider createLabelProvider() {
return new AppearanceAwareLabelProvider(
AppearanceAwareLabelProvider.DEFAULT_TEXTFLAGS,
AppearanceAwareLabelProvider.DEFAULT_IMAGEFLAGS | JavaElementImageProvider.SMALL_ICONS,
AppearanceAwareLabelProvider.getDecorators(true, null)
);
}
protected ILabelProvider createTitleProvider() {
return new JavaElementLabelProvider(JavaElementLabelProvider.SHOW_BASICS | JavaElementLabelProvider.SHOW_SMALL_ICONS);
}
protected final ILabelProvider getLabelProvider() {
return fLabelProvider;
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
}
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.MULTI);
}
protected int getLabelProviderFlags() {
return JavaElementLabelProvider.SHOW_BASICS | JavaElementLabelProvider.SHOW_OVERLAY_ICONS |
JavaElementLabelProvider.SHOW_SMALL_ICONS | JavaElementLabelProvider.SHOW_VARIABLE | JavaElementLabelProvider.SHOW_PARAMETERS;
}
/**
* Adds filters the viewer of this part.
*/
protected void addFilters() {
}
/**
* Creates the the content provider of this part.
*/
protected StandardJavaElementContentProvider createContentProvider() {
return new JavaBrowsingContentProvider(true, this);
}
protected void setInitialInput() {
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
ISelection selection= getSite().getPage().getSelection();
Object input= getSingleElementFromSelection(selection);
if (!(input instanceof IJavaElement)) {
input= getSite().getPage().getInput();
if (!(input instanceof IJavaElement) && input instanceof IAdaptable)
input= ((IAdaptable)input).getAdapter(IJavaElement.class);
}
setInput(findInputForJavaElement((IJavaElement)input));
}
protected void setInitialSelection() {
Object input;
ISelection selection= getSite().getPage().getSelection();
if (selection != null && !selection.isEmpty())
input= getSingleElementFromSelection(selection);
else {
input= getSite().getPage().getInput();
if (!(input instanceof IJavaElement)) {
if (input instanceof IAdaptable)
input= ((IAdaptable)input).getAdapter(IJavaElement.class);
else
return;
}
}
if (findElementToSelect((IJavaElement)input) != null)
adjustInputAndSetSelection((IJavaElement)input);
}
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
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.
* This method can be overridden but should
* call super.
*/
protected void hookViewerListeners() {
fViewer.addSelectionChangedListener(new ISelectionChangedListener() {
public void selectionChanged(SelectionChangedEvent event) {
if (!fProcessSelectionEvents)
return;
IWorkbenchPage page= getSite().getPage();
if (page == null)
return;
if (page.equals(JavaPlugin.getActivePage()) && JavaBrowsingPart.this.equals(page.getActivePart())) {
linkToEditor((IStructuredSelection)event.getSelection());
}
}
});
fViewer.addOpenListener(new IOpenListener() {
public void open(OpenEvent event) {
IAction open= fOpenEditorGroup.getOpenAction();
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
if (open.isEnabled())
open.run();
}
});
}
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
*
* @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 || !je.exists())
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
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 getSingleElementFromSelection(ISelection selection) {
if (!(selection instanceof StructuredSelection) || selection.isEmpty())
return null;
Iterator iter= ((StructuredSelection)selection).iterator();
Object firstElement= iter.next();
if (!(firstElement instanceof IJavaElement)) {
if (firstElement instanceof IAdaptable)
return (IJavaElement)((IAdaptable)firstElement).getAdapter(IJavaElement.class);
else
return firstElement;
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
}
Object currentInput= (IJavaElement)getViewer().getInput();
if (currentInput == null || !currentInput.equals(findInputForJavaElement((IJavaElement)firstElement)))
if (iter.hasNext())
return null;
else
return firstElement;
while (iter.hasNext()) {
Object element= iter.next();
if (!(element instanceof IJavaElement))
return null;
if (!currentInput.equals(findInputForJavaElement((IJavaElement)element)))
return null;
}
return firstElement;
}
/**
* Gets the typeComparator.
* @return Returns a JavaElementTypeComparator
*/
protected Comparator getTypeComparator() {
return fTypeComparator;
}
/**
* Links to editor (if option enabled)
*/
private void linkToEditor(IStructuredSelection selection) {
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
Object obj= selection.getFirstElement();
Object element= null;
if (selection.size() == 1) {
IEditorPart part= EditorUtility.isOpenInEditor(obj);
if (part != null) {
IWorkbenchPage page= getSite().getPage();
page.bringToTop(part);
if (obj instanceof IJavaElement)
EditorUtility.revealInEditor(part, (IJavaElement) obj);
}
}
}
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 && JavaBasePreferencePage.linkBrowsingViewSelectionToEditor()) {
IEditorInput ei= ((IEditorPart)part).getEditorInput();
if (selection instanceof ITextSelection) {
int offset= ((ITextSelection)selection).getOffset();
IJavaElement element= getElementForInputAt(ei, offset);
if (element != null) {
adjustInputAndSetSelection(element);
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
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();
return null;
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
}
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;
}
/**
* Tries to find the given element in a workingcopy.
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
*/
protected static IJavaElement getWorkingCopy(IJavaElement input) {
try {
if (input instanceof ICompilationUnit)
return ((ICompilationUnit)input).findSharedWorkingCopy(JavaUI.getBufferFactory());
else
return EditorUtility.getWorkingCopy(input, false);
} 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
* @return the compilation unit of the given java element
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
*/
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;
if (element.getElementType() == IJavaElement.CLASS_FILE)
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
return element;
if (((StandardJavaElementContentProvider)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)
try {
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/JavaBrowsingPart.java
|
unit.reconcile();
return unit.getElementAt(offset);
} catch (JavaModelException ex) {
}
return null;
}
protected IType getTypeForCU(ICompilationUnit cu) {
cu= (ICompilationUnit)getSuitableJavaElement(cu);
IType primaryType= cu.findPrimaryType();
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;
}
}
void setProcessSelectionEvents(boolean state) {
fProcessSelectionEvents= state;
}
}
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/MembersView.java
|
/*
* (c) Copyright IBM Corp. 2000, 2001.
* All Rights Reserved.
*/
package org.eclipse.jdt.internal.ui.browsing;
import org.eclipse.swt.SWT;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.jface.action.IToolBarManager;
import org.eclipse.jface.viewers.DoubleClickEvent;
import org.eclipse.jface.viewers.IDoubleClickListener;
import org.eclipse.jface.viewers.ILabelProvider;
import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.jface.viewers.StructuredViewer;
import org.eclipse.jface.viewers.TreeViewer;
import org.eclipse.ui.IMemento;
import org.eclipse.jdt.core.IClassFile;
import org.eclipse.jdt.core.ICompilationUnit;
import org.eclipse.jdt.core.IImportContainer;
import org.eclipse.jdt.core.IImportDeclaration;
import org.eclipse.jdt.core.IJavaElement;
import org.eclipse.jdt.core.IMember;
import org.eclipse.jdt.core.IType;
import org.eclipse.jdt.core.JavaModelException;
import org.eclipse.jdt.ui.JavaUI;
import org.eclipse.jdt.ui.OverrideIndicatorLabelDecorator;
import org.eclipse.jdt.ui.actions.MemberFilterActionGroup;
import org.eclipse.jdt.internal.ui.IJavaHelpContextIds;
import org.eclipse.jdt.internal.ui.viewsupport.AppearanceAwareLabelProvider;
import org.eclipse.jdt.internal.ui.viewsupport.ProblemTreeViewer;
public class MembersView extends JavaBrowsingPart {
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/MembersView.java
|
private MemberFilterActionGroup fMemberFilterActionGroup;
public MembersView() {
setHasWorkingSetFilter(false);
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/MembersView.java
|
}
/**
* Creates and returns the label provider for this part.
*
* @return the label provider
* @see ILabelProvider
*/
protected ILabelProvider createLabelProvider() {
return new AppearanceAwareLabelProvider(
AppearanceAwareLabelProvider.DEFAULT_TEXTFLAGS,
AppearanceAwareLabelProvider.DEFAULT_IMAGEFLAGS,
AppearanceAwareLabelProvider.getDecorators(true, new OverrideIndicatorLabelDecorator(null))
);
}
/**
* Returns the context ID for the Help system
*
* @return the string used as ID for the Help context
*/
protected String getHelpContextId() {
return IJavaHelpContextIds.MEMBERS_VIEW;
}
/**
* Creates the the viewer of this part.
*
* @param parent the parent for the viewer
*/
protected StructuredViewer createViewer(Composite parent) {
ProblemTreeViewer viewer= new ProblemTreeViewer(parent, SWT.MULTI);
fMemberFilterActionGroup= new MemberFilterActionGroup(viewer, JavaUI.ID_MEMBERS_VIEW);
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/MembersView.java
|
return viewer;
}
protected void fillToolBar(IToolBarManager tbm) {
tbm.add(new LexicalSortingAction(getViewer(), JavaUI.ID_MEMBERS_VIEW));
fMemberFilterActionGroup.contributeToToolBar(tbm);
}
/**
* 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
*/
protected boolean isValidInput(Object element) {
if (element instanceof IType) {
IType type= (IType)element;
return type.isBinary() || type.getDeclaringType() == null;
}
return false;
}
/**
* 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) {
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/MembersView.java
|
if (element instanceof IMember)
return super.isValidElement(((IMember)element).getDeclaringType());
else if (element instanceof IImportDeclaration)
return isValidElement(((IJavaElement)element).getParent());
else if (element instanceof IImportContainer) {
Object input= getViewer().getInput();
if (input instanceof IJavaElement) {
ICompilationUnit cu= (ICompilationUnit)((IJavaElement)input).getAncestor(IJavaElement.COMPILATION_UNIT);
if (cu != null) {
ICompilationUnit importContainerCu= (ICompilationUnit)((IJavaElement)element).getAncestor(IJavaElement.COMPILATION_UNIT);
return cu.equals(importContainerCu);
} else {
IClassFile cf= (IClassFile)((IJavaElement)input).getAncestor(IJavaElement.CLASS_FILE);
IClassFile importContainerCf= (IClassFile)((IJavaElement)element).getAncestor(IJavaElement.CLASS_FILE);
return cf != null && cf.equals(importContainerCf);
}
}
}
return false;
}
/**
* Finds the element which has to be selected in this part.
*
* @param je the Java element which has the focus
*/
protected IJavaElement findElementToSelect(IJavaElement je) {
if (je == null)
return null;
switch (je.getElementType()) {
case IJavaElement.TYPE:
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/MembersView.java
|
if (((IType)je).getDeclaringType() == null)
return null;
case IJavaElement.METHOD:
case IJavaElement.FIELD:
case IJavaElement.PACKAGE_DECLARATION:
case IJavaElement.IMPORT_CONTAINER:
case IJavaElement.IMPORT_DECLARATION:
je= getSuitableJavaElement(je);
if (je != null)
return je;
default:
return null;
}
}
/**
* Finds the closest Java element which can be used as input for
* this part and has the given Java element as child
*
* @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 || !je.exists())
return null;
switch (je.getElementType()) {
case IJavaElement.TYPE:
IType type= ((IType)je).getDeclaringType();
if (type == null)
return je;
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/MembersView.java
|
else
return findInputForJavaElement(type);
case IJavaElement.COMPILATION_UNIT:
return getTypeForCU((ICompilationUnit)je);
case IJavaElement.CLASS_FILE:
try {
return findInputForJavaElement(((IClassFile)je).getType());
} catch (JavaModelException ex) {
return null;
}
case IJavaElement.IMPORT_DECLARATION:
return findInputForJavaElement(je.getParent());
case IJavaElement.PACKAGE_DECLARATION:
case IJavaElement.IMPORT_CONTAINER:
IJavaElement parent= je.getParent();
if (parent instanceof ICompilationUnit) {
IType[] types;
try {
types= ((ICompilationUnit)parent).getAllTypes();
} catch (JavaModelException ex) {
return null;
}
if (types.length > 0)
return types[0];
else
return null;
}
else if (parent instanceof IClassFile)
return findInputForJavaElement(parent);
default:
|
16,343 |
Bug 16343 Method list should not have a view drop down/filter menu
|
Opt to remove it. It takes space, is rarely used, and is inconsistent with the outliner.
|
verified fixed
|
6860f94
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:44:41Z | 2002-05-18T11:06:40Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/browsing/MembersView.java
|
if (je instanceof IMember)
return findInputForJavaElement(((IMember)je).getDeclaringType());
}
return null;
}
/*
* Implements method from IViewPart.
*/
public void saveState(IMemento memento) {
super.saveState(memento);
fMemberFilterActionGroup.saveState(memento);
}
protected void restoreState(IMemento memento) {
super.restoreState(memento);
fMemberFilterActionGroup.restoreState(memento);
}
protected void hookViewerListeners() {
super.hookViewerListeners();
getViewer().addDoubleClickListener(new IDoubleClickListener() {
public void doubleClick(DoubleClickEvent event) {
TreeViewer viewer= (TreeViewer)getViewer();
Object element= ((IStructuredSelection)event.getSelection()).getFirstElement();
if (viewer.isExpandable(element))
viewer.setExpandedState(element, !viewer.getExpandedState(element));
}
});
}
}
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
/*
* (c) Copyright IBM Corp. 2000, 2001.
* All Rights Reserved.
*/
package org.eclipse.jdt.internal.ui.typehierarchy;
import java.util.ArrayList;
import java.util.List;
import org.eclipse.core.resources.IFile;
import org.eclipse.core.resources.IResource;
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
import org.eclipse.core.runtime.CoreException;
import org.eclipse.swt.SWT;
import org.eclipse.swt.custom.BusyIndicator;
import org.eclipse.swt.custom.CLabel;
import org.eclipse.swt.custom.SashForm;
import org.eclipse.swt.custom.ViewForm;
import org.eclipse.swt.dnd.DND;
import org.eclipse.swt.dnd.DragSource;
import org.eclipse.swt.dnd.DropTarget;
import org.eclipse.swt.dnd.Transfer;
import org.eclipse.swt.events.KeyAdapter;
import org.eclipse.swt.events.KeyEvent;
import org.eclipse.swt.events.KeyListener;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
import org.eclipse.swt.widgets.Display;
import org.eclipse.swt.widgets.Label;
import org.eclipse.swt.widgets.ScrollBar;
import org.eclipse.swt.widgets.ToolBar;
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.action.ToolBarManager;
import org.eclipse.jface.dialogs.IDialogSettings;
import org.eclipse.jface.dialogs.MessageDialog;
import org.eclipse.jface.util.Assert;
import org.eclipse.jface.viewers.AbstractTreeViewer;
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
import org.eclipse.jface.viewers.IBasicPropertyConstants;
import org.eclipse.jface.viewers.ISelection;
import org.eclipse.jface.viewers.ISelectionChangedListener;
import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.jface.viewers.SelectionChangedEvent;
import org.eclipse.jface.viewers.StructuredSelection;
import org.eclipse.jface.viewers.StructuredViewer;
import org.eclipse.jface.viewers.Viewer;
import org.eclipse.ui.IActionBars;
import org.eclipse.ui.IEditorPart;
import org.eclipse.ui.IMemento;
import org.eclipse.ui.IPartListener;
import org.eclipse.ui.IViewSite;
import org.eclipse.ui.IWorkbenchActionConstants;
import org.eclipse.ui.IWorkbenchPart;
import org.eclipse.ui.PartInitException;
import org.eclipse.ui.actions.ActionContext;
import org.eclipse.ui.actions.ActionGroup;
import org.eclipse.ui.actions.OpenWithMenu;
import org.eclipse.ui.help.WorkbenchHelp;
import org.eclipse.ui.part.PageBook;
import org.eclipse.ui.part.ViewPart;
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.ITypeHierarchy;
import org.eclipse.jdt.core.JavaCore;
import org.eclipse.jdt.core.JavaModelException;
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
import org.eclipse.jdt.ui.IContextMenuConstants;
import org.eclipse.jdt.ui.ITypeHierarchyViewPart;
import org.eclipse.jdt.ui.actions.CCPActionGroup;
import org.eclipse.jdt.ui.actions.GenerateActionGroup;
import org.eclipse.jdt.ui.actions.JavaSearchActionGroup;
import org.eclipse.jdt.ui.actions.OpenEditorActionGroup;
import org.eclipse.jdt.ui.actions.OpenViewActionGroup;
import org.eclipse.jdt.ui.actions.RefactorActionGroup;
import org.eclipse.jdt.ui.actions.ShowActionGroup;
import org.eclipse.jdt.internal.ui.IJavaHelpContextIds;
import org.eclipse.jdt.internal.ui.JavaPlugin;
import org.eclipse.jdt.internal.ui.actions.AddMethodStubAction;
import org.eclipse.jdt.internal.ui.actions.CompositeActionGroup;
import org.eclipse.jdt.internal.ui.dnd.DelegatingDragAdapter;
import org.eclipse.jdt.internal.ui.dnd.DelegatingDropAdapter;
import org.eclipse.jdt.internal.ui.dnd.LocalSelectionTransfer;
import org.eclipse.jdt.internal.ui.dnd.TransferDragSourceListener;
import org.eclipse.jdt.internal.ui.dnd.TransferDropTargetListener;
import org.eclipse.jdt.internal.ui.javaeditor.EditorUtility;
import org.eclipse.jdt.internal.ui.packageview.SelectionTransferDragAdapter;
import org.eclipse.jdt.internal.ui.preferences.JavaBasePreferencePage;
import org.eclipse.jdt.internal.ui.util.OpenTypeHierarchyUtil;
import org.eclipse.jdt.internal.ui.viewsupport.IProblemChangedListener;
import org.eclipse.jdt.internal.ui.viewsupport.JavaElementLabels;
import org.eclipse.jdt.internal.ui.viewsupport.JavaUILabelProvider;
import org.eclipse.jdt.internal.ui.viewsupport.StatusBarUpdater;
/**
* view showing the supertypes/subtypes of its input.
*/
public class TypeHierarchyViewPart extends ViewPart implements ITypeHierarchyViewPart {
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
public static final int VIEW_ID_TYPE= 2;
public static final int VIEW_ID_SUPER= 0;
public static final int VIEW_ID_SUB= 1;
public static final int VIEW_ORIENTATION_VERTICAL= 0;
public static final int VIEW_ORIENTATION_HORIZONTAL= 1;
public static final int VIEW_ORIENTATION_SINGLE= 2;
private static final String DIALOGSTORE_HIERARCHYVIEW= "TypeHierarchyViewPart.hierarchyview";
private static final String DIALOGSTORE_VIEWORIENTATION= "TypeHierarchyViewPart.orientation";
private static final String TAG_INPUT= "input";
private static final String TAG_VIEW= "view";
private static final String TAG_ORIENTATION= "orientation";
private static final String TAG_RATIO= "ratio";
private static final String TAG_SELECTION= "selection";
private static final String TAG_VERTICAL_SCROLL= "vertical_scroll";
private static final String GROUP_FOCUS= "group.focus";
private IType fSelectedType;
private IJavaElement fInputElement;
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
private ArrayList fInputHistory;
private IMemento fMemento;
private TypeHierarchyLifeCycle fHierarchyLifeCycle;
private ITypeHierarchyLifeCycleListener fTypeHierarchyLifeCycleListener;
private MethodsViewer fMethodsViewer;
private int fCurrentViewerIndex;
private TypeHierarchyViewer[] fAllViewers;
private SelectionProviderMediator fSelectionProviderMediator;
private ISelectionChangedListener fSelectionChangedListener;
private boolean fIsEnableMemberFilter;
private SashForm fTypeMethodsSplitter;
private PageBook fViewerbook;
private PageBook fPagebook;
private Label fNoHierarchyShownLabel;
private Label fEmptyTypesViewer;
private ViewForm fTypeViewerViewForm;
private ViewForm fMethodViewerViewForm;
private CLabel fMethodViewerPaneLabel;
private JavaUILabelProvider fPaneLabelProvider;
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
private IDialogSettings fDialogSettings;
private ToggleViewAction[] fViewActions;
private HistoryDropDownAction fHistoryDropDownAction;
private ToggleOrientationAction[] fToggleOrientationActions;
private int fCurrentOrientation;
private EnableMemberFilterAction fEnableMemberFilterAction;
private AddMethodStubAction fAddStubAction;
private FocusOnTypeAction fFocusOnTypeAction;
private FocusOnSelectionAction fFocusOnSelectionAction;
private IPartListener fPartListener;
private CompositeActionGroup fActionGroups;
private CCPActionGroup fCCPActionGroup;
public TypeHierarchyViewPart() {
fSelectedType= null;
fInputElement= null;
fHierarchyLifeCycle= new TypeHierarchyLifeCycle();
fHierarchyLifeCycle.setReconciled(JavaBasePreferencePage.reconcileJavaViews());
fTypeHierarchyLifeCycleListener= new ITypeHierarchyLifeCycleListener() {
public void typeHierarchyChanged(TypeHierarchyLifeCycle typeHierarchy, IType[] changedTypes) {
doTypeHierarchyChanged(typeHierarchy, changedTypes);
}
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
};
fHierarchyLifeCycle.addChangedListener(fTypeHierarchyLifeCycleListener);
fIsEnableMemberFilter= false;
fInputHistory= new ArrayList();
fAllViewers= null;
fViewActions= new ToggleViewAction[] {
new ToggleViewAction(this, VIEW_ID_TYPE),
new ToggleViewAction(this, VIEW_ID_SUPER),
new ToggleViewAction(this, VIEW_ID_SUB)
};
fDialogSettings= JavaPlugin.getDefault().getDialogSettings();
fHistoryDropDownAction= new HistoryDropDownAction(this);
fHistoryDropDownAction.setEnabled(false);
fToggleOrientationActions= new ToggleOrientationAction[] {
new ToggleOrientationAction(this, VIEW_ORIENTATION_VERTICAL),
new ToggleOrientationAction(this, VIEW_ORIENTATION_HORIZONTAL),
new ToggleOrientationAction(this, VIEW_ORIENTATION_SINGLE)
};
fEnableMemberFilterAction= new EnableMemberFilterAction(this, false);
fFocusOnTypeAction= new FocusOnTypeAction(this);
fPaneLabelProvider= new JavaUILabelProvider();
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
fAddStubAction= new AddMethodStubAction();
fFocusOnSelectionAction= new FocusOnSelectionAction(this);
fPartListener= new IPartListener() {
public void partActivated(IWorkbenchPart part) {
if (part instanceof IEditorPart)
editorActivated((IEditorPart) part);
}
public void partBroughtToTop(IWorkbenchPart part) {}
public void partClosed(IWorkbenchPart part) {}
public void partDeactivated(IWorkbenchPart part) {}
public void partOpened(IWorkbenchPart part) {}
};
fSelectionChangedListener= new ISelectionChangedListener() {
public void selectionChanged(SelectionChangedEvent event) {
doSelectionChanged(event);
}
};
}
/**
* Adds the entry if new. Inserted at the beginning of the history entries list.
*/
private void addHistoryEntry(IJavaElement entry) {
if (fInputHistory.contains(entry)) {
fInputHistory.remove(entry);
}
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
fInputHistory.add(0, entry);
fHistoryDropDownAction.setEnabled(true);
}
private void updateHistoryEntries() {
for (int i= fInputHistory.size() - 1; i >= 0; i--) {
IJavaElement type= (IJavaElement) fInputHistory.get(i);
if (!type.exists()) {
fInputHistory.remove(i);
}
}
fHistoryDropDownAction.setEnabled(!fInputHistory.isEmpty());
}
/**
* Goes to the selected entry, without updating the order of history entries.
*/
public void gotoHistoryEntry(IJavaElement entry) {
if (fInputHistory.contains(entry)) {
updateInput(entry);
}
}
/**
* Gets all history entries.
*/
public IJavaElement[] getHistoryEntries() {
if (fInputHistory.size() > 0) {
updateHistoryEntries();
}
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
return (IJavaElement[]) fInputHistory.toArray(new IJavaElement[fInputHistory.size()]);
}
/**
* Sets the history entries
*/
public void setHistoryEntries(IJavaElement[] elems) {
fInputHistory.clear();
for (int i= 0; i < elems.length; i++) {
fInputHistory.add(elems[i]);
}
updateHistoryEntries();
}
/**
* Selects an member in the methods list or in the current hierarchy.
*/
public void selectMember(IMember member) {
ICompilationUnit cu= member.getCompilationUnit();
if (cu != null && cu.isWorkingCopy()) {
member= (IMember) cu.getOriginal(member);
if (member == null) {
return;
}
}
if (member.getElementType() != IJavaElement.TYPE) {
if (fHierarchyLifeCycle.isReconciled() && cu != null) {
try {
member= (IMember) EditorUtility.getWorkingCopy(member);
if (member == null) {
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
return;
}
} catch (JavaModelException e) {
JavaPlugin.log(e);
return;
}
}
Control methodControl= fMethodsViewer.getControl();
if (methodControl != null && !methodControl.isDisposed()) {
methodControl.setFocus();
}
fMethodsViewer.setSelection(new StructuredSelection(member), true);
} else {
Control viewerControl= getCurrentViewer().getControl();
if (viewerControl != null && !viewerControl.isDisposed()) {
viewerControl.setFocus();
}
getCurrentViewer().setSelection(new StructuredSelection(member), true);
}
}
/**
* @deprecated
*/
public IType getInput() {
if (fInputElement instanceof IType) {
return (IType) fInputElement;
}
return null;
}
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
/**
* Sets the input to a new type
* @deprecated
*/
public void setInput(IType type) {
setInputElement(type);
}
/**
* Returns the input element of the type hierarchy.
* Can be of type <code>IType</code> or <code>IPackageFragment</code>
*/
public IJavaElement getInputElement() {
return fInputElement;
}
/**
* Sets the input to a new element.
*/
public void setInputElement(IJavaElement element) {
if (element != null) {
if (element instanceof IMember) {
if (element.getElementType() != IJavaElement.TYPE) {
element= ((IMember) element).getDeclaringType();
}
ICompilationUnit cu= ((IMember) element).getCompilationUnit();
if (cu != null && cu.isWorkingCopy()) {
element= cu.getOriginal(element);
if (!element.exists()) {
MessageDialog.openError(getSite().getShell(), TypeHierarchyMessages.getString("TypeHierarchyViewPart.error.title"), TypeHierarchyMessages.getString("TypeHierarchyViewPart.error.message"));
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
return;
}
}
}
}
if (element != null && !element.equals(fInputElement)) {
addHistoryEntry(element);
}
updateInput(element);
}
/**
* Changes the input to a new type
*/
private void updateInput(IJavaElement inputElement) {
IJavaElement prevInput= fInputElement;
fInputElement= inputElement;
if (fInputElement == null) {
clearInput();
} else {
try {
fHierarchyLifeCycle.ensureRefreshedTypeHierarchy(fInputElement);
} catch (JavaModelException e) {
JavaPlugin.log(e);
clearInput();
return;
}
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
fPagebook.showPage(fTypeMethodsSplitter);
if (inputElement.getElementType() != IJavaElement.TYPE) {
setView(VIEW_ID_TYPE);
}
setMemberFilter(null);
fIsEnableMemberFilter= false;
if (!fInputElement.equals(prevInput)) {
updateHierarchyViewer();
}
IType root= getSelectableType(fInputElement);
internalSelectType(root, true);
updateMethodViewer(root);
updateToolbarButtons();
updateTitle();
enableMemberFilter(false);
}
}
private void clearInput() {
fInputElement= null;
fHierarchyLifeCycle.freeHierarchy();
updateHierarchyViewer();
updateToolbarButtons();
}
/*
* @see IWorbenchPart#setFocus
*/
public void setFocus() {
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
fPagebook.setFocus();
}
/*
* @see IWorkbenchPart#dispose
*/
public void dispose() {
fHierarchyLifeCycle.freeHierarchy();
fHierarchyLifeCycle.removeChangedListener(fTypeHierarchyLifeCycleListener);
fPaneLabelProvider.dispose();
getSite().getPage().removePartListener(fPartListener);
if (fActionGroups != null)
fActionGroups.dispose();
super.dispose();
}
private Control createTypeViewerControl(Composite parent) {
fViewerbook= new PageBook(parent, SWT.NULL);
KeyListener keyListener= createKeyListener();
TypeHierarchyViewer superTypesViewer= new SuperTypeHierarchyViewer(fViewerbook, fHierarchyLifeCycle, this);
initializeTypesViewer(superTypesViewer, keyListener, IContextMenuConstants.TARGET_ID_SUPERTYPES_VIEW);
TypeHierarchyViewer subTypesViewer= new SubTypeHierarchyViewer(fViewerbook, fHierarchyLifeCycle, this);
initializeTypesViewer(subTypesViewer, keyListener, IContextMenuConstants.TARGET_ID_SUBTYPES_VIEW);
TypeHierarchyViewer vajViewer= new TraditionalHierarchyViewer(fViewerbook, fHierarchyLifeCycle, this);
initializeTypesViewer(vajViewer, keyListener, IContextMenuConstants.TARGET_ID_HIERARCHY_VIEW);
fAllViewers= new TypeHierarchyViewer[3];
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
fAllViewers[VIEW_ID_SUPER]= superTypesViewer;
fAllViewers[VIEW_ID_SUB]= subTypesViewer;
fAllViewers[VIEW_ID_TYPE]= vajViewer;
int currViewerIndex;
try {
currViewerIndex= fDialogSettings.getInt(DIALOGSTORE_HIERARCHYVIEW);
if (currViewerIndex < 0 || currViewerIndex > 2) {
currViewerIndex= VIEW_ID_TYPE;
}
} catch (NumberFormatException e) {
currViewerIndex= VIEW_ID_TYPE;
}
fEmptyTypesViewer= new Label(fViewerbook, SWT.LEFT);
for (int i= 0; i < fAllViewers.length; i++) {
fAllViewers[i].setInput(fAllViewers[i]);
}
fCurrentViewerIndex= -1;
setView(currViewerIndex);
return fViewerbook;
}
private KeyListener createKeyListener() {
return new KeyAdapter() {
public void keyReleased(KeyEvent event) {
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
if (event.stateMask == 0) {
if (event.keyCode == SWT.F5) {
updateHierarchyViewer();
return;
} else if (event.character == SWT.DEL){
if (fCCPActionGroup.getDeleteAction().isEnabled())
fCCPActionGroup.getDeleteAction().run();
return;
}
}
viewPartKeyShortcuts(event);
}
};
}
private void initializeTypesViewer(final TypeHierarchyViewer typesViewer, KeyListener keyListener, String cotextHelpId) {
typesViewer.getControl().setVisible(false);
typesViewer.getControl().addKeyListener(keyListener);
typesViewer.initContextMenu(new IMenuListener() {
public void menuAboutToShow(IMenuManager menu) {
fillTypesViewerContextMenu(typesViewer, menu);
}
}, cotextHelpId, getSite());
typesViewer.addSelectionChangedListener(fSelectionChangedListener);
}
private Control createMethodViewerControl(Composite parent) {
fMethodsViewer= new MethodsViewer(parent, fHierarchyLifeCycle, this);
fMethodsViewer.initContextMenu(new IMenuListener() {
public void menuAboutToShow(IMenuManager menu) {
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
fillMethodsViewerContextMenu(menu);
}
}, IContextMenuConstants.TARGET_ID_MEMBERS_VIEW, getSite());
fMethodsViewer.addSelectionChangedListener(fSelectionChangedListener);
Control control= fMethodsViewer.getTable();
control.addKeyListener(createKeyListener());
return control;
}
private void initDragAndDrop() {
Transfer[] transfers= new Transfer[] { LocalSelectionTransfer.getInstance() };
int ops= DND.DROP_MOVE | DND.DROP_COPY | DND.DROP_LINK;
for (int i= 0; i < fAllViewers.length; i++) {
addDragAdapters(fAllViewers[i], ops, transfers);
addDropAdapters(fAllViewers[i], ops | DND.DROP_DEFAULT, transfers);
}
addDragAdapters(fMethodsViewer, ops, transfers);
DropTarget dropTarget = new DropTarget(fNoHierarchyShownLabel, ops | DND.DROP_DEFAULT);
dropTarget.setTransfer(transfers);
dropTarget.addDropListener(new TypeHierarchyTransferDropAdapter(this, fAllViewers[0]));
}
private void addDropAdapters(AbstractTreeViewer viewer, int ops, Transfer[] transfers){
TransferDropTargetListener[] dropListeners= new TransferDropTargetListener[] {
new TypeHierarchyTransferDropAdapter(this, viewer)
};
viewer.addDropSupport(ops, transfers, new DelegatingDropAdapter(dropListeners));
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
}
private void addDragAdapters(StructuredViewer viewer, int ops, Transfer[] transfers){
Control control= viewer.getControl();
TransferDragSourceListener[] dragListeners= new TransferDragSourceListener[] {
new SelectionTransferDragAdapter(viewer)
};
DragSource source= new DragSource(control, ops);
source.addDragListener(new DelegatingDragAdapter(dragListeners));
}
private void viewPartKeyShortcuts(KeyEvent event) {
if (event.stateMask == SWT.CTRL) {
if (event.character == '1') {
setView(VIEW_ID_TYPE);
} else if (event.character == '2') {
setView(VIEW_ID_SUPER);
} else if (event.character == '3') {
setView(VIEW_ID_SUB);
}
}
}
/**
* Returns the inner component in a workbench part.
* @see IWorkbenchPart#createPartControl
*/
public void createPartControl(Composite container) {
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
fPagebook= new PageBook(container, SWT.NONE);
fTypeMethodsSplitter= new SashForm(fPagebook, SWT.VERTICAL);
fTypeMethodsSplitter.setVisible(false);
fTypeViewerViewForm= new ViewForm(fTypeMethodsSplitter, SWT.NONE);
Control typeViewerControl= createTypeViewerControl(fTypeViewerViewForm);
fTypeViewerViewForm.setContent(typeViewerControl);
fMethodViewerViewForm= new ViewForm(fTypeMethodsSplitter, SWT.NONE);
fTypeMethodsSplitter.setWeights(new int[] {35, 65});
Control methodViewerPart= createMethodViewerControl(fMethodViewerViewForm);
fMethodViewerViewForm.setContent(methodViewerPart);
fMethodViewerPaneLabel= new CLabel(fMethodViewerViewForm, SWT.NONE);
fMethodViewerViewForm.setTopLeft(fMethodViewerPaneLabel);
ToolBar methodViewerToolBar= new ToolBar(fMethodViewerViewForm, SWT.FLAT | SWT.WRAP);
fMethodViewerViewForm.setTopCenter(methodViewerToolBar);
fNoHierarchyShownLabel= new Label(fPagebook, SWT.TOP + SWT.LEFT + SWT.WRAP);
fNoHierarchyShownLabel.setText(TypeHierarchyMessages.getString("TypeHierarchyViewPart.empty"));
MenuManager menu= new MenuManager();
menu.add(fFocusOnTypeAction);
fNoHierarchyShownLabel.setMenu(menu.createContextMenu(fNoHierarchyShownLabel));
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
fPagebook.showPage(fNoHierarchyShownLabel);
int orientation;
try {
orientation= fDialogSettings.getInt(DIALOGSTORE_VIEWORIENTATION);
if (orientation < 0 || orientation > 2) {
orientation= VIEW_ORIENTATION_VERTICAL;
}
} catch (NumberFormatException e) {
orientation= VIEW_ORIENTATION_VERTICAL;
}
fCurrentOrientation= -1;
setOrientation(orientation);
IActionBars actionBars= getViewSite().getActionBars();
IMenuManager viewMenu= actionBars.getMenuManager();
for (int i= 0; i < fToggleOrientationActions.length; i++) {
viewMenu.add(fToggleOrientationActions[i]);
}
viewMenu.add(new Separator(IWorkbenchActionConstants.MB_ADDITIONS));
ToolBarManager lowertbmanager= new ToolBarManager(methodViewerToolBar);
lowertbmanager.add(fEnableMemberFilterAction);
lowertbmanager.add(new Separator());
fMethodsViewer.contributeToToolBar(lowertbmanager);
lowertbmanager.update(true);
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
int nHierarchyViewers= fAllViewers.length;
Viewer[] trackedViewers= new Viewer[nHierarchyViewers + 1];
for (int i= 0; i < nHierarchyViewers; i++) {
trackedViewers[i]= fAllViewers[i];
}
trackedViewers[nHierarchyViewers]= fMethodsViewer;
fSelectionProviderMediator= new SelectionProviderMediator(trackedViewers);
IStatusLineManager slManager= getViewSite().getActionBars().getStatusLineManager();
fSelectionProviderMediator.addSelectionChangedListener(new StatusBarUpdater(slManager));
getSite().setSelectionProvider(fSelectionProviderMediator);
getSite().getPage().addPartListener(fPartListener);
IJavaElement input= determineInputElement();
if (fMemento != null) {
restoreState(fMemento, input);
} else if (input != null) {
setInputElement(input);
} else {
setViewerVisibility(false);
}
WorkbenchHelp.setHelp(fPagebook, IJavaHelpContextIds.TYPE_HIERARCHY_VIEW);
fActionGroups= new CompositeActionGroup(new ActionGroup[] {
new OpenEditorActionGroup(this),
new OpenViewActionGroup(this),
new ShowActionGroup(this),
fCCPActionGroup= new CCPActionGroup(this),
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
new RefactorActionGroup(this),
new GenerateActionGroup(this),
new JavaSearchActionGroup(this)});
fActionGroups.fillActionBars(getViewSite().getActionBars());
initDragAndDrop();
}
/**
* called from ToggleOrientationAction.
* @param orientation VIEW_ORIENTATION_SINGLE, VIEW_ORIENTATION_HORIZONTAL or VIEW_ORIENTATION_VERTICAL
*/
public void setOrientation(int orientation) {
if (fCurrentOrientation != orientation) {
boolean methodViewerNeedsUpdate= false;
if (fMethodViewerViewForm != null && !fMethodViewerViewForm.isDisposed()
&& fTypeMethodsSplitter != null && !fTypeMethodsSplitter.isDisposed()) {
if (orientation == VIEW_ORIENTATION_SINGLE) {
fMethodViewerViewForm.setVisible(false);
enableMemberFilter(false);
updateMethodViewer(null);
} else {
if (fCurrentOrientation == VIEW_ORIENTATION_SINGLE) {
fMethodViewerViewForm.setVisible(true);
methodViewerNeedsUpdate= true;
}
boolean horizontal= orientation == VIEW_ORIENTATION_HORIZONTAL;
fTypeMethodsSplitter.setOrientation(horizontal ? SWT.HORIZONTAL : SWT.VERTICAL);
}
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
updateMainToolbar(orientation);
fTypeMethodsSplitter.layout();
}
for (int i= 0; i < fToggleOrientationActions.length; i++) {
fToggleOrientationActions[i].setChecked(orientation == fToggleOrientationActions[i].getOrientation());
}
fCurrentOrientation= orientation;
if (methodViewerNeedsUpdate) {
updateMethodViewer(fSelectedType);
}
fDialogSettings.put(DIALOGSTORE_VIEWORIENTATION, orientation);
}
}
private void updateMainToolbar(int orientation) {
IActionBars actionBars= getViewSite().getActionBars();
IToolBarManager tbmanager= actionBars.getToolBarManager();
if (orientation == VIEW_ORIENTATION_HORIZONTAL) {
clearMainToolBar(tbmanager);
ToolBar typeViewerToolBar= new ToolBar(fTypeViewerViewForm, SWT.FLAT | SWT.WRAP);
fillMainToolBar(new ToolBarManager(typeViewerToolBar));
fTypeViewerViewForm.setTopLeft(typeViewerToolBar);
} else {
fTypeViewerViewForm.setTopLeft(null);
fillMainToolBar(tbmanager);
}
}
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
private void fillMainToolBar(IToolBarManager tbmanager) {
tbmanager.removeAll();
tbmanager.add(fHistoryDropDownAction);
for (int i= 0; i < fViewActions.length; i++) {
tbmanager.add(fViewActions[i]);
}
tbmanager.update(false);
}
private void clearMainToolBar(IToolBarManager tbmanager) {
tbmanager.removeAll();
tbmanager.update(false);
}
/**
* Creates the context menu for the hierarchy viewers
*/
private void fillTypesViewerContextMenu(TypeHierarchyViewer viewer, IMenuManager menu) {
JavaPlugin.createStandardGroups(menu);
menu.appendToGroup(IContextMenuConstants.GROUP_SHOW, new Separator(GROUP_FOCUS));
viewer.contributeToContextMenu(menu);
menu.appendToGroup(GROUP_FOCUS, fFocusOnTypeAction);
if (fFocusOnSelectionAction.canActionBeAdded())
menu.appendToGroup(GROUP_FOCUS, fFocusOnSelectionAction);
fActionGroups.setContext(new ActionContext(getSite().getSelectionProvider().getSelection()));
fActionGroups.fillContextMenu(menu);
fActionGroups.setContext(null);
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
}
/**
* Creates the context menu for the method viewer
*/
private void fillMethodsViewerContextMenu(IMenuManager menu) {
JavaPlugin.createStandardGroups(menu);
fMethodsViewer.contributeToContextMenu(menu);
if (fSelectedType != null && fAddStubAction.init(fSelectedType, fMethodsViewer.getSelection())) {
menu.appendToGroup(IContextMenuConstants.GROUP_REORGANIZE, fAddStubAction);
}
fActionGroups.setContext(new ActionContext(getSite().getSelectionProvider().getSelection()));
fActionGroups.fillContextMenu(menu);
fActionGroups.setContext(null);
}
private void addOpenWithMenu(IMenuManager menu, IStructuredSelection selection) {
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
if (selection.size() != 1)
return;
Object element= selection.getFirstElement();
if (!(element instanceof IJavaElement))
return;
IResource resource= null;
try {
resource= ((IJavaElement)element).getUnderlyingResource();
} catch(JavaModelException e) {
}
if (!(resource instanceof IFile))
return;
MenuManager submenu= new MenuManager(TypeHierarchyMessages.getString("TypeHierarchyViewPart.menu.open"));
submenu.add(new OpenWithMenu(getSite().getPage(), (IFile) resource));
menu.appendToGroup(IContextMenuConstants.GROUP_OPEN, submenu);
}
/**
* Toggles between the empty viewer page and the hierarchy
*/
private void setViewerVisibility(boolean showHierarchy) {
if (showHierarchy) {
fViewerbook.showPage(getCurrentViewer().getControl());
} else {
fViewerbook.showPage(fEmptyTypesViewer);
}
}
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
/**
* Sets the member filter. <code>null</code> disables member filtering.
*/
private void setMemberFilter(IMember[] memberFilter) {
Assert.isNotNull(fAllViewers);
for (int i= 0; i < fAllViewers.length; i++) {
fAllViewers[i].setMemberFilter(memberFilter);
}
}
private IType getSelectableType(IJavaElement elem) {
ISelection sel= null;
if (elem.getElementType() != IJavaElement.TYPE) {
return (IType) getCurrentViewer().getTreeRootType();
} else {
return (IType) elem;
}
}
private void internalSelectType(IMember elem, boolean reveal) {
TypeHierarchyViewer viewer= getCurrentViewer();
viewer.removeSelectionChangedListener(fSelectionChangedListener);
viewer.setSelection(elem != null ? new StructuredSelection(elem) : StructuredSelection.EMPTY, reveal);
viewer.addSelectionChangedListener(fSelectionChangedListener);
}
private void internalSelectMember(IMember member) {
fMethodsViewer.removeSelectionChangedListener(fSelectionChangedListener);
fMethodsViewer.setSelection(member != null ? new StructuredSelection(member) : StructuredSelection.EMPTY);
fMethodsViewer.addSelectionChangedListener(fSelectionChangedListener);
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
}
/**
* When the input changed or the hierarchy pane becomes visible,
* <code>updateHierarchyViewer<code> brings up the correct view and refreshes
* the current tree
*/
private void updateHierarchyViewer() {
if (fInputElement == null) {
fPagebook.showPage(fNoHierarchyShownLabel);
} else {
if (getCurrentViewer().containsElements() != null) {
Runnable runnable= new Runnable() {
public void run() {
getCurrentViewer().updateContent();
}
};
BusyIndicator.showWhile(getDisplay(), runnable);
if (!isChildVisible(fViewerbook, getCurrentViewer().getControl())) {
setViewerVisibility(true);
}
} else {
fEmptyTypesViewer.setText(TypeHierarchyMessages.getFormattedString("TypeHierarchyViewPart.nodecl", fInputElement.getElementName()));
setViewerVisibility(false);
}
}
}
private void updateMethodViewer(IType input) {
if (input != fMethodsViewer.getInput() && !fIsEnableMemberFilter && fCurrentOrientation != VIEW_ORIENTATION_SINGLE) {
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
if (input != null) {
fMethodViewerPaneLabel.setText(fPaneLabelProvider.getText(input));
fMethodViewerPaneLabel.setImage(fPaneLabelProvider.getImage(input));
} else {
fMethodViewerPaneLabel.setText("");
fMethodViewerPaneLabel.setImage(null);
}
fMethodsViewer.setInput(input);
}
}
private void doSelectionChanged(SelectionChangedEvent e) {
if (e.getSelectionProvider() == fMethodsViewer) {
methodSelectionChanged(e.getSelection());
} else {
typeSelectionChanged(e.getSelection());
}
}
private void methodSelectionChanged(ISelection sel) {
if (sel instanceof IStructuredSelection) {
List selected= ((IStructuredSelection)sel).toList();
int nSelected= selected.size();
if (fIsEnableMemberFilter) {
IMember[] memberFilter= null;
if (nSelected > 0) {
memberFilter= new IMember[nSelected];
selected.toArray(memberFilter);
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
}
setMemberFilter(memberFilter);
updateHierarchyViewer();
updateTitle();
internalSelectType(fSelectedType, true);
}
if (nSelected == 1) {
revealElementInEditor(selected.get(0), fMethodsViewer);
}
}
}
private void typeSelectionChanged(ISelection sel) {
if (sel instanceof IStructuredSelection) {
List selected= ((IStructuredSelection)sel).toList();
int nSelected= selected.size();
if (nSelected != 0) {
List types= new ArrayList(nSelected);
for (int i= nSelected-1; i >= 0; i--) {
Object elem= selected.get(i);
if (elem instanceof IType && !types.contains(elem)) {
types.add(elem);
}
}
if (types.size() == 1) {
fSelectedType= (IType) types.get(0);
updateMethodViewer(fSelectedType);
} else if (types.size() == 0) {
}
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
if (nSelected == 1) {
revealElementInEditor(selected.get(0), getCurrentViewer());
}
} else {
fSelectedType= null;
updateMethodViewer(null);
}
}
}
private void revealElementInEditor(Object elem, Viewer originViewer) {
if (getSite().getPage().getActivePart() != this) {
return;
}
if (fSelectionProviderMediator.getViewerInFocus() != originViewer) {
return;
}
IEditorPart editorPart= EditorUtility.isOpenInEditor(elem);
if (editorPart != null && (elem instanceof IJavaElement)) {
try {
getSite().getPage().removePartListener(fPartListener);
EditorUtility.openInEditor(elem, false);
EditorUtility.revealInEditor(editorPart, (IJavaElement) elem);
getSite().getPage().addPartListener(fPartListener);
} catch (CoreException e) {
JavaPlugin.log(e);
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
}
}
}
private Display getDisplay() {
if (fPagebook != null && !fPagebook.isDisposed()) {
return fPagebook.getDisplay();
}
return null;
}
private boolean isChildVisible(Composite pb, Control child) {
Control[] children= pb.getChildren();
for (int i= 0; i < children.length; i++) {
if (children[i] == child && children[i].isVisible())
return true;
}
return false;
}
private void updateTitle() {
String viewerTitle= getCurrentViewer().getTitle();
String tooltip;
String title;
if (fInputElement != null) {
String[] args= new String[] { viewerTitle, JavaElementLabels.getElementLabel(fInputElement, JavaElementLabels.ALL_DEFAULT) };
title= TypeHierarchyMessages.getFormattedString("TypeHierarchyViewPart.title", args);
tooltip= TypeHierarchyMessages.getFormattedString("TypeHierarchyViewPart.tooltip", args);
} else {
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
title= viewerTitle;
tooltip= viewerTitle;
}
setTitle(title);
setTitleToolTip(tooltip);
}
private void updateToolbarButtons() {
boolean isType= fInputElement instanceof IType;
for (int i= 0; i < fViewActions.length; i++) {
ToggleViewAction action= fViewActions[i];
if (action.getViewerIndex() == VIEW_ID_TYPE) {
action.setEnabled(fInputElement != null);
} else {
action.setEnabled(isType);
}
}
}
/**
* Sets the current view (see view id)
* called from ToggleViewAction. Must be called after creation of the viewpart.
*/
public void setView(int viewerIndex) {
Assert.isNotNull(fAllViewers);
if (viewerIndex < fAllViewers.length && fCurrentViewerIndex != viewerIndex) {
fCurrentViewerIndex= viewerIndex;
updateHierarchyViewer();
if (fInputElement != null) {
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
ISelection currSelection= getCurrentViewer().getSelection();
if (currSelection == null || currSelection.isEmpty()) {
internalSelectType(getSelectableType(fInputElement), false);
currSelection= getCurrentViewer().getSelection();
}
if (!fIsEnableMemberFilter) {
typeSelectionChanged(currSelection);
}
}
updateTitle();
fDialogSettings.put(DIALOGSTORE_HIERARCHYVIEW, viewerIndex);
getCurrentViewer().getTree().setFocus();
}
for (int i= 0; i < fViewActions.length; i++) {
ToggleViewAction action= fViewActions[i];
action.setChecked(fCurrentViewerIndex == action.getViewerIndex());
}
}
/**
* Gets the curret active view index.
*/
public int getViewIndex() {
return fCurrentViewerIndex;
}
private TypeHierarchyViewer getCurrentViewer() {
return fAllViewers[fCurrentViewerIndex];
}
/**
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
* called from EnableMemberFilterAction.
* Must be called after creation of the viewpart.
*/
public void enableMemberFilter(boolean on) {
if (on != fIsEnableMemberFilter) {
fIsEnableMemberFilter= on;
if (!on) {
IType methodViewerInput= (IType) fMethodsViewer.getInput();
setMemberFilter(null);
updateHierarchyViewer();
updateTitle();
if (methodViewerInput != null && getCurrentViewer().isElementShown(methodViewerInput)) {
internalSelectType(methodViewerInput, true);
} else if (fSelectedType != null) {
internalSelectType(fSelectedType, true);
updateMethodViewer(fSelectedType);
}
} else {
methodSelectionChanged(fMethodsViewer.getSelection());
}
}
fEnableMemberFilterAction.setChecked(on);
}
/**
* Called from ITypeHierarchyLifeCycleListener.
* Can be called from any thread
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
*/
private void doTypeHierarchyChanged(final TypeHierarchyLifeCycle typeHierarchy, final IType[] changedTypes) {
Display display= getDisplay();
if (display != null) {
display.asyncExec(new Runnable() {
public void run() {
if (fPagebook != null && !fPagebook.isDisposed()) {
doTypeHierarchyChangedOnViewers(changedTypes);
}
}
});
}
}
private void doTypeHierarchyChangedOnViewers(IType[] changedTypes) {
if (fHierarchyLifeCycle.getHierarchy() == null || !fHierarchyLifeCycle.getHierarchy().exists()) {
clearInput();
} else {
if (changedTypes == null) {
try {
fHierarchyLifeCycle.ensureRefreshedTypeHierarchy(fInputElement);
} catch (JavaModelException e) {
JavaPlugin.log(e.getStatus());
clearInput();
return;
}
updateHierarchyViewer();
} else {
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
if (getCurrentViewer().isMethodFiltering()) {
if (changedTypes.length == 1) {
getCurrentViewer().refresh(changedTypes[0]);
} else {
updateHierarchyViewer();
}
} else {
getCurrentViewer().update(changedTypes, new String[] { IBasicPropertyConstants.P_TEXT, IBasicPropertyConstants.P_IMAGE } );
}
}
fMethodsViewer.refresh();
}
}
/**
* Determines the input element to be used initially .
*/
private IJavaElement determineInputElement() {
Object input= getSite().getPage().getInput();
if (input instanceof IJavaElement) {
return (IJavaElement) input;
}
return null;
}
/*
* @see IViewPart#init
*/
public void init(IViewSite site, IMemento memento) throws PartInitException {
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
super.init(site, memento);
fMemento= memento;
}
/*
* @see ViewPart#saveState(IMemento)
*/
public void saveState(IMemento memento) {
if (fPagebook == null) {
if (fMemento != null) {
memento.putMemento(fMemento);
}
return;
}
if (fInputElement != null) {
String handleIndentifier= fInputElement.getHandleIdentifier();
if (fInputElement instanceof IType) {
ITypeHierarchy hierarchy= fHierarchyLifeCycle.getHierarchy();
if (hierarchy != null && hierarchy.getSupertypes((IType) fInputElement).length > 1000) {
}
}
memento.putString(TAG_INPUT, handleIndentifier);
}
memento.putInteger(TAG_VIEW, getViewIndex());
memento.putInteger(TAG_ORIENTATION, fCurrentOrientation);
int weigths[]= fTypeMethodsSplitter.getWeights();
int ratio= (weigths[0] * 1000) / (weigths[0] + weigths[1]);
memento.putInteger(TAG_RATIO, ratio);
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
ScrollBar bar= getCurrentViewer().getTree().getVerticalBar();
int position= bar != null ? bar.getSelection() : 0;
memento.putInteger(TAG_VERTICAL_SCROLL, position);
IJavaElement selection= (IJavaElement)((IStructuredSelection) getCurrentViewer().getSelection()).getFirstElement();
if (selection != null) {
memento.putString(TAG_SELECTION, selection.getHandleIdentifier());
}
fMethodsViewer.saveState(memento);
}
/**
* Restores the type hierarchy settings from a memento.
*/
private void restoreState(IMemento memento, IJavaElement defaultInput) {
IJavaElement input= defaultInput;
String elementId= memento.getString(TAG_INPUT);
if (elementId != null) {
input= null;
if (input != null && !input.exists()) {
input= null;
}
}
setInputElement(input);
Integer viewerIndex= memento.getInteger(TAG_VIEW);
if (viewerIndex != null) {
setView(viewerIndex.intValue());
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
}
Integer orientation= memento.getInteger(TAG_ORIENTATION);
if (orientation != null) {
setOrientation(orientation.intValue());
}
Integer ratio= memento.getInteger(TAG_RATIO);
if (ratio != null) {
fTypeMethodsSplitter.setWeights(new int[] { ratio.intValue(), 1000 - ratio.intValue() });
}
ScrollBar bar= getCurrentViewer().getTree().getVerticalBar();
if (bar != null) {
Integer vScroll= memento.getInteger(TAG_VERTICAL_SCROLL);
if (vScroll != null) {
bar.setSelection(vScroll.intValue());
}
}
String selectionId= memento.getString(TAG_SELECTION);
fMethodsViewer.restoreState(memento);
}
/**
* Link selection to active editor.
*/
private void editorActivated(IEditorPart editor) {
if (!JavaBasePreferencePage.linkTypeHierarchySelectionToEditor()) {
return;
}
if (fInputElement == null) {
|
15,486 |
Bug 15486 Hierarchy View takes 8 minutes to start up
|
In my workspace I have 24 projects. In each case, the java build path contains about 20 or more jar files from a target platform which I am extending with new plugins. I have one java perspective, which contains the following views: packages, navigator, outline. In the shortcut bar, I have the tasks, search, and repository view. There are no editors open. It takes about 20 seconds to start up. If I open the JavaEditor class using Open Type.., a java edior opens on the class and the hierarchy view opens. If I close the editor, shutdown, and restart, it takes me 8 minutes to restart. If I close the hierarchy view, shutdown, and restart, it takes about 20 seconds to start up. I am now afraid to shutdown eclipse with the hierarchy view open. Please help me.
|
verified fixed
|
dc4de44
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:48:14Z | 2002-05-07T22:20:00Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
|
return;
}
IJavaElement elem= (IJavaElement)editor.getEditorInput().getAdapter(IJavaElement.class);
try {
TypeHierarchyViewer currentViewer= getCurrentViewer();
if (elem instanceof IClassFile) {
IType type= ((IClassFile)elem).getType();
if (currentViewer.isElementShown(type)) {
internalSelectType(type, true);
updateMethodViewer(type);
}
} else if (elem instanceof ICompilationUnit) {
IType[] allTypes= ((ICompilationUnit)elem).getAllTypes();
for (int i= 0; i < allTypes.length; i++) {
if (currentViewer.isElementShown(allTypes[i])) {
internalSelectType(allTypes[i], true);
updateMethodViewer(allTypes[i]);
return;
}
}
}
} catch (JavaModelException e) {
JavaPlugin.log(e.getStatus());
}
}
}
|
17,598 |
Bug 17598 Source->Generate Getter and Setter enabled for read only file
|
F1 This action is enabled for read-only files. Executing it shows a dialog saying that the file is read-only. The action should be disabled since all other source actions are disabled as well.
|
verified fixed
|
6b03c57
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:51:22Z | 2002-05-24T11:33:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/AddGetterSetterAction.java
|
/*******************************************************************************
* Copyright (c) 2000, 2002 International Business Machines Corp. and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Common Public License v0.5
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/cpl-v05.html
*
* Contributors:
* IBM Corporation - initial API and implementation
******************************************************************************/
package org.eclipse.jdt.ui.actions;
import java.lang.reflect.InvocationTargetException;
import java.util.ArrayList;
import java.util.Collection;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.swt.graphics.Image;
import org.eclipse.swt.widgets.Shell;
import org.eclipse.jface.dialogs.IDialogConstants;
import org.eclipse.jface.dialogs.MessageDialog;
import org.eclipse.jface.dialogs.ProgressMonitorDialog;
import org.eclipse.jface.text.ITextSelection;
import org.eclipse.jface.viewers.ILabelProvider;
import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.jface.viewers.ITreeContentProvider;
import org.eclipse.jface.viewers.Viewer;
import org.eclipse.ui.IEditorPart;
|
17,598 |
Bug 17598 Source->Generate Getter and Setter enabled for read only file
|
F1 This action is enabled for read-only files. Executing it shows a dialog saying that the file is read-only. The action should be disabled since all other source actions are disabled as well.
|
verified fixed
|
6b03c57
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:51:22Z | 2002-05-24T11:33:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/AddGetterSetterAction.java
|
import org.eclipse.ui.IWorkbenchSite;
import org.eclipse.ui.dialogs.CheckedTreeSelectionDialog;
import org.eclipse.ui.dialogs.ISelectionStatusValidator;
import org.eclipse.ui.help.WorkbenchHelp;
import org.eclipse.jdt.core.ICompilationUnit;
import org.eclipse.jdt.core.IField;
import org.eclipse.jdt.core.IJavaElement;
import org.eclipse.jdt.core.IMember;
import org.eclipse.jdt.core.IMethod;
import org.eclipse.jdt.core.IType;
import org.eclipse.jdt.core.JavaModelException;
import org.eclipse.jdt.ui.JavaElementImageDescriptor;
import org.eclipse.jdt.ui.JavaElementLabelProvider;
import org.eclipse.jdt.ui.JavaElementSorter;
import org.eclipse.jdt.internal.corext.codemanipulation.AddGetterSetterOperation;
import org.eclipse.jdt.internal.corext.codemanipulation.CodeGenerationSettings;
import org.eclipse.jdt.internal.corext.codemanipulation.GetterSetterUtil;
import org.eclipse.jdt.internal.corext.codemanipulation.IRequestQuery;
import org.eclipse.jdt.internal.corext.codemanipulation.NameProposer;
import org.eclipse.jdt.internal.corext.refactoring.util.JavaElementUtil;
import org.eclipse.jdt.internal.corext.util.JavaModelUtil;
import org.eclipse.jdt.internal.ui.IJavaHelpContextIds;
import org.eclipse.jdt.internal.ui.JavaPlugin;
import org.eclipse.jdt.internal.ui.JavaPluginImages;
import org.eclipse.jdt.internal.ui.actions.ActionMessages;
import org.eclipse.jdt.internal.ui.actions.SelectionConverter;
import org.eclipse.jdt.internal.ui.actions.WorkbenchRunnableAdapter;
import org.eclipse.jdt.internal.ui.dialogs.StatusInfo;
import org.eclipse.jdt.internal.ui.javaeditor.CompilationUnitEditor;
import org.eclipse.jdt.internal.ui.javaeditor.EditorUtility;
|
17,598 |
Bug 17598 Source->Generate Getter and Setter enabled for read only file
|
F1 This action is enabled for read-only files. Executing it shows a dialog saying that the file is read-only. The action should be disabled since all other source actions are disabled as well.
|
verified fixed
|
6b03c57
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:51:22Z | 2002-05-24T11:33:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/AddGetterSetterAction.java
|
import org.eclipse.jdt.internal.ui.preferences.CodeGenerationPreferencePage;
import org.eclipse.jdt.internal.ui.preferences.JavaPreferencesSettings;
import org.eclipse.jdt.internal.ui.viewsupport.JavaElementImageProvider;
import org.eclipse.jdt.internal.ui.viewsupport.JavaElementLabels;
/**
* Create Getter and Setter for selected fields.
* Will open the parent compilation unit in the editor.
* The result is unsaved, so the user can decide if the
* changes are acceptable.
*
* <p>
* This class may be instantiated; it is not intended to be subclassed.
* </p>
*
* @since 2.0
*/
public class AddGetterSetterAction extends SelectionDispatchAction {
private CompilationUnitEditor fEditor;
private static final String dialogTitle= ActionMessages.getString("AddGetterSetterAction.error.title");
/**
* Creates a new <code>AddGetterSetterAction</code>.
*
* @param site the site providing context information for this action
*/
public AddGetterSetterAction(IWorkbenchSite site) {
super(site);
setText(ActionMessages.getString("AddGetterSetterAction.label"));
setDescription(ActionMessages.getString("AddGetterSetterAction.description"));
setToolTipText(ActionMessages.getString("AddGetterSetterAction.tooltip"));
|
17,598 |
Bug 17598 Source->Generate Getter and Setter enabled for read only file
|
F1 This action is enabled for read-only files. Executing it shows a dialog saying that the file is read-only. The action should be disabled since all other source actions are disabled as well.
|
verified fixed
|
6b03c57
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:51:22Z | 2002-05-24T11:33:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/AddGetterSetterAction.java
|
WorkbenchHelp.setHelp(this, IJavaHelpContextIds.GETTERSETTER_ACTION);
}
/**
* Creates a new <code>AddGetterSetterAction</code>.
* <p>
* Note: This constructor is for internal use only. Clients should not call this constructor.
* </p>
*/
public AddGetterSetterAction(CompilationUnitEditor editor) {
this(editor.getEditorSite());
fEditor= editor;
}
/* (non-Javadoc)
* Method declared on SelectionDispatchAction
*/
protected void selectionChanged(IStructuredSelection selection) {
try {
setEnabled(canEnable(selection));
} catch (JavaModelException e) {
JavaPlugin.log(e);
setEnabled(false);
}
}
/* (non-Javadoc)
* Method declared on SelectionDispatchAction
|
17,598 |
Bug 17598 Source->Generate Getter and Setter enabled for read only file
|
F1 This action is enabled for read-only files. Executing it shows a dialog saying that the file is read-only. The action should be disabled since all other source actions are disabled as well.
|
verified fixed
|
6b03c57
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:51:22Z | 2002-05-24T11:33:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/AddGetterSetterAction.java
|
*/
protected void run(IStructuredSelection selection) {
try {
IField[] selectedFields= getSelectedFields(selection);
if (canEnableOn(selectedFields)){
run(selectedFields[0].getDeclaringType(), selectedFields);
return;
}
Object firstElement= selection.getFirstElement();
if (firstElement instanceof IType)
run((IType)firstElement, new IField[0]);
else if (firstElement instanceof ICompilationUnit)
run(JavaElementUtil.getMainType((ICompilationUnit)firstElement), new IField[0]);
} catch (CoreException e) {
JavaPlugin.log(e.getStatus());
showError(ActionMessages.getString("AddGetterSetterAction.error.actionfailed"));
}
}
private boolean canEnable(IStructuredSelection selection) throws JavaModelException{
if (canEnableOn(getSelectedFields(selection)))
return true;
if ((selection.size() == 1) && (selection.getFirstElement() instanceof IType))
return canEnableOn((IType)selection.getFirstElement());
if ((selection.size() == 1) && (selection.getFirstElement() instanceof ICompilationUnit))
return canEnableOn(JavaElementUtil.getMainType((ICompilationUnit)selection.getFirstElement()));
return false;
}
|
17,598 |
Bug 17598 Source->Generate Getter and Setter enabled for read only file
|
F1 This action is enabled for read-only files. Executing it shows a dialog saying that the file is read-only. The action should be disabled since all other source actions are disabled as well.
|
verified fixed
|
6b03c57
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:51:22Z | 2002-05-24T11:33:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/AddGetterSetterAction.java
|
private static boolean canEnableOn(IType type) throws JavaModelException {
if (type == null)
return false;
if (type.getFields().length == 0)
return false;
if (type.getCompilationUnit() == null)
return false;
if (JavaModelUtil.isEditable(type.getCompilationUnit()))
return true;
return false;
}
private static boolean canEnableOn(IField[] fields) throws JavaModelException {
return fields != null && fields.length > 0 && JavaModelUtil.isEditable(fields[0].getCompilationUnit());
}
private void run(IType type, IField[] preselected) throws CoreException{
ILabelProvider lp= new AddGetterSetterLabelProvider(createNameProposer());
Map entries= createGetterSetterMapping(type);
if (entries.isEmpty()){
MessageDialog.openInformation(getShell(), dialogTitle, "The type contains no fields or all fields have getters/setters already.");
return;
}
ITreeContentProvider cp= new AddGetterSetterContentProvider(entries);
CheckedTreeSelectionDialog dialog= new CheckedTreeSelectionDialog(getShell(), lp, cp);
dialog.setSorter(new JavaElementSorter());
dialog.setTitle(dialogTitle);
String message= ActionMessages.getFormattedString("AddGetterSetterAction.dialog.title", JavaElementUtil.createSignature(type));
dialog.setMessage(message);
dialog.setValidator(createValidator());
|
17,598 |
Bug 17598 Source->Generate Getter and Setter enabled for read only file
|
F1 This action is enabled for read-only files. Executing it shows a dialog saying that the file is read-only. The action should be disabled since all other source actions are disabled as well.
|
verified fixed
|
6b03c57
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:51:22Z | 2002-05-24T11:33:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/AddGetterSetterAction.java
|
dialog.setContainerMode(true);
dialog.setSize(60, 18);
dialog.setInput(type);
dialog.setExpandedElements(type.getFields());
dialog.setInitialSelections(preselected);
dialog.open();
Object[] result= dialog.getResult();
if (result == null)
return;
IField[] getterFields= getGetterFields(result);
IField[] setterFields= getSetterFields(result);
generate(getterFields, setterFields);
}
private static ISelectionStatusValidator createValidator() {
return new ISelectionStatusValidator(){
public IStatus validate(Object[] selection) {
int count= countSelectedMethods(selection);
if (count == 0)
return new StatusInfo(IStatus.ERROR, "");
if (count == 1)
return new StatusInfo(IStatus.INFO, ActionMessages.getString("AddGetterSetterAction.one_selected"));
String message= ActionMessages.getFormattedString("AddGetterSetterAction.methods_selected", String.valueOf(count));
return new StatusInfo(IStatus.INFO, message);
}
};
}
private static int countSelectedMethods(Object[] selection){
int count= 0;
|
17,598 |
Bug 17598 Source->Generate Getter and Setter enabled for read only file
|
F1 This action is enabled for read-only files. Executing it shows a dialog saying that the file is read-only. The action should be disabled since all other source actions are disabled as well.
|
verified fixed
|
6b03c57
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:51:22Z | 2002-05-24T11:33:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/AddGetterSetterAction.java
|
for (int i = 0; i < selection.length; i++) {
if (selection[i] instanceof GetterSetterEntry)
count++;
}
return count;
}
private static IField[] getGetterFields(Object[] result){
Collection list= new ArrayList(0);
for (int i = 0; i < result.length; i++) {
Object each= result[i];
if ((each instanceof GetterSetterEntry)){
GetterSetterEntry entry= (GetterSetterEntry)each;
if (entry.isGetterEntry)
list.add(entry.field);
}
}
return (IField[]) list.toArray(new IField[list.size()]);
}
private static IField[] getSetterFields(Object[] result){
Collection list= new ArrayList(0);
for (int i = 0; i < result.length; i++) {
Object each= result[i];
if ((each instanceof GetterSetterEntry)){
GetterSetterEntry entry= (GetterSetterEntry)each;
if (! entry.isGetterEntry)
list.add(entry.field);
}
}
|
17,598 |
Bug 17598 Source->Generate Getter and Setter enabled for read only file
|
F1 This action is enabled for read-only files. Executing it shows a dialog saying that the file is read-only. The action should be disabled since all other source actions are disabled as well.
|
verified fixed
|
6b03c57
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:51:22Z | 2002-05-24T11:33:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/AddGetterSetterAction.java
|
return (IField[]) list.toArray(new IField[list.size()]);
}
private static NameProposer createNameProposer(){
return new NameProposer(getGetterSetterPrefixes(), getGetterSetterSuffixes());
}
private static String[] getGetterSetterPrefixes(){
return CodeGenerationPreferencePage.getGetterStetterPrefixes();
}
private static String[] getGetterSetterSuffixes(){
return CodeGenerationPreferencePage.getGetterStetterSuffixes();
}
private void generate(IField[] getterFields, IField[] setterFields) throws CoreException{
if (getterFields.length == 0 && setterFields.length == 0)
return;
ICompilationUnit cu= null;
if (getterFields.length != 0)
cu= getterFields[0].getCompilationUnit();
else
cu= setterFields[0].getCompilationUnit();
IEditorPart editor= EditorUtility.openInEditor(cu);
IField[] workingCopyGetterFields= getWorkingCopyFields(getterFields);
IField[] workingCopySetterFields= getWorkingCopyFields(setterFields);
if (workingCopyGetterFields != null && workingCopySetterFields != null)
|
17,598 |
Bug 17598 Source->Generate Getter and Setter enabled for read only file
|
F1 This action is enabled for read-only files. Executing it shows a dialog saying that the file is read-only. The action should be disabled since all other source actions are disabled as well.
|
verified fixed
|
6b03c57
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:51:22Z | 2002-05-24T11:33:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/AddGetterSetterAction.java
|
run(workingCopyGetterFields, workingCopySetterFields, editor);
}
private IField[] getWorkingCopyFields(IField[] fields) throws CoreException{
if (fields.length == 0)
return new IField[0];
ICompilationUnit cu= fields[0].getCompilationUnit();
ICompilationUnit workingCopyCU;
IField[] workingCopyFields;
if (cu.isWorkingCopy()) {
workingCopyCU= cu;
workingCopyFields= fields;
} else {
workingCopyCU= EditorUtility.getWorkingCopy(cu);
if (workingCopyCU == null) {
showError(ActionMessages.getString("AddGetterSetterAction.error.actionfailed"));
return null;
}
workingCopyFields= new IField[fields.length];
for (int i= 0; i < fields.length; i++) {
IField field= fields[i];
IField workingCopyField= (IField) JavaModelUtil.findMemberInCompilationUnit(workingCopyCU, field);
if (workingCopyField == null) {
showError(ActionMessages.getFormattedString("AddGetterSetterAction.error.fieldNotExisting", field.getElementName()));
return null;
}
workingCopyFields[i]= workingCopyField;
}
}
|
17,598 |
Bug 17598 Source->Generate Getter and Setter enabled for read only file
|
F1 This action is enabled for read-only files. Executing it shows a dialog saying that the file is read-only. The action should be disabled since all other source actions are disabled as well.
|
verified fixed
|
6b03c57
|
JDT
|
https://github.com/eclipse-jdt/eclipse.jdt.ui
|
eclipse-jdt/eclipse.jdt.ui
|
java
| null | null | null | 2002-05-27T16:51:22Z | 2002-05-24T11:33:20Z |
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/actions/AddGetterSetterAction.java
|
return workingCopyFields;
}
/* (non-Javadoc)
* Method declared on SelectionDispatchAction
*/
protected void selectionChanged(ITextSelection selection) {
setEnabled(fEditor != null);
}
/* (non-Javadoc)
* Method declared on SelectionDispatchAction
*/
protected void run(ITextSelection selection) {
try {
IJavaElement[] elements= SelectionConverter.codeResolve(fEditor);
if (elements.length == 1 && (elements[0] instanceof IField)) {
IField field= (IField)elements[0];
if (! checkCu(field))
return;
run(field.getDeclaringType(), new IField[] {field});
return;
}
IJavaElement element= SelectionConverter.getElementAtOffset(fEditor);
if (element != null){
IType type= (IType)element.getAncestor(IJavaElement.TYPE);
if (type != null){
if (! checkCu(type))
return;
if (type.getFields().length > 0){
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.