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
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
public void typeHierarchyChanged(TypeHierarchyLifeCycle typeHierarchy, IType[] changedTypes) { doTypeHierarchyChanged(typeHierarchy, changedTypes); } }; fHierarchyLifeCycle.addChangedListener(fTypeHierarchyLifeCycleListener); fHierarchyProblemListener= null; 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) };
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
fEnableMemberFilterAction= new EnableMemberFilterAction(this, false); fFocusOnTypeAction= new FocusOnTypeAction(this); fPaneLabelProvider= new JavaElementLabelProvider(JavaElementLabelProvider.SHOW_BASICS); fPaneLabelProvider.setErrorTickManager(new MarkerErrorTickProvider()); 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); } }; } /**
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
* 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); } 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); } } /**
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
* Gets all history entries. */ public IJavaElement[] getHistoryEntries() { if (fInputHistory.size() > 0) { updateHistoryEntries(); } 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 */ public void selectMember(IMember member) { ICompilationUnit cu= member.getCompilationUnit(); if (cu != null && cu.isWorkingCopy()) { member= (IMember) cu.getOriginal(member); if (member == null) { return; }
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
} Control methodControl= fMethodsViewer.getControl(); if (methodControl != null && !methodControl.isDisposed()) { fMethodsViewer.getControl().setFocus(); } fMethodsViewer.setSelection(new StructuredSelection(member), true); } /** * @deprecated */ public IType getInput() { if (fInputElement instanceof IType) { return (IType) fInputElement; } return null; } /** * 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() {
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
return fInputElement; } /** * Sets the input to a new element. */ public void setInputElement(IJavaElement element) { if (element != null) { if (element instanceof IMember) { 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")); return; } } if (element.getElementType() == IJavaElement.METHOD || element.getElementType() == IJavaElement.FIELD || element.getElementType() == IJavaElement.INITIALIZER) { element= ((IMember) element).getDeclaringType(); } } } if (element != null && !element.equals(fInputElement)) { addHistoryEntry(element); } updateInput(element); } /**
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
* 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; } 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);
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
updateToolbarButtons(); updateTitle(); enableMemberFilter(false); } } private void clearInput() { fInputElement= null; fHierarchyLifeCycle.freeHierarchy(); updateHierarchyViewer(); updateToolbarButtons(); } /* * @see IWorbenchPart#setFocus */ public void setFocus() { fPagebook.setFocus(); } /* * @see IWorkbenchPart#dispose */ public void dispose() { fHierarchyLifeCycle.freeHierarchy(); fHierarchyLifeCycle.removeChangedListener(fTypeHierarchyLifeCycleListener); fPaneLabelProvider.dispose(); getSite().getPage().removePartListener(fPartListener); if (fHierarchyProblemListener != null) { JavaPlugin.getDefault().getProblemMarkerManager().removeListener(fHierarchyProblemListener); }
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
if (fMethodsViewer != null) { JavaPlugin.getDefault().getProblemMarkerManager().removeListener(fMethodsViewer); } super.dispose(); } private Control createTypeViewerControl(Composite parent) { fViewerbook= new PageBook(parent, SWT.NULL); KeyListener keyListener= createKeyListener(); HierarchyLabelProvider lprovider= new HierarchyLabelProvider(this, new MarkerErrorTickProvider()); TypeHierarchyViewer superTypesViewer= new SuperTypeHierarchyViewer(fViewerbook, fHierarchyLifeCycle, lprovider, this); initializeTypesViewer(superTypesViewer, keyListener, IContextMenuConstants.TARGET_ID_SUPERTYPES_VIEW); TypeHierarchyViewer subTypesViewer= new SubTypeHierarchyViewer(fViewerbook, fHierarchyLifeCycle, lprovider, this); initializeTypesViewer(subTypesViewer, keyListener, IContextMenuConstants.TARGET_ID_SUBTYPES_VIEW); TypeHierarchyViewer vajViewer= new TraditionalHierarchyViewer(fViewerbook, fHierarchyLifeCycle, lprovider, this); initializeTypesViewer(vajViewer, keyListener, IContextMenuConstants.TARGET_ID_HIERARCHY_VIEW); fAllViewers= new TypeHierarchyViewer[3]; fAllViewers[VIEW_ID_SUPER]= superTypesViewer; fAllViewers[VIEW_ID_SUB]= subTypesViewer; fAllViewers[VIEW_ID_TYPE]= vajViewer; int currViewerIndex; try { currViewerIndex= fDialogSettings.getInt(DIALOGSTORE_HIERARCHYVIEW);
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
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 keyPressed(KeyEvent event) { if (event.stateMask == 0) { if (event.keyCode == SWT.F4) { OpenTypeHierarchyUtil.open(getSite().getSelectionProvider().getSelection(), getSite().getWorkbenchWindow()); return; } else if (event.keyCode == SWT.F5) { updateHierarchyViewer(); return;
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
} } 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, this); fMethodsViewer.initContextMenu(new IMenuListener() { public void menuAboutToShow(IMenuManager menu) { fillMethodsViewerContextMenu(menu); } }, IContextMenuConstants.TARGET_ID_MEMBERS_VIEW, getSite()); fMethodsViewer.addSelectionChangedListener(fSelectionChangedListener); Control control= fMethodsViewer.getTable(); control.addKeyListener(createKeyListener());
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
JavaPlugin.getDefault().getProblemMarkerManager().addListener(fMethodsViewer); return control; } private void initDragAndDrop() { Transfer[] transfers= new Transfer[] { LocalSelectionTransfer.getInstance() }; int ops= DND.DROP_COPY; DragSource source= new DragSource(fMethodsViewer.getControl(), ops); source.setTransfer(transfers); source.addDragListener(new BasicSelectionTransferDragAdapter(fMethodsViewer)); for (int i= 0; i < fAllViewers.length; i++) { TypeHierarchyViewer curr= fAllViewers[i]; curr.addDropSupport(ops, transfers, new TypeHierarchyTransferDropAdapter(curr)); } } 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); } } }
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
/** * Returns the inner component in a workbench part. * @see IWorkbenchPart#createPartControl */ public void createPartControl(Composite container) { 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); initDragAndDrop(); ToolBar methodViewerToolBar= new ToolBar(fMethodViewerViewForm, SWT.FLAT | SWT.WRAP); fMethodViewerViewForm.setTopCenter(methodViewerToolBar);
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
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)); 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]); }
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
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); 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);
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
} WorkbenchHelp.setHelp(fPagebook, new ViewContextComputer(this, IJavaHelpContextIds.TYPE_HIERARCHY_VIEW)); } /** * 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); } updateMainToolbar(orientation); fTypeMethodsSplitter.layout(); }
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
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); } } private void fillMainToolBar(IToolBarManager tbmanager) { tbmanager.removeAll(); tbmanager.add(fHistoryDropDownAction);
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
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); viewer.contributeToContextMenu(menu); IStructuredSelection selection= (IStructuredSelection)viewer.getSelection(); if (JavaBasePreferencePage.openTypeHierarchyInPerspective()) { addOpenPerspectiveItem(menu, selection); } addOpenWithMenu(menu, selection); menu.appendToGroup(IContextMenuConstants.GROUP_SHOW, fFocusOnTypeAction); if (fFocusOnSelectionAction.canActionBeAdded()) menu.appendToGroup(IContextMenuConstants.GROUP_SHOW, fFocusOnSelectionAction); addRefactoring(menu, viewer); ContextMenuGroup.add(menu, new ContextMenuGroup[] { new BuildGroup(), new ReorgGroup() }, viewer);
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40: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); } addOpenWithMenu(menu, (IStructuredSelection)fMethodsViewer.getSelection()); addRefactoring(menu, fMethodsViewer); ContextMenuGroup.add(menu, new ContextMenuGroup[] { new BuildGroup(), new ReorgGroup() }, fMethodsViewer); } private void addRefactoring(IMenuManager menu, IInputSelectionProvider viewer){ MenuManager refactoring= new MenuManager(TypeHierarchyMessages.getString("TypeHierarchyViewPart.menu.refactor")); ContextMenuGroup.add(refactoring, new ContextMenuGroup[] { new RefactoringGroup() }, viewer); if (!refactoring.isEmpty()) menu.appendToGroup(IContextMenuConstants.GROUP_REORGANIZE, refactoring); } private void addOpenWithMenu(IMenuManager menu, IStructuredSelection selection) { if (selection.size() != 1) return; Object element= selection.getFirstElement();
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
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); } private void addOpenPerspectiveItem(IMenuManager menu, IStructuredSelection selection) { OpenTypeHierarchyUtil.addToMenu(getSite().getWorkbenchWindow(), menu, selection); } /** * Toggles between the empty viewer page and the hierarchy */ private void setViewerVisibility(boolean showHierarchy) { if (showHierarchy) { fViewerbook.showPage(getCurrentViewer().getControl()); } else { fViewerbook.showPage(fEmptyTypesViewer); } }
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40: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); } fIsEnableMemberFilter= (memberFilter != null); } 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);
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
fMethodsViewer.addSelectionChangedListener(fSelectionChangedListener); } /** * 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) {
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
if (input != fMethodsViewer.getInput() && !fIsEnableMemberFilter && fCurrentOrientation != VIEW_ORIENTATION_SINGLE) { 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];
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
selected.toArray(memberFilter); } 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) {
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40: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) {
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
JavaPlugin.log(e); } } } 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);
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
} else { 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();
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
if (fInputElement != null) { ISelection currSelection= getCurrentViewer().getSelection(); if (currSelection == null || currSelection.isEmpty()) { internalSelectType(getSelectableType(fInputElement), false); } if (!fIsEnableMemberFilter) { typeSelectionChanged(currSelection); } } updateTitle(); if (fHierarchyProblemListener != null) { JavaPlugin.getDefault().getProblemMarkerManager().removeListener(fHierarchyProblemListener); } fHierarchyProblemListener= getCurrentViewer(); JavaPlugin.getDefault().getProblemMarkerManager().addListener(fHierarchyProblemListener); 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() {
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
return fCurrentViewerIndex; } private TypeHierarchyViewer getCurrentViewer() { return fAllViewers[fCurrentViewerIndex]; } /** * 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()); }
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
} fEnableMemberFilterAction.setChecked(on); } /** * Called from ITypeHierarchyLifeCycleListener. * Can be called from any thread */ private void doTypeHierarchyChanged(final TypeHierarchyLifeCycle typeHierarchy, final IType[] changedTypes) { Display display= getDisplay(); if (display != null) { display.asyncExec(new Runnable() { public void run() { 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();
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
return; } updateHierarchyViewer(); } else { 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 } ); } } } } /** * 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; }
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
/* * @see IViewPart#init */ public void init(IViewSite site, IMemento memento) throws PartInitException { 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) { memento.putString(TAG_INPUT, fInputElement.getHandleIdentifier()); } 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); ScrollBar bar= getCurrentViewer().getTree().getVerticalBar(); int position= bar != null ? bar.getSelection() : 0;
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
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= JavaCore.create(elementId); if (!input.exists()) { input= null; } } setInputElement(input); Integer viewerIndex= memento.getInteger(TAG_VIEW); if (viewerIndex != null) { setView(viewerIndex.intValue()); } Integer orientation= memento.getInteger(TAG_ORIENTATION); if (orientation != null) { setOrientation(orientation.intValue()); }
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/TypeHierarchyViewPart.java
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); if (selectionId != null) { IJavaElement elem= JavaCore.create(selectionId); if (getCurrentViewer().isElementShown(elem) && elem instanceof IMember) { internalSelectType((IMember)elem, false); } } fMethodsViewer.restoreState(memento); } /** * Link selection to active editor. */ private void editorActivated(IEditorPart editor) { if (!JavaBasePreferencePage.linkTypeHierarchySelectionToEditor()) { return; } if (fInputElement == null) {
7,540
Bug 7540 JDT Type hierarchy "Lock view ..." doen't work always
If the "Lock view and show members in hierarchy" is selected before any method is selected in method pane, the class pane isn t updated, if a method is selected afterwards. Selecting a method and select "Lock view..." works as expected
resolved fixed
f58d6b6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:27:26Z
2002-01-14T17:40: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()); } } }
7,591
Bug 7591 Flicker when toggeling show inherited filter
When toggeling the show inherited filter in the type hierarchy you can watch the scrollbar grow. We should bracket this refresh with setRedraw(false/true) so that there is only a single refresh.
verified fixed
d21e057
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:29:53Z
2002-01-15T10:20:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/MethodsViewer.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.swt.SWT; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Menu; import org.eclipse.swt.widgets.ScrollBar; import org.eclipse.swt.widgets.Table; import org.eclipse.jface.action.IMenuListener; import org.eclipse.jface.action.IMenuManager; import org.eclipse.jface.action.MenuManager; import org.eclipse.jface.action.Separator; import org.eclipse.jface.action.ToolBarManager; import org.eclipse.jface.viewers.DoubleClickEvent; import org.eclipse.jface.viewers.IDoubleClickListener; import org.eclipse.jface.viewers.ISelection; import org.eclipse.jface.viewers.StructuredSelection; import org.eclipse.jface.viewers.Viewer; import org.eclipse.ui.IMemento; import org.eclipse.ui.IWorkbenchPart; import org.eclipse.ui.IWorkbenchPartSite;
7,591
Bug 7591 Flicker when toggeling show inherited filter
When toggeling the show inherited filter in the type hierarchy you can watch the scrollbar grow. We should bracket this refresh with setRedraw(false/true) so that there is only a single refresh.
verified fixed
d21e057
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:29:53Z
2002-01-15T10:20:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/MethodsViewer.java
import org.eclipse.jdt.core.IJavaElement; import org.eclipse.jdt.core.IMethod; import org.eclipse.jdt.core.JavaModelException; import org.eclipse.jdt.ui.IContextMenuConstants; import org.eclipse.jdt.ui.JavaElementLabelProvider; 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.ContextMenuGroup; import org.eclipse.jdt.internal.ui.actions.GenerateGroup; import org.eclipse.jdt.internal.ui.actions.OpenJavaElementAction; import org.eclipse.jdt.internal.ui.search.JavaSearchGroup; import org.eclipse.jdt.internal.ui.util.ExceptionHandler; import org.eclipse.jdt.internal.ui.util.SelectionUtil; import org.eclipse.jdt.internal.ui.viewsupport.JavaElementLabels; import org.eclipse.jdt.internal.ui.viewsupport.JavaElementSorter; import org.eclipse.jdt.internal.ui.viewsupport.MarkerErrorTickProvider; import org.eclipse.jdt.internal.ui.viewsupport.ProblemTableViewer; /** * Method viewer shows a list of methods of a input type. * Offers filter actions. * No dependency to the type hierarchy view */ public class MethodsViewer extends ProblemTableViewer { /** * Sorter that uses the unmodified labelprovider (No declaring class names) */ private static class MethodsViewerSorter extends JavaElementSorter {
7,591
Bug 7591 Flicker when toggeling show inherited filter
When toggeling the show inherited filter in the type hierarchy you can watch the scrollbar grow. We should bracket this refresh with setRedraw(false/true) so that there is only a single refresh.
verified fixed
d21e057
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:29:53Z
2002-01-15T10:20:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/MethodsViewer.java
public MethodsViewerSorter() { } public int compare(Viewer viewer, Object e1, Object e2) { int cat1 = category(e1); int cat2 = category(e2); if (cat1 != cat2) return cat1 - cat2; String name1= JavaElementLabels.getElementLabel((IJavaElement) e1, JavaElementLabels.ALL_DEFAULT); String name2= JavaElementLabels.getElementLabel((IJavaElement) e2, JavaElementLabels.ALL_DEFAULT); return getCollator().compare(name1, name2); } } private static final String TAG_HIDEFIELDS= "hidefields"; private static final String TAG_HIDESTATIC= "hidestatic"; private static final String TAG_HIDENONPUBLIC= "hidenonpublic"; private static final String TAG_SHOWINHERITED= "showinherited"; private static final String TAG_VERTICAL_SCROLL= "mv_vertical_scroll"; private MethodsViewerFilterAction[] fFilterActions; private MethodsViewerFilter fFilter; private OpenJavaElementAction fOpen;
7,591
Bug 7591 Flicker when toggeling show inherited filter
When toggeling the show inherited filter in the type hierarchy you can watch the scrollbar grow. We should bracket this refresh with setRedraw(false/true) so that there is only a single refresh.
verified fixed
d21e057
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:29:53Z
2002-01-15T10:20:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/MethodsViewer.java
private ShowInheritedMembersAction fShowInheritedMembersAction; private ContextMenuGroup[] fStandardGroups; public MethodsViewer(Composite parent, IWorkbenchPart part) { super(new Table(parent, SWT.MULTI)); JavaElementLabelProvider lprovider= new JavaElementLabelProvider(JavaElementLabelProvider.SHOW_DEFAULT); lprovider.setErrorTickManager(new MarkerErrorTickProvider()); MethodsContentProvider contentProvider= new MethodsContentProvider(); setLabelProvider(lprovider); setContentProvider(contentProvider); fOpen= new OpenJavaElementAction(this); addDoubleClickListener(new IDoubleClickListener() { public void doubleClick(DoubleClickEvent event) { fOpen.run(); } }); fFilter= new MethodsViewerFilter(); String title= TypeHierarchyMessages.getString("MethodsViewer.hide_fields.label"); String helpContext= IJavaHelpContextIds.FILTER_FIELDS_ACTION; MethodsViewerFilterAction hideFields= new MethodsViewerFilterAction(this, title, MethodsViewerFilter.FILTER_FIELDS, helpContext, false); hideFields.setDescription(TypeHierarchyMessages.getString("MethodsViewer.hide_fields.description")); hideFields.setToolTipChecked(TypeHierarchyMessages.getString("MethodsViewer.hide_fields.tooltip.checked"));
7,591
Bug 7591 Flicker when toggeling show inherited filter
When toggeling the show inherited filter in the type hierarchy you can watch the scrollbar grow. We should bracket this refresh with setRedraw(false/true) so that there is only a single refresh.
verified fixed
d21e057
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:29:53Z
2002-01-15T10:20:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/MethodsViewer.java
hideFields.setToolTipUnchecked(TypeHierarchyMessages.getString("MethodsViewer.hide_fields.tooltip.unchecked")); JavaPluginImages.setLocalImageDescriptors(hideFields, "fields_co.gif"); title= TypeHierarchyMessages.getString("MethodsViewer.hide_static.label"); helpContext= IJavaHelpContextIds.FILTER_STATIC_ACTION; MethodsViewerFilterAction hideStatic= new MethodsViewerFilterAction(this, title, MethodsViewerFilter.FILTER_STATIC, helpContext, false); hideStatic.setDescription(TypeHierarchyMessages.getString("MethodsViewer.hide_static.description")); hideStatic.setToolTipChecked(TypeHierarchyMessages.getString("MethodsViewer.hide_static.tooltip.checked")); hideStatic.setToolTipUnchecked(TypeHierarchyMessages.getString("MethodsViewer.hide_static.tooltip.unchecked")); JavaPluginImages.setLocalImageDescriptors(hideStatic, "static_co.gif"); title= TypeHierarchyMessages.getString("MethodsViewer.hide_nonpublic.label"); helpContext= IJavaHelpContextIds.FILTER_PUBLIC_ACTION; MethodsViewerFilterAction hideNonPublic= new MethodsViewerFilterAction(this, title, MethodsViewerFilter.FILTER_NONPUBLIC, helpContext, false); hideNonPublic.setDescription(TypeHierarchyMessages.getString("MethodsViewer.hide_nonpublic.description")); hideNonPublic.setToolTipChecked(TypeHierarchyMessages.getString("MethodsViewer.hide_nonpublic.tooltip.checked")); hideNonPublic.setToolTipUnchecked(TypeHierarchyMessages.getString("MethodsViewer.hide_nonpublic.tooltip.unchecked")); JavaPluginImages.setLocalImageDescriptors(hideNonPublic, "public_co.gif"); fFilterActions= new MethodsViewerFilterAction[] { hideFields, hideStatic, hideNonPublic }; addFilter(fFilter); fShowInheritedMembersAction= new ShowInheritedMembersAction(this, false); showInheritedMethods(false); fStandardGroups= new ContextMenuGroup[] {
7,591
Bug 7591 Flicker when toggeling show inherited filter
When toggeling the show inherited filter in the type hierarchy you can watch the scrollbar grow. We should bracket this refresh with setRedraw(false/true) so that there is only a single refresh.
verified fixed
d21e057
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:29:53Z
2002-01-15T10:20:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/MethodsViewer.java
new JavaSearchGroup(), new GenerateGroup() }; setSorter(new MethodsViewerSorter()); } /** * Show inherited methods */ public void showInheritedMethods(boolean on) { MethodsContentProvider cprovider= (MethodsContentProvider) getContentProvider(); try { cprovider.showInheritedMethods(on); fShowInheritedMembersAction.setChecked(on); JavaElementLabelProvider lprovider= (JavaElementLabelProvider) getLabelProvider(); if (on) { lprovider.turnOn(JavaElementLabelProvider.SHOW_POST_QUALIFIED); } else { lprovider.turnOff(JavaElementLabelProvider.SHOW_POST_QUALIFIED); } refresh(); } catch (JavaModelException e) { ExceptionHandler.handle(e, getControl().getShell(), TypeHierarchyMessages.getString("MethodsViewer.toggle.error.title"), TypeHierarchyMessages.getString("MethodsViewer.toggle.error.message")); } } /* * @see Viewer#inputChanged(Object, Object)
7,591
Bug 7591 Flicker when toggeling show inherited filter
When toggeling the show inherited filter in the type hierarchy you can watch the scrollbar grow. We should bracket this refresh with setRedraw(false/true) so that there is only a single refresh.
verified fixed
d21e057
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:29:53Z
2002-01-15T10:20:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/MethodsViewer.java
*/ protected void inputChanged(Object input, Object oldInput) { super.inputChanged(input, oldInput); } /** * Returns <code>true</code> if inherited methods are shown. */ public boolean isShowInheritedMethods() { return ((MethodsContentProvider) getContentProvider()).isShowInheritedMethods(); } /** * Filters the method list */ public void setMemberFilter(int filterProperty, boolean set) { if (set) { fFilter.addFilter(filterProperty); } else { fFilter.removeFilter(filterProperty); } for (int i= 0; i < fFilterActions.length; i++) { if (fFilterActions[i].getFilterProperty() == filterProperty) { fFilterActions[i].setChecked(set); } } refresh(); } /** * Returns <code>true</code> if the given filter is set. */
7,591
Bug 7591 Flicker when toggeling show inherited filter
When toggeling the show inherited filter in the type hierarchy you can watch the scrollbar grow. We should bracket this refresh with setRedraw(false/true) so that there is only a single refresh.
verified fixed
d21e057
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:29:53Z
2002-01-15T10:20:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/MethodsViewer.java
public boolean hasMemberFilter(int filterProperty) { return fFilter.hasFilter(filterProperty); } /** * Saves the state of the filter actions */ public void saveState(IMemento memento) { memento.putString(TAG_HIDEFIELDS, String.valueOf(hasMemberFilter(MethodsViewerFilter.FILTER_FIELDS))); memento.putString(TAG_HIDESTATIC, String.valueOf(hasMemberFilter(MethodsViewerFilter.FILTER_STATIC))); memento.putString(TAG_HIDENONPUBLIC, String.valueOf(hasMemberFilter(MethodsViewerFilter.FILTER_NONPUBLIC))); memento.putString(TAG_SHOWINHERITED, String.valueOf(isShowInheritedMethods())); ScrollBar bar= getTable().getVerticalBar(); int position= bar != null ? bar.getSelection() : 0; memento.putString(TAG_VERTICAL_SCROLL, String.valueOf(position)); } /** * Restores the state of the filter actions */ public void restoreState(IMemento memento) { boolean set= Boolean.valueOf(memento.getString(TAG_HIDEFIELDS)).booleanValue(); setMemberFilter(MethodsViewerFilter.FILTER_FIELDS, set); set= Boolean.valueOf(memento.getString(TAG_HIDESTATIC)).booleanValue(); setMemberFilter(MethodsViewerFilter.FILTER_STATIC, set); set= Boolean.valueOf(memento.getString(TAG_HIDENONPUBLIC)).booleanValue(); setMemberFilter(MethodsViewerFilter.FILTER_NONPUBLIC, set); set= Boolean.valueOf(memento.getString(TAG_SHOWINHERITED)).booleanValue(); showInheritedMethods(set);
7,591
Bug 7591 Flicker when toggeling show inherited filter
When toggeling the show inherited filter in the type hierarchy you can watch the scrollbar grow. We should bracket this refresh with setRedraw(false/true) so that there is only a single refresh.
verified fixed
d21e057
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:29:53Z
2002-01-15T10:20:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/MethodsViewer.java
ScrollBar bar= getTable().getVerticalBar(); if (bar != null) { Integer vScroll= memento.getInteger(TAG_VERTICAL_SCROLL); if (vScroll != null) { bar.setSelection(vScroll.intValue()); } } } /** * Attaches a contextmenu listener to the table */ public void initContextMenu(IMenuListener menuListener, String popupId, IWorkbenchPartSite viewSite) { MenuManager menuMgr= new MenuManager(); menuMgr.setRemoveAllWhenShown(true); menuMgr.addMenuListener(menuListener); Menu menu= menuMgr.createContextMenu(getTable()); getTable().setMenu(menu); viewSite.registerContextMenu(popupId, menuMgr, this); } /** * Fills up the context menu with items for the method viewer * Should be called by the creator of the context menu */ public void contributeToContextMenu(IMenuManager menu) { if (fOpen.canActionBeAdded()) { menu.appendToGroup(IContextMenuConstants.GROUP_OPEN, fOpen); }
7,591
Bug 7591 Flicker when toggeling show inherited filter
When toggeling the show inherited filter in the type hierarchy you can watch the scrollbar grow. We should bracket this refresh with setRedraw(false/true) so that there is only a single refresh.
verified fixed
d21e057
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:29:53Z
2002-01-15T10:20:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/MethodsViewer.java
ContextMenuGroup.add(menu, fStandardGroups, this); } /** * Fills up the tool bar with items for the method viewer * Should be called by the creator of the tool bar */ public void contributeToToolBar(ToolBarManager tbm) { tbm.add(fShowInheritedMembersAction); tbm.add(new Separator()); tbm.add(fFilterActions[0]); tbm.add(fFilterActions[1]); tbm.add(fFilterActions[2]); } /* * @see StructuredViewer#handleInvalidSelection(ISelection, ISelection) */ protected void handleInvalidSelection(ISelection invalidSelection, ISelection newSelection) { List oldSelections= SelectionUtil.toList(invalidSelection); List newSelections= SelectionUtil.toList(newSelection); if (!oldSelections.isEmpty()) { ArrayList newSelectionElements= new ArrayList(newSelections); try { Object[] currElements= getFilteredChildren(getInput()); for (int i= 0; i < oldSelections.size(); i++) { Object curr= oldSelections.get(i); if (curr instanceof IMethod && !newSelections.contains(curr)) { IMethod method= (IMethod) curr; if (method.exists()) {
7,591
Bug 7591 Flicker when toggeling show inherited filter
When toggeling the show inherited filter in the type hierarchy you can watch the scrollbar grow. We should bracket this refresh with setRedraw(false/true) so that there is only a single refresh.
verified fixed
d21e057
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-15T15:29:53Z
2002-01-15T10:20:00Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/typehierarchy/MethodsViewer.java
IMethod similar= findSimilarMethod(method, currElements); if (similar != null) { newSelectionElements.add(similar); } } } } newSelection= new StructuredSelection(newSelectionElements); } catch (JavaModelException e) { JavaPlugin.log(e); } } setSelection(newSelection); updateSelection(newSelection); } private IMethod findSimilarMethod(IMethod meth, Object[] elements) throws JavaModelException { String name= meth.getElementName(); String[] paramTypes= meth.getParameterTypes(); boolean isConstructor= meth.isConstructor(); for (int i= 0; i < elements.length; i++) { Object curr= elements[i]; if (curr instanceof IMethod && JavaModelUtil.isSameMethodSignature(name, paramTypes, isConstructor, (IMethod) curr)) { return (IMethod) curr; } } return null; } }
7,023
Bug 7023 Refactoring too many builds when auto build is on
Refactoring saves compilation units for the precondition checking and this can trigger an autobuild. This autobuild should be supressed since you need to build again after the refactoring.
resolved fixed
01e6991
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T12:52:05Z
2001-12-18T10:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/reorg/RefactoringSupportFactory.java
/* * (c) Copyright IBM Corp. 2000, 2001. * All Rights Reserved. */ package org.eclipse.jdt.internal.ui.reorg; import org.eclipse.core.resources.IResource; import org.eclipse.core.runtime.NullProgressMonitor;
7,023
Bug 7023 Refactoring too many builds when auto build is on
Refactoring saves compilation units for the precondition checking and this can trigger an autobuild. This autobuild should be supressed since you need to build again after the refactoring.
resolved fixed
01e6991
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T12:52:05Z
2001-12-18T10:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/reorg/RefactoringSupportFactory.java
import org.eclipse.jface.resource.ImageDescriptor; import org.eclipse.jface.util.Assert; import org.eclipse.jdt.core.ICompilationUnit; import org.eclipse.jdt.core.IField; import org.eclipse.jdt.core.IJavaElement; import org.eclipse.jdt.core.IJavaProject; import org.eclipse.jdt.core.IMethod; import org.eclipse.jdt.core.IPackageFragment; import org.eclipse.jdt.core.IPackageFragmentRoot; import org.eclipse.jdt.core.IType; import org.eclipse.jdt.core.JavaModelException; import org.eclipse.jdt.internal.corext.refactoring.base.Refactoring; import org.eclipse.jdt.internal.corext.refactoring.rename.RenameCompilationUnitRefactoring; import org.eclipse.jdt.internal.corext.refactoring.rename.RenameFieldRefactoring; import org.eclipse.jdt.internal.corext.refactoring.rename.RenameJavaProjectRefactoring; import org.eclipse.jdt.internal.corext.refactoring.rename.RenameMethodRefactoring; import org.eclipse.jdt.internal.corext.refactoring.rename.RenamePackageRefactoring; import org.eclipse.jdt.internal.corext.refactoring.rename.RenameResourceRefactoring; import org.eclipse.jdt.internal.corext.refactoring.rename.RenameSourceFolderRefactoring; import org.eclipse.jdt.internal.corext.refactoring.rename.RenameTypeRefactoring; import org.eclipse.jdt.internal.corext.refactoring.tagging.IRenameRefactoring; import org.eclipse.jdt.internal.ui.IJavaHelpContextIds; import org.eclipse.jdt.internal.ui.JavaPluginImages; import org.eclipse.jdt.internal.ui.refactoring.RefactoringMessages; import org.eclipse.jdt.internal.ui.refactoring.RefactoringWizard; import org.eclipse.jdt.internal.ui.refactoring.RenameRefactoringWizard; import org.eclipse.jdt.internal.ui.refactoring.actions.RefactoringAction; public class RefactoringSupportFactory { private abstract static class RenameSupport implements IRefactoringRenameSupport { private IRenameRefactoring fRefactoring;
7,023
Bug 7023 Refactoring too many builds when auto build is on
Refactoring saves compilation units for the precondition checking and this can trigger an autobuild. This autobuild should be supressed since you need to build again after the refactoring.
resolved fixed
01e6991
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T12:52:05Z
2001-12-18T10:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/reorg/RefactoringSupportFactory.java
public boolean canRename(Object element) throws JavaModelException{ fRefactoring= createRefactoring(element); boolean canRename= canAddToMenu(fRefactoring); if (!canRename) fRefactoring= null; return canRename; } public void rename(Object element) throws JavaModelException{ Assert.isNotNull(fRefactoring); RefactoringWizard wizard= createWizard(fRefactoring); if (wizard != null) RefactoringAction.activateRefactoringWizard((Refactoring)fRefactoring, wizard, "Rename", true); else RefactoringAction.activateRenameRefactoringDialog(fRefactoring, "Rename", getNameEntryMessage(), false, element); fRefactoring= null; } abstract IRenameRefactoring createRefactoring(Object element) throws JavaModelException; RefactoringWizard createWizard(IRenameRefactoring ref){ return null; } abstract boolean canAddToMenu(IRenameRefactoring refactoring) throws JavaModelException; String getNameEntryMessage(){ return ""; } } private static RefactoringWizard createRenameWizard(IRenameRefactoring ref, String title, String message, String wizardPageHelp, String errorPageHelp, ImageDescriptor image){
7,023
Bug 7023 Refactoring too many builds when auto build is on
Refactoring saves compilation units for the precondition checking and this can trigger an autobuild. This autobuild should be supressed since you need to build again after the refactoring.
resolved fixed
01e6991
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T12:52:05Z
2001-12-18T10:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/reorg/RefactoringSupportFactory.java
RenameRefactoringWizard w= new RenameRefactoringWizard(ref, title, message, wizardPageHelp, errorPageHelp); w.setInputPageImageDescriptor(image); return w; } private static RenameSupport createJavaProjectRename(){ return new RenameSupport(){ IRenameRefactoring createRefactoring(Object element) { return new RenameJavaProjectRefactoring((IJavaProject)element); } public boolean canAddToMenu(IRenameRefactoring refactoring) throws JavaModelException{ return ((RenameJavaProjectRefactoring)refactoring).checkActivation(new NullProgressMonitor()).isOK(); } String getNameEntryMessage(){ return "Enter the new name for this Java project:"; } }; } private static RenameSupport createSourceFolderRename(){ return new RenameSupport(){ IRenameRefactoring createRefactoring(Object element) { return new RenameSourceFolderRefactoring((IPackageFragmentRoot)element); } public boolean canAddToMenu(IRenameRefactoring refactoring) throws JavaModelException{ return ((RenameSourceFolderRefactoring)refactoring).checkActivation(new NullProgressMonitor()).isOK(); } String getNameEntryMessage(){ return "Enter the new name for this source folder:"; }
7,023
Bug 7023 Refactoring too many builds when auto build is on
Refactoring saves compilation units for the precondition checking and this can trigger an autobuild. This autobuild should be supressed since you need to build again after the refactoring.
resolved fixed
01e6991
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T12:52:05Z
2001-12-18T10:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/reorg/RefactoringSupportFactory.java
}; } private static RenameSupport createResourceRename(){ return new RenameSupport(){ IRenameRefactoring createRefactoring(Object element) { return new RenameResourceRefactoring((IResource)element); } public boolean canAddToMenu(IRenameRefactoring refactoring) throws JavaModelException{ return ((RenameResourceRefactoring)refactoring).checkActivation(new NullProgressMonitor()).isOK(); } String getNameEntryMessage(){ return "Enter the new name for this resource:"; } }; } private static RenameSupport createPackageRename(){ return new RenameSupport(){ IRenameRefactoring createRefactoring(Object element) { return new RenamePackageRefactoring((IPackageFragment)element); } public boolean canAddToMenu(IRenameRefactoring refactoring) throws JavaModelException{ return ((RenamePackageRefactoring)refactoring).checkActivation(new NullProgressMonitor()).isOK(); } RefactoringWizard createWizard(IRenameRefactoring refactoring) { String title= "Rename Package"; String message= "Enter the new name for this package. References to all types declared in it will be updated."; String wizardPageHelp= IJavaHelpContextIds.RENAME_PACKAGE_WIZARD_PAGE; String errorPageHelp= IJavaHelpContextIds.RENAME_PACKAGE_ERROR_WIZARD_PAGE; ImageDescriptor imageDesc= JavaPluginImages.DESC_WIZBAN_REFACTOR_PACKAGE;
7,023
Bug 7023 Refactoring too many builds when auto build is on
Refactoring saves compilation units for the precondition checking and this can trigger an autobuild. This autobuild should be supressed since you need to build again after the refactoring.
resolved fixed
01e6991
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T12:52:05Z
2001-12-18T10:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/reorg/RefactoringSupportFactory.java
return createRenameWizard(refactoring, title, message, wizardPageHelp, errorPageHelp, imageDesc); } }; } private static RenameSupport createCompilationUnitRename(){ return new RenameSupport(){ IRenameRefactoring createRefactoring(Object element) { ICompilationUnit cu= (ICompilationUnit)element; if (cu.isWorkingCopy()) return new RenameCompilationUnitRefactoring((ICompilationUnit)cu.getOriginalElement()); return new RenameCompilationUnitRefactoring(cu); } public boolean canAddToMenu(IRenameRefactoring refactoring) throws JavaModelException{ return ((RenameCompilationUnitRefactoring)refactoring).checkPreactivation().isOK(); } RefactoringWizard createWizard(IRenameRefactoring refactoring) { String title= "Rename Compilation Unit"; String message= "Enter the new name for this compilation unit. Refactoring will also rename and update references to the type (if any exists) that has the same name as this compilation unit."; String wizardPageHelp= IJavaHelpContextIds.RENAME_CU_WIZARD_PAGE; String errorPageHelp= IJavaHelpContextIds.RENAME_CU_ERROR_WIZARD_PAGE; ImageDescriptor imageDesc= JavaPluginImages.DESC_WIZBAN_REFACTOR_CU; return createRenameWizard(refactoring, title, message, wizardPageHelp, errorPageHelp, imageDesc); } }; } private static RenameSupport createTypeRename(){ return new RenameSupport(){ IRenameRefactoring createRefactoring(Object element) {
7,023
Bug 7023 Refactoring too many builds when auto build is on
Refactoring saves compilation units for the precondition checking and this can trigger an autobuild. This autobuild should be supressed since you need to build again after the refactoring.
resolved fixed
01e6991
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T12:52:05Z
2001-12-18T10:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/reorg/RefactoringSupportFactory.java
return new RenameTypeRefactoring((IType)element); } public boolean canAddToMenu(IRenameRefactoring refactoring) throws JavaModelException{ return ((RenameTypeRefactoring)refactoring).checkPreactivation().isOK(); } RefactoringWizard createWizard(IRenameRefactoring refactoring) { String title= RefactoringMessages.getString("RefactoringGroup.rename_type_title"); String message= RefactoringMessages.getString("RefactoringGroup.rename_type_message"); String wizardPageHelp= IJavaHelpContextIds.RENAME_TYPE_WIZARD_PAGE; String errorPageHelp= IJavaHelpContextIds.RENAME_TYPE_ERROR_WIZARD_PAGE; ImageDescriptor imageDesc= JavaPluginImages.DESC_WIZBAN_REFACTOR_TYPE; return createRenameWizard(refactoring, title, message, wizardPageHelp, errorPageHelp, imageDesc); } }; } private static RenameSupport createMethodRename(){ return new RenameSupport(){ IRenameRefactoring createRefactoring(Object element) throws JavaModelException{ return RenameMethodRefactoring.createInstance((IMethod)element); } public boolean canAddToMenu(IRenameRefactoring refactoring) throws JavaModelException{ return ((RenameMethodRefactoring)refactoring).checkPreactivation().isOK(); } RefactoringWizard createWizard(IRenameRefactoring refactoring) { String title= RefactoringMessages.getString("RefactoringGroup.rename_method_title"); String message= RefactoringMessages.getString("RefactoringGroup.rename_method_message"); String wizardPageHelp= IJavaHelpContextIds.RENAME_METHOD_WIZARD_PAGE; String errorPageHelp= IJavaHelpContextIds.RENAME_METHOD_ERROR_WIZARD_PAGE; ImageDescriptor imageDesc= JavaPluginImages.DESC_WIZBAN_REFACTOR_METHOD;
7,023
Bug 7023 Refactoring too many builds when auto build is on
Refactoring saves compilation units for the precondition checking and this can trigger an autobuild. This autobuild should be supressed since you need to build again after the refactoring.
resolved fixed
01e6991
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T12:52:05Z
2001-12-18T10:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/reorg/RefactoringSupportFactory.java
return createRenameWizard(refactoring, title, message, wizardPageHelp, errorPageHelp, imageDesc); } }; } private static RenameSupport createFieldRename(){ return new RenameSupport(){ IRenameRefactoring createRefactoring(Object element) { return new RenameFieldRefactoring((IField)element); } public boolean canAddToMenu(IRenameRefactoring refactoring) throws JavaModelException{ return ((RenameFieldRefactoring)refactoring).checkPreactivation().isOK(); } RefactoringWizard createWizard(IRenameRefactoring refactoring){ String title= RefactoringMessages.getString("RefactoringGroup.rename_field_title"); String message= RefactoringMessages.getString("RefactoringGroup.rename_field_message"); String wizardPageHelp= IJavaHelpContextIds.RENAME_FIELD_WIZARD_PAGE; String errorPageHelp= IJavaHelpContextIds.RENAME_FIELD_ERROR_WIZARD_PAGE; ImageDescriptor imageDesc= JavaPluginImages.DESC_WIZBAN_REFACTOR_CU; return createRenameWizard(refactoring, title, message, wizardPageHelp, errorPageHelp, imageDesc); } }; } public static IRefactoringRenameSupport createRenameSupport(Object element) { if (element instanceof IResource) return createResourceRename(); if (!(element instanceof IJavaElement)) return null;
7,023
Bug 7023 Refactoring too many builds when auto build is on
Refactoring saves compilation units for the precondition checking and this can trigger an autobuild. This autobuild should be supressed since you need to build again after the refactoring.
resolved fixed
01e6991
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T12:52:05Z
2001-12-18T10:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/reorg/RefactoringSupportFactory.java
switch (((IJavaElement)element).getElementType()){ case IJavaElement.PACKAGE_FRAGMENT: return createPackageRename(); case IJavaElement.COMPILATION_UNIT: return createCompilationUnitRename(); case IJavaElement.PACKAGE_FRAGMENT_ROOT: return createSourceFolderRename(); case IJavaElement.JAVA_PROJECT: return createJavaProjectRename(); case IJavaElement.TYPE: return createTypeRename(); case IJavaElement.METHOD: return createMethodRename(); case IJavaElement.FIELD: return createFieldRename(); default: return null; } } }
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/JavaHierarchyPerspectiveFactory.java
/* * (c) Copyright IBM Corp. 2000, 2001. * All Rights Reserved. */ package org.eclipse.jdt.internal.ui; import org.eclipse.debug.ui.IDebugUIConstants; import org.eclipse.ui.IFolderLayout; import org.eclipse.ui.IPageLayout; import org.eclipse.ui.IPerspectiveFactory; import org.eclipse.search.ui.SearchUI; import org.eclipse.jdt.ui.JavaUI; public class JavaHierarchyPerspectiveFactory implements IPerspectiveFactory {
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/JavaHierarchyPerspectiveFactory.java
/** * Constructs a new Java hierarchy layout engine. */ public JavaHierarchyPerspectiveFactory() { super(); } public void createInitialLayout(IPageLayout layout) { String editorArea = layout.getEditorArea(); IFolderLayout folder= layout.createFolder("left", IPageLayout.LEFT, (float)0.25, editorArea); folder.addView(JavaUI.ID_TYPE_HIERARCHY); layout.addActionSet(IDebugUIConstants.DEBUG_ACTION_SET); layout.addActionSet(JavaUI.ID_ACTION_SET); layout.addShowViewShortcut(JavaUI.ID_PACKAGES); layout.addShowViewShortcut(JavaUI.ID_TYPE_HIERARCHY); layout.addShowViewShortcut(SearchUI.SEARCH_RESULT_VIEW_ID); layout.addShowViewShortcut(IDebugUIConstants.ID_PROCESS_VIEW); layout.addShowViewShortcut(IDebugUIConstants.ID_CONSOLE_VIEW); layout.addShowViewShortcut(IPageLayout.ID_OUTLINE); layout.addShowViewShortcut(IPageLayout.ID_TASK_LIST); layout.addShowViewShortcut(IPageLayout.ID_RES_NAV); } }
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/JavaPerspectiveFactory.java
/* * (c) Copyright IBM Corp. 2000, 2001. * All Rights Reserved. */ package org.eclipse.jdt.internal.ui; import org.eclipse.ui.IFolderLayout; import org.eclipse.ui.IPageLayout; import org.eclipse.ui.IPerspectiveFactory; import org.eclipse.search.ui.SearchUI; import org.eclipse.debug.ui.IDebugUIConstants; import org.eclipse.jdt.ui.JavaUI; public class JavaPerspectiveFactory implements IPerspectiveFactory {
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/JavaPerspectiveFactory.java
/** * Constructs a new Default layout engine. */ public JavaPerspectiveFactory() { super(); } public void createInitialLayout(IPageLayout layout) { String editorArea = layout.getEditorArea(); IFolderLayout folder= layout.createFolder("left", IPageLayout.LEFT, (float)0.25, editorArea); folder.addView(JavaUI.ID_PACKAGES); folder.addView(JavaUI.ID_TYPE_HIERARCHY); folder.addPlaceholder(IPageLayout.ID_RES_NAV); IFolderLayout outputfolder= layout.createFolder("bottom", IPageLayout.BOTTOM, (float)0.75, editorArea); outputfolder.addView(IPageLayout.ID_TASK_LIST); outputfolder.addView(SearchUI.SEARCH_RESULT_VIEW_ID); outputfolder.addView(IDebugUIConstants.ID_CONSOLE_VIEW);
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/JavaPerspectiveFactory.java
layout.addView(IPageLayout.ID_OUTLINE, IPageLayout.RIGHT, (float)0.75, editorArea); layout.addActionSet(IDebugUIConstants.LAUNCH_ACTION_SET); layout.addActionSet(JavaUI.ID_ACTION_SET); layout.addActionSet(IUIConstants.ID_REFACTORING_ACTION_SET); layout.addShowViewShortcut(JavaUI.ID_PACKAGES); layout.addShowViewShortcut(JavaUI.ID_TYPE_HIERARCHY); layout.addShowViewShortcut(SearchUI.SEARCH_RESULT_VIEW_ID); layout.addShowViewShortcut(IDebugUIConstants.ID_PROCESS_VIEW); layout.addShowViewShortcut(IDebugUIConstants.ID_CONSOLE_VIEW); layout.addShowViewShortcut(IPageLayout.ID_OUTLINE); layout.addShowViewShortcut(IPageLayout.ID_TASK_LIST); layout.addShowViewShortcut(IPageLayout.ID_RES_NAV); layout.addNewWizardShortcut("org.eclipse.jdt.ui.wizards.NewPackageCreationWizard"); layout.addNewWizardShortcut("org.eclipse.jdt.ui.wizards.NewClassCreationWizard"); layout.addNewWizardShortcut("org.eclipse.jdt.ui.wizards.NewInterfaceCreationWizard"); layout.addNewWizardShortcut("org.eclipse.jdt.ui.wizards.NewSourceFolderCreationWizard"); layout.addNewWizardShortcut("org.eclipse.jdt.ui.wizards.NewSnippetFileCreationWizard"); layout.addNewWizardShortcut("org.eclipse.ui.wizards.new.folder"); layout.addNewWizardShortcut("org.eclipse.ui.wizards.new.file"); } }
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/dnd/ResourceTransferDragAdapter.java
/* * (c) Copyright 2001 MyCorporation. * All Rights Reserved. */ package org.eclipse.jdt.internal.ui.dnd; import java.util.ArrayList; import java.util.Iterator; import java.util.List; import org.eclipse.swt.dnd.DND; import org.eclipse.swt.dnd.DragSourceAdapter; import org.eclipse.swt.dnd.DragSourceEvent; import org.eclipse.swt.dnd.Transfer; import org.eclipse.swt.widgets.Shell; import org.eclipse.jface.dialogs.ErrorDialog; import org.eclipse.jface.util.Assert; import org.eclipse.jface.viewers.ISelection; import org.eclipse.jface.viewers.ISelectionProvider; import org.eclipse.jface.viewers.IStructuredSelection; import org.eclipse.core.resources.IResource; import org.eclipse.core.runtime.CoreException; import org.eclipse.core.runtime.IAdaptable; import org.eclipse.core.runtime.IStatus;
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/dnd/ResourceTransferDragAdapter.java
import org.eclipse.core.runtime.MultiStatus; import org.eclipse.ui.part.ResourceTransfer; import org.eclipse.jdt.internal.ui.JavaPlugin; import org.eclipse.jdt.internal.ui.JavaStatusConstants; import org.eclipse.jdt.internal.ui.util.SWTUtil; /** * A drag adapter that transfers the current selection as </code> * IResource</code>. Only those elements in the selection are part * of the transfer which can be converted into an <code>IResource * </code>. */ public class ResourceTransferDragAdapter extends DragSourceAdapter implements TransferDragSourceListener { private ISelectionProvider fProvider; private static final List EMPTY_LIST= new ArrayList(0); /** * Creates a new ResourceTransferDragAdapter for the given selection * provider. * * @param provider the selection provider to access the viewer's selection */ public ResourceTransferDragAdapter(ISelectionProvider provider) { fProvider= provider; Assert.isNotNull(fProvider); } public Transfer getTransfer() { return ResourceTransfer.getInstance(); } public void dragStart(DragSourceEvent event) {
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/dnd/ResourceTransferDragAdapter.java
event.doit= convertSelection().size() > 0; } public void dragSetData(DragSourceEvent event) { List resources= convertSelection(); event.data= (IResource[]) resources.toArray(new IResource[resources.size()]); } public void dragFinished(DragSourceEvent event) { if (!event.doit) return; if (event.detail == DND.DROP_MOVE) { handleFinishedDropMove(event); } } private List convertSelection() { ISelection s= fProvider.getSelection(); if (!(s instanceof IStructuredSelection)) return EMPTY_LIST; IStructuredSelection selection= (IStructuredSelection)s; List result= new ArrayList(selection.size()); for (Iterator iter= selection.iterator(); iter.hasNext();) { Object element= iter.next(); if (element instanceof IAdaptable) { IAdaptable adaptable= (IAdaptable)element; IResource resource= (IResource)adaptable.getAdapter(IResource.class); if (resource != null) result.add(resource); }
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/dnd/ResourceTransferDragAdapter.java
} return result; } private void handleFinishedDropMove(DragSourceEvent event) { MultiStatus status= new MultiStatus( JavaPlugin.getPluginId(), JavaStatusConstants.INTERNAL_ERROR, "DND: cannot delete resources", null); List resources= convertSelection(); for (Iterator iter= resources.iterator(); iter.hasNext();) { IResource resource= (IResource) iter.next(); try { resource.delete(true, null); } catch (CoreException e) { status.add(e.getStatus()); } } if (status.getChildren().length > 0) { Shell parent= SWTUtil.getShell(event.widget); ErrorDialog error= new ErrorDialog(parent, "Moving Resources via DND", "Cannot delete the following file(s)", status, IStatus.ERROR); error.open(); } } }
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/viewsupport/ContainerCheckedTreeViewer.java
/* * (c) Copyright 2001 MyCorporation. * All Rights Reserved. */ package org.eclipse.jdt.internal.ui.viewsupport; import java.util.ArrayList; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Item; import org.eclipse.swt.widgets.Tree; import org.eclipse.swt.widgets.TreeItem; import org.eclipse.swt.widgets.Widget; import org.eclipse.jface.viewers.CheckStateChangedEvent; import org.eclipse.jface.viewers.CheckboxTreeViewer; import org.eclipse.jface.viewers.ICheckStateListener; import org.eclipse.jface.viewers.ITreeViewerListener; import org.eclipse.jface.viewers.TreeExpansionEvent; /** * CheckboxTreeViewer with special behaviour of the checked / gray state on * container (non-leaf) nodes: * The grayed state is used to visualize the checked state of its children. * Containers are checked and non-gary if all contained leafs are checked. The * container is grayed if some but not all leafs are checked. */ public class ContainerCheckedTreeViewer extends CheckboxTreeViewer {
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/viewsupport/ContainerCheckedTreeViewer.java
/** * Constructor for ContainerCheckedTreeViewer. * @see CheckboxTreeViewer#CheckboxTreeViewer(Composite) */ public ContainerCheckedTreeViewer(Composite parent) { super(parent); initViewer(); }
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/viewsupport/ContainerCheckedTreeViewer.java
/** * Constructor for ContainerCheckedTreeViewer. * @see CheckboxTreeViewer#CheckboxTreeViewer(Composite,int) */ public ContainerCheckedTreeViewer(Composite parent, int style) { super(parent, style); initViewer(); } /** * Constructor for ContainerCheckedTreeViewer. * @see CheckboxTreeViewer#CheckboxTreeViewer(Tree) */ public ContainerCheckedTreeViewer(Tree tree) { super(tree); initViewer(); } private void initViewer() { setUseHashlookup(true); addCheckStateListener(new ICheckStateListener() { public void checkStateChanged(CheckStateChangedEvent event) { doCheckStateChanged(event.getElement()); } }); addTreeListener(new ITreeViewerListener() { public void treeCollapsed(TreeExpansionEvent event) { } public void treeExpanded(TreeExpansionEvent event) { Widget item= findItem(event.getElement());
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/viewsupport/ContainerCheckedTreeViewer.java
if (item instanceof TreeItem) { initializeItem((TreeItem) item); } } }); } protected void doCheckStateChanged(Object element) { Widget item= findItem(element); if (item instanceof TreeItem) { TreeItem treeItem= (TreeItem) item; treeItem.setGrayed(false); updateChildrenItems(treeItem); updateParentItems(treeItem.getParentItem()); } } /** * The item has expanded. Updates the checked state of its children. */ private void initializeItem(TreeItem item) { if (item.getChecked() && !item.getGrayed()) { updateChildrenItems((TreeItem) item); } } /** * Updates the check state of all created children */ private void updateChildrenItems(TreeItem parent) { Item[] children= getChildren(parent);
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/viewsupport/ContainerCheckedTreeViewer.java
boolean state= parent.getChecked(); for (int i= 0; i < children.length; i++) { TreeItem curr= (TreeItem) children[i]; if (curr.getData() != null && ((curr.getChecked() != state) || curr.getGrayed())) { curr.setChecked(state); curr.setGrayed(false); updateChildrenItems(curr); } } } /** * Updates the check / gray state of all parent items */ private void updateParentItems(TreeItem item) { if (item != null) { Item[] children= getChildren(item); boolean containsChecked= false; boolean containsUnchecked= false; for (int i= 0; i < children.length; i++) { TreeItem curr= (TreeItem) children[i]; containsChecked |= curr.getChecked(); containsUnchecked |= (!curr.getChecked() || curr.getGrayed()); } item.setChecked(containsChecked); item.setGrayed(containsChecked && containsUnchecked); updateParentItems(item.getParentItem()); } } /*
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/viewsupport/ContainerCheckedTreeViewer.java
* @see ICheckable#setChecked(Object, boolean) */ public boolean setChecked(Object element, boolean state) { if (super.setChecked(element, state)) { doCheckStateChanged(element); return true; } return false; } /* * @see CheckboxTreeViewer#setCheckedElements(Object[]) */ public void setCheckedElements(Object[] elements) { super.setCheckedElements(elements); for (int i= 0; i < elements.length; i++) { doCheckStateChanged(elements[i]); } } /* * @see AbstractTreeViewer#setExpanded(Item, boolean) */ protected void setExpanded(Item item, boolean expand) { super.setExpanded(item, expand); if (expand && item instanceof TreeItem) { initializeItem((TreeItem) item); } } /* * @see CheckboxTreeViewer#getCheckedElements()
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/viewsupport/ContainerCheckedTreeViewer.java
*/ public Object[] getCheckedElements() { Object[] checked= super.getCheckedElements(); ArrayList result= new ArrayList(); for (int i= 0; i < checked.length; i++) { Object curr= checked[i]; result.add(curr); Widget item= findItem(curr); if (item != null) { Item[] children= getChildren(item); if (children.length == 1 && children[0].getData() == null) { collectChildren(curr, result); } } } return result.toArray(); } private void collectChildren(Object element, ArrayList result) { Object[] filteredChildren= getFilteredChildren(element); for (int i= 0; i < filteredChildren.length; i++) { Object curr= filteredChildren[i]; result.add(curr); collectChildren(curr, result); } } }
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
/* * (c) Copyright IBM Corp. 2000, 2001. * All Rights Reserved. */ package org.eclipse.jdt.ui; import java.util.ArrayList; import java.util.Arrays; import java.util.Iterator; import java.util.List; import java.util.Set; import org.eclipse.swt.widgets.Shell; import org.eclipse.core.resources.IProject; import org.eclipse.jface.operation.IRunnableContext; import org.eclipse.jface.util.Assert; import org.eclipse.ui.IEditorPart; import org.eclipse.ui.PartInitException; import org.eclipse.ui.dialogs.SelectionDialog; import org.eclipse.jdt.core.IJavaElement; import org.eclipse.jdt.core.IJavaProject;
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
import org.eclipse.jdt.core.IPackageFragmentRoot; import org.eclipse.jdt.core.ISourceReference; import org.eclipse.jdt.core.JavaCore; import org.eclipse.jdt.core.JavaModelException; import org.eclipse.jdt.core.search.IJavaSearchScope; import org.eclipse.jdt.core.search.SearchEngine; import org.eclipse.jdt.internal.corext.util.JavaModelUtil; import org.eclipse.jdt.internal.ui.JavaPlugin; import org.eclipse.jdt.internal.ui.SharedImages; import org.eclipse.jdt.internal.ui.dialogs.AbstractElementListSelectionDialog; import org.eclipse.jdt.internal.ui.dialogs.ElementListSelectionDialog; import org.eclipse.jdt.internal.ui.dialogs.MainTypeSelectionDialog; import org.eclipse.jdt.internal.ui.dialogs.MultiMainTypeSelectionDialog; import org.eclipse.jdt.internal.ui.dialogs.MultiTypeSelectionDialog; import org.eclipse.jdt.internal.ui.dialogs.TypeSelectionDialog; import org.eclipse.jdt.internal.ui.javaeditor.EditorUtility; /** * Central access point for the Java UI plug-in (id <code>"org.eclipse.jdt.ui"</code>). * This class provides static methods for: * <ul> * <li> creating various kinds of selection dialogs to present a collection * of Java elements to the user and let them make a selection.</li> * <li> opening a Java editor on a compilation unit.</li> * </ul> * <p> * This class provides static methods and fields only; it is not intended to be * instantiated or subclassed by clients. * </p> */ public final class JavaUI {
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
private static ISharedImages fgSharedImages= null; private JavaUI() { } /** * The id of the Java plugin (value <code>"org.eclipse.jdt.ui"</code>). */ public static final String ID_PLUGIN= "org.eclipse.jdt.ui"; /** * The id of the Java perspective * (value <code>"org.eclipse.jdt.ui.JavaPerspective"</code>). */ public static final String ID_PERSPECTIVE= "org.eclipse.jdt.ui.JavaPerspective"; /** * The id of the Java hierarchy perspective * (value <code>"org.eclipse.jdt.ui.JavaHierarchyPerspective"</code>). */ public static final String ID_HIERARCHYPERSPECTIVE= "org.eclipse.jdt.ui.JavaHierarchyPerspective"; /** * The id of the Java action set
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
* (value <code>"org.eclipse.jdt.ui.JavaActionSet"</code>). */ public static final String ID_ACTION_SET= "org.eclipse.jdt.ui.JavaActionSet"; /** * The editor part id of the editor that presents Java compilation units * (value <code>"org.eclipse.jdt.ui.CompilationUnitEditor"</code>). */ public static final String ID_CU_EDITOR= "org.eclipse.jdt.ui.CompilationUnitEditor"; /** * The editor part id of the editor that presents Java binary class files * (value <code>"org.eclipse.jdt.ui.ClassFileEditor"</code>). */ public static final String ID_CF_EDITOR= "org.eclipse.jdt.ui.ClassFileEditor"; /** * The editor part id of the code snippet editor * (value <code>"org.eclipse.jdt.ui.SnippetEditor"</code>). */ public static final String ID_SNIPPET_EDITOR= "org.eclipse.jdt.ui.SnippetEditor"; /** * The view part id of the Packages view * (value <code>"org.eclipse.jdt.ui.PackageExplorer"</code>). * <p> * When this id is used to access * a view part with <code>IWorkbenchPage.findView</code> or * <code>showView</code>, the returned <code>IViewPart</code> * can be safely cast to an <code>IPackagesViewPart</code>. * </p>
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
* * @see IPackagesViewPart * @see org.eclipse.ui.IWorkbenchPage#findView * @see org.eclipse.ui.IWorkbenchPage#showView */ public static final String ID_PACKAGES= "org.eclipse.jdt.ui.PackageExplorer"; /** * The view part id of the type hierarchy part. * (value <code>"org.eclipse.jdt.ui.TypeHierarchy"</code>). * <p> * When this id is used to access * a view part with <code>IWorkbenchPage.findView</code> or * <code>showView</code>, the returned <code>IViewPart</code> * can be safely cast to an <code>ITypeHierarchyViewPart</code>. * </p> * * @see ITypeHierarchyViewPart * @see org.eclipse.ui.IWorkbenchPage#findView * @see org.eclipse.ui.IWorkbenchPage#showView */ public static final String ID_TYPE_HIERARCHY= "org.eclipse.jdt.ui.TypeHierarchy"; /** * The class org.eclipse.debug.core.model.IProcess allows attaching * String properties to processes. The Java UI contributes a property * page for IProcess that will show the contents of the property * with this key. * The intent of this property is to show the command line a process * was launched with.
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
* @deprecated */ public final static String ATTR_CMDLINE= JavaPlugin.getPluginId()+".launcher.cmdLine"; /** * Returns the shared images for the Java UI. * * @return the shared images manager */ public static ISharedImages getSharedImages() { if (fgSharedImages == null) fgSharedImages= new SharedImages(); return fgSharedImages; } /** * Creates a selection dialog that lists all packages of the given Java project. * The caller is responsible for opening the dialog with <code>Window.open</code>, * and subsequently extracting the selected packages (of type * <code>IPackageFragment</code>) via <code>SelectionDialog.getResult</code>. * * @param parent the parent shell of the dialog to be created * @param project the Java project * @param style flags defining the style of the dialog; the valid flags are: * <code>IJavaElementSearchConstants.CONSIDER_BINARIES</code>, indicating that * packages from binary package fragment roots should be included in addition * to those from source package fragment roots; * <code>IJavaElementSearchConstants.CONSIDER_REQUIRED_PROJECTS</code>, indicating that * packages from required projects should be included as well. * @param filter the filter
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
* @return a new selection dialog * @exception JavaModelException if the selection dialog could not be opened */ public static SelectionDialog createPackageDialog(Shell parent, IJavaProject project, int style, String filter) throws JavaModelException { Assert.isTrue((style | IJavaElementSearchConstants.CONSIDER_BINARIES | IJavaElementSearchConstants.CONSIDER_REQUIRED_PROJECTS) == (IJavaElementSearchConstants.CONSIDER_BINARIES | IJavaElementSearchConstants.CONSIDER_REQUIRED_PROJECTS)); IPackageFragmentRoot[] roots= null; if ((style & IJavaElementSearchConstants.CONSIDER_REQUIRED_PROJECTS) != 0) { roots= project.getAllPackageFragmentRoots(); } else { roots= project.getPackageFragmentRoots(); } List consideredRoots= null; if ((style & IJavaElementSearchConstants.CONSIDER_BINARIES) != 0) { consideredRoots= Arrays.asList(roots); } else { consideredRoots= new ArrayList(roots.length); for (int i= 0; i < roots.length; i++) { IPackageFragmentRoot root= roots[i]; if (root.getKind() != IPackageFragmentRoot.K_BINARY) consideredRoots.add(root); } } int flags= JavaElementLabelProvider.SHOW_DEFAULT; if (consideredRoots.size() > 1) flags= flags | JavaElementLabelProvider.SHOW_ROOT; List packages= new ArrayList();
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
Iterator iter= consideredRoots.iterator(); while(iter.hasNext()) { IPackageFragmentRoot root= (IPackageFragmentRoot)iter.next(); packages.addAll(Arrays.asList(root.getChildren())); } ElementListSelectionDialog dialog= new ElementListSelectionDialog(parent, new JavaElementLabelProvider(flags)); dialog.setIgnoreCase(false); dialog.setElements(packages.toArray()); dialog.setFilter(filter); return dialog; } /** * @see createPackageDialog(Shell,IJavaProject,int,String) */ public static SelectionDialog createPackageDialog(Shell parent, IJavaProject project, int style) throws JavaModelException { return createPackageDialog(parent, project, style, "A"); } /** * Creates a selection dialog that lists all packages under the given package * fragment root. * The caller is responsible for opening the dialog with <code>Window.open</code>, * and subsequently extracting the selected packages (of type * <code>IPackageFragment</code>) via <code>SelectionDialog.getResult</code>. * * @param parent the parent shell of the dialog to be created * @param root the package fragment root * @param filter the filter * @return a new selection dialog * @exception JavaModelException if the selection dialog could not be opened
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
*/ public static SelectionDialog createPackageDialog(Shell parent, IPackageFragmentRoot root, String filter) throws JavaModelException { ElementListSelectionDialog dialog= new ElementListSelectionDialog(parent, new JavaElementLabelProvider(JavaElementLabelProvider.SHOW_DEFAULT)); dialog.setIgnoreCase(false); dialog.setElements(root.getChildren()); dialog.setFilter(filter); return dialog; } /** * @see createPackageDialog(Shell,IPackageFragmentRoot) */ public static SelectionDialog createPackageDialog(Shell parent, IPackageFragmentRoot root) throws JavaModelException { return createPackageDialog(parent, root, "A"); } /** * Creates a selection dialog that lists all types in the given scope. * The caller is responsible for opening the dialog with <code>Window.open</code>, * and subsequently extracting the selected packages (of type * <code>IType</code>) via <code>SelectionDialog.getResult</code>. * * @param parent the parent shell of the dialog to be created * @param context the runnable context used to show progress when the dialog * is being populated * @param scope the scope that limits which types are included * @param style flags defining the style of the dialog; the only valid values are * <code>IJavaElementSearchConstants.CONSIDER_CLASSES</code>, * <code>CONSIDER_INTERFACES</code>, or their bitwise OR * (equivalent to <code>CONSIDER_TYPES</code>) * @param multipleSelection <code>true</code> if multiple selection is allowed * @param filter the filter
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
* @return a new selection dialog * @exception JavaModelException if the selection dialog could not be opened */ public static SelectionDialog createTypeDialog(Shell parent, IRunnableContext context, IJavaSearchScope scope, int style, boolean multipleSelection, String filter) throws JavaModelException { Assert.isTrue((style | IJavaElementSearchConstants.CONSIDER_TYPES) == IJavaElementSearchConstants.CONSIDER_TYPES); if (multipleSelection) { MultiTypeSelectionDialog dialog= new MultiTypeSelectionDialog(parent, context, scope, style); dialog.setFilter(filter); return dialog; } else { TypeSelectionDialog dialog= new TypeSelectionDialog(parent, context, scope, style); dialog.setFilter(filter); return dialog; } } /** * @see createTypeDialog(Shell,IRunnableContext,IJavaSearchScope,int,boolean,String) */ public static SelectionDialog createTypeDialog(Shell parent, IRunnableContext context, IJavaSearchScope scope, int style, boolean multipleSelection) throws JavaModelException { return createTypeDialog(parent, context, scope, style, multipleSelection, "A"); } /** * Creates a selection dialog that lists all types in the given scope containing * a standard <code>main</code> method. * The caller is responsible for opening the dialog with <code>Window.open</code>, * and subsequently extracting the selected packages (of type * <code>IType</code>) via <code>SelectionDialog.getResult</code>. * <p> * [Issue: IJavaSearchScope is not currently part of the Java core API.]
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
* </p> * <p> * [Issue: SelectionDialogs must be parented. shell must not be null.] * </p> * * @param parent the parent shell of the dialog to be created * @param context the runnable context used to show progress when the dialog * is being populated * @param scope the scope that limits which types are included * @param style flags defining the style of the dialog; the only valid values are * <code>IJavaElementSearchConstants.CONSIDER_BINARIES</code>, * <code>CONSIDER_EXTERNAL_JARS</code>, or their bitwise OR, or <code>0</code> * @param multipleSelection <code>true</code> if multiple selection is allowed * @param filter the filter * @return a new selection dialog */ public static SelectionDialog createMainTypeDialog(Shell parent, IRunnableContext context, IJavaSearchScope scope, int style, boolean multipleSelection, String filter) { AbstractElementListSelectionDialog dialog= null; if (multipleSelection) { dialog= new MultiMainTypeSelectionDialog(parent, context, scope, style); } else { dialog= new MainTypeSelectionDialog(parent, context, scope, style); } dialog.setFilter(filter); return dialog; } /** * @see createMainTypeDialog(Shell,IRunnableContext,IJavaSearchScope,int,boolean,String) */ public static SelectionDialog createMainTypeDialog(Shell parent, IRunnableContext context, IJavaSearchScope scope, int style, boolean multipleSelection) {
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
return createMainTypeDialog(parent, context, scope, style, multipleSelection, "A"); } /** * Creates a selection dialog that lists all types in the given project. * The caller is responsible for opening the dialog with <code>Window.open</code>, * and subsequently extracting the selected packages (of type * <code>IType</code>) via <code>SelectionDialog.getResult</code>. * * @param parent the parent shell of the dialog to be created * @param context the runnable context used to show progress when the dialog * is being populated * @param project the Java project * @param style flags defining the style of the dialog; the only valid values are * <code>IJavaElementSearchConstants.CONSIDER_CLASSES</code>, * <code>CONSIDER_INTERFACES</code>, or their bitwise OR * (equivalent to <code>CONSIDER_TYPES</code>) * @param multipleSelection <code>true</code> if multiple selection is allowed * @return a new selection dialog * @exception JavaModelException if the selection dialog could not be opened */ public static SelectionDialog createTypeDialog(Shell parent, IRunnableContext context, IProject project, int style, boolean multipleSelection) throws JavaModelException { IJavaSearchScope scope= SearchEngine.createJavaSearchScope(new IJavaProject[] { JavaCore.create(project) }); return createTypeDialog(parent, context, scope, style, multipleSelection); } /** * Opens a Java editor on the given Java compilation unit of class file. * If there already is an open Java editor for the given element, it is returned. * <p>
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
* [Issue: Explain semantics of opening an editor on a class file.] * </p> * <p> * [Issue: Explain under which conditions it returns null, throws JavaModelException, * or throws JavaModelException. * ] * </p> * * @param element the input element; either a compilation unit * (<code>ICompilationUnit</code>) or a class file (</code>IClassFile</code>) * @return the editor, or </code>null</code> if wrong element type or opening failed * @exception PartInitException if the editor could not be initialized * @exception JavaModelException if this element does not exist or if an * exception occurs while accessing its underlying resource */ public static IEditorPart openInEditor(IJavaElement element) throws JavaModelException, PartInitException { return EditorUtility.openInEditor(element); } /** * Reveals the source range of the given source reference element in the * given editor. No checking is done if the editor displays a compilation unit or * class file that contains the given source reference. * <p> * [Issue: Explain what is meant by that last sentence.] * </p> * <p> * [Issue: Explain what happens if the source reference is from some other * compilation unit, editor is not open, etc.] * </p> *
7,127
Bug 7127 'refactor' menu missing from the type hierarchy perspective
the 'refactor' menu is missing from the type hierarchy perspective
resolved fixed
0c1b5e6
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T15:20:36Z
2001-12-20T12:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
* @param part the editor displaying the compilation unit or class file * @param element the source reference element defining the source range to be revealed * * @deprecated use <code>revealInEditor(IEditorPart, IJavaElement)</code> instead */ public static void revealInEditor(IEditorPart part, ISourceReference element) { if (element instanceof IJavaElement) revealInEditor(part, (IJavaElement) element); } /** * Reveals the given java element in the given editor. No checking is done if the * editor displays a compilation unit or class file that contains the given element. * If the element is not contained, nothing happens. * @param part the editor displaying a compilation unit or class file * @param element the element to be revealed */ public static void revealInEditor(IEditorPart part, IJavaElement element) { EditorUtility.revealInEditor(part, element); } /** * Returns the working copy manager for the Java UI plug-in. * * @return the working copy manager for the Java UI plug-in */ public static IWorkingCopyManager getWorkingCopyManager() { return JavaPlugin.getDefault().getWorkingCopyManager(); } }
3,963
Bug 3963 Clean up the [Issues] in javadoc (1GF9P7T)
Search for Issues in our plug-ins and clean up. This was found for JDT: org.eclipse.jdt.ui.wizards.NewJavaProjectWizardPage * [Issue: It is slightly unfortunate to make appeal to a preference in an API * method but not expose that preference as API. * ] public void setDefaultClassPath(IClasspathEntry[] entries, boolean appendDefaultJRE) { ==> There's a setter but no getter. This is a designed. Remove the Issue comment. org.eclipse.jdt.ui.JavaUI * [Issue: SelectionDialogs must be parented. shell must not be null.] * @param parent the parent shell of the dialog to be created public static SelectionDialog createMainTypeDialog(Shell parent, IRunnableContext cont... ==> This is a designed: we want to allow unparented dialogs. Remove the Issue comment. * [Issue: Explain semantics of opening an editor on a class file.] * </p> * <p> * [Issue: Explain under which conditions it returns null, throws JavaModelException, * or throws JavaModelException. * ] * </p> * @param element the input element; either a compilation unit * (<code>ICompilationUnit</code>) or a class file (</code>IClassFile</code>) * @return the editor, or </code>null</code> if wrong element type or opening failed * @exception PartInitException if the editor could not be initialized * @exception JavaModelException if this element does not exist or if an * exception occurs while accessing its underlying resource */ public static IEditorPart openInEditor(IJavaElement element) throws JavaModelException, PartInitException { ==> Better explanation would be good. * Reveals the source range of the given source reference element in the * given editor. No checking is done if the editor displays a compilation unit or * class file that contains the given source reference. * <p> * [Issue: Explain what is meant by that last sentence.] * </p> * <p> * [Issue: Explain what happens if the source reference is from some other * compilation unit, editor is not open, etc.] * </p> public static void revealInEditor(IEditorPart part, ISourceReference element) { ==> Better explanation would be good. PackageViewer // defensive code. Multithread issue? if (item.isDisposed()) ==> Would write: // guard for thread safety --- or --- remove the ? NOTES:
resolved fixed
c5b5154
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T16:42:37Z
2001-10-11T03:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
/* * (c) Copyright IBM Corp. 2000, 2001. * All Rights Reserved. */ package org.eclipse.jdt.ui; import java.util.ArrayList; import java.util.Arrays; import java.util.Iterator; import java.util.List; import java.util.Set; import org.eclipse.swt.widgets.Shell; import org.eclipse.core.resources.IProject; import org.eclipse.jface.operation.IRunnableContext; import org.eclipse.jface.util.Assert; import org.eclipse.ui.IEditorPart; import org.eclipse.ui.PartInitException; import org.eclipse.ui.dialogs.SelectionDialog; import org.eclipse.jdt.core.IJavaElement; import org.eclipse.jdt.core.IJavaProject;
3,963
Bug 3963 Clean up the [Issues] in javadoc (1GF9P7T)
Search for Issues in our plug-ins and clean up. This was found for JDT: org.eclipse.jdt.ui.wizards.NewJavaProjectWizardPage * [Issue: It is slightly unfortunate to make appeal to a preference in an API * method but not expose that preference as API. * ] public void setDefaultClassPath(IClasspathEntry[] entries, boolean appendDefaultJRE) { ==> There's a setter but no getter. This is a designed. Remove the Issue comment. org.eclipse.jdt.ui.JavaUI * [Issue: SelectionDialogs must be parented. shell must not be null.] * @param parent the parent shell of the dialog to be created public static SelectionDialog createMainTypeDialog(Shell parent, IRunnableContext cont... ==> This is a designed: we want to allow unparented dialogs. Remove the Issue comment. * [Issue: Explain semantics of opening an editor on a class file.] * </p> * <p> * [Issue: Explain under which conditions it returns null, throws JavaModelException, * or throws JavaModelException. * ] * </p> * @param element the input element; either a compilation unit * (<code>ICompilationUnit</code>) or a class file (</code>IClassFile</code>) * @return the editor, or </code>null</code> if wrong element type or opening failed * @exception PartInitException if the editor could not be initialized * @exception JavaModelException if this element does not exist or if an * exception occurs while accessing its underlying resource */ public static IEditorPart openInEditor(IJavaElement element) throws JavaModelException, PartInitException { ==> Better explanation would be good. * Reveals the source range of the given source reference element in the * given editor. No checking is done if the editor displays a compilation unit or * class file that contains the given source reference. * <p> * [Issue: Explain what is meant by that last sentence.] * </p> * <p> * [Issue: Explain what happens if the source reference is from some other * compilation unit, editor is not open, etc.] * </p> public static void revealInEditor(IEditorPart part, ISourceReference element) { ==> Better explanation would be good. PackageViewer // defensive code. Multithread issue? if (item.isDisposed()) ==> Would write: // guard for thread safety --- or --- remove the ? NOTES:
resolved fixed
c5b5154
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T16:42:37Z
2001-10-11T03:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
import org.eclipse.jdt.core.IPackageFragmentRoot; import org.eclipse.jdt.core.ISourceReference; import org.eclipse.jdt.core.JavaCore; import org.eclipse.jdt.core.JavaModelException; import org.eclipse.jdt.core.search.IJavaSearchScope; import org.eclipse.jdt.core.search.SearchEngine; import org.eclipse.jdt.internal.corext.util.JavaModelUtil; import org.eclipse.jdt.internal.ui.JavaPlugin; import org.eclipse.jdt.internal.ui.SharedImages; import org.eclipse.jdt.internal.ui.dialogs.AbstractElementListSelectionDialog; import org.eclipse.jdt.internal.ui.dialogs.ElementListSelectionDialog; import org.eclipse.jdt.internal.ui.dialogs.MainTypeSelectionDialog; import org.eclipse.jdt.internal.ui.dialogs.MultiMainTypeSelectionDialog; import org.eclipse.jdt.internal.ui.dialogs.MultiTypeSelectionDialog; import org.eclipse.jdt.internal.ui.dialogs.TypeSelectionDialog; import org.eclipse.jdt.internal.ui.javaeditor.EditorUtility; /** * Central access point for the Java UI plug-in (id <code>"org.eclipse.jdt.ui"</code>). * This class provides static methods for: * <ul> * <li> creating various kinds of selection dialogs to present a collection * of Java elements to the user and let them make a selection.</li> * <li> opening a Java editor on a compilation unit.</li> * </ul> * <p> * This class provides static methods and fields only; it is not intended to be * instantiated or subclassed by clients. * </p> */ public final class JavaUI {
3,963
Bug 3963 Clean up the [Issues] in javadoc (1GF9P7T)
Search for Issues in our plug-ins and clean up. This was found for JDT: org.eclipse.jdt.ui.wizards.NewJavaProjectWizardPage * [Issue: It is slightly unfortunate to make appeal to a preference in an API * method but not expose that preference as API. * ] public void setDefaultClassPath(IClasspathEntry[] entries, boolean appendDefaultJRE) { ==> There's a setter but no getter. This is a designed. Remove the Issue comment. org.eclipse.jdt.ui.JavaUI * [Issue: SelectionDialogs must be parented. shell must not be null.] * @param parent the parent shell of the dialog to be created public static SelectionDialog createMainTypeDialog(Shell parent, IRunnableContext cont... ==> This is a designed: we want to allow unparented dialogs. Remove the Issue comment. * [Issue: Explain semantics of opening an editor on a class file.] * </p> * <p> * [Issue: Explain under which conditions it returns null, throws JavaModelException, * or throws JavaModelException. * ] * </p> * @param element the input element; either a compilation unit * (<code>ICompilationUnit</code>) or a class file (</code>IClassFile</code>) * @return the editor, or </code>null</code> if wrong element type or opening failed * @exception PartInitException if the editor could not be initialized * @exception JavaModelException if this element does not exist or if an * exception occurs while accessing its underlying resource */ public static IEditorPart openInEditor(IJavaElement element) throws JavaModelException, PartInitException { ==> Better explanation would be good. * Reveals the source range of the given source reference element in the * given editor. No checking is done if the editor displays a compilation unit or * class file that contains the given source reference. * <p> * [Issue: Explain what is meant by that last sentence.] * </p> * <p> * [Issue: Explain what happens if the source reference is from some other * compilation unit, editor is not open, etc.] * </p> public static void revealInEditor(IEditorPart part, ISourceReference element) { ==> Better explanation would be good. PackageViewer // defensive code. Multithread issue? if (item.isDisposed()) ==> Would write: // guard for thread safety --- or --- remove the ? NOTES:
resolved fixed
c5b5154
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T16:42:37Z
2001-10-11T03:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
private static ISharedImages fgSharedImages= null; private JavaUI() { } /** * The id of the Java plugin (value <code>"org.eclipse.jdt.ui"</code>). */ public static final String ID_PLUGIN= "org.eclipse.jdt.ui"; /** * The id of the Java perspective * (value <code>"org.eclipse.jdt.ui.JavaPerspective"</code>). */ public static final String ID_PERSPECTIVE= "org.eclipse.jdt.ui.JavaPerspective"; /** * The id of the Java hierarchy perspective * (value <code>"org.eclipse.jdt.ui.JavaHierarchyPerspective"</code>). */ public static final String ID_HIERARCHYPERSPECTIVE= "org.eclipse.jdt.ui.JavaHierarchyPerspective"; /** * The id of the Java action set * (value <code>"org.eclipse.jdt.ui.JavaActionSet"</code>). */ public static final String ID_ACTION_SET= "org.eclipse.jdt.ui.JavaActionSet"; /**
3,963
Bug 3963 Clean up the [Issues] in javadoc (1GF9P7T)
Search for Issues in our plug-ins and clean up. This was found for JDT: org.eclipse.jdt.ui.wizards.NewJavaProjectWizardPage * [Issue: It is slightly unfortunate to make appeal to a preference in an API * method but not expose that preference as API. * ] public void setDefaultClassPath(IClasspathEntry[] entries, boolean appendDefaultJRE) { ==> There's a setter but no getter. This is a designed. Remove the Issue comment. org.eclipse.jdt.ui.JavaUI * [Issue: SelectionDialogs must be parented. shell must not be null.] * @param parent the parent shell of the dialog to be created public static SelectionDialog createMainTypeDialog(Shell parent, IRunnableContext cont... ==> This is a designed: we want to allow unparented dialogs. Remove the Issue comment. * [Issue: Explain semantics of opening an editor on a class file.] * </p> * <p> * [Issue: Explain under which conditions it returns null, throws JavaModelException, * or throws JavaModelException. * ] * </p> * @param element the input element; either a compilation unit * (<code>ICompilationUnit</code>) or a class file (</code>IClassFile</code>) * @return the editor, or </code>null</code> if wrong element type or opening failed * @exception PartInitException if the editor could not be initialized * @exception JavaModelException if this element does not exist or if an * exception occurs while accessing its underlying resource */ public static IEditorPart openInEditor(IJavaElement element) throws JavaModelException, PartInitException { ==> Better explanation would be good. * Reveals the source range of the given source reference element in the * given editor. No checking is done if the editor displays a compilation unit or * class file that contains the given source reference. * <p> * [Issue: Explain what is meant by that last sentence.] * </p> * <p> * [Issue: Explain what happens if the source reference is from some other * compilation unit, editor is not open, etc.] * </p> public static void revealInEditor(IEditorPart part, ISourceReference element) { ==> Better explanation would be good. PackageViewer // defensive code. Multithread issue? if (item.isDisposed()) ==> Would write: // guard for thread safety --- or --- remove the ? NOTES:
resolved fixed
c5b5154
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T16:42:37Z
2001-10-11T03:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
* The id of the Java Element Creation action set. */ public static final String ID_ELEMENT_CREATION_ACTION_SET= "org.eclipse.jdt.ui.JavaElementCreationActionSet"; /** * The editor part id of the editor that presents Java compilation units * (value <code>"org.eclipse.jdt.ui.CompilationUnitEditor"</code>). */ public static final String ID_CU_EDITOR= "org.eclipse.jdt.ui.CompilationUnitEditor"; /** * The editor part id of the editor that presents Java binary class files * (value <code>"org.eclipse.jdt.ui.ClassFileEditor"</code>). */ public static final String ID_CF_EDITOR= "org.eclipse.jdt.ui.ClassFileEditor"; /** * The editor part id of the code snippet editor * (value <code>"org.eclipse.jdt.ui.SnippetEditor"</code>). */ public static final String ID_SNIPPET_EDITOR= "org.eclipse.jdt.ui.SnippetEditor"; /** * The view part id of the Packages view * (value <code>"org.eclipse.jdt.ui.PackageExplorer"</code>). * <p> * When this id is used to access * a view part with <code>IWorkbenchPage.findView</code> or * <code>showView</code>, the returned <code>IViewPart</code> * can be safely cast to an <code>IPackagesViewPart</code>. * </p>
3,963
Bug 3963 Clean up the [Issues] in javadoc (1GF9P7T)
Search for Issues in our plug-ins and clean up. This was found for JDT: org.eclipse.jdt.ui.wizards.NewJavaProjectWizardPage * [Issue: It is slightly unfortunate to make appeal to a preference in an API * method but not expose that preference as API. * ] public void setDefaultClassPath(IClasspathEntry[] entries, boolean appendDefaultJRE) { ==> There's a setter but no getter. This is a designed. Remove the Issue comment. org.eclipse.jdt.ui.JavaUI * [Issue: SelectionDialogs must be parented. shell must not be null.] * @param parent the parent shell of the dialog to be created public static SelectionDialog createMainTypeDialog(Shell parent, IRunnableContext cont... ==> This is a designed: we want to allow unparented dialogs. Remove the Issue comment. * [Issue: Explain semantics of opening an editor on a class file.] * </p> * <p> * [Issue: Explain under which conditions it returns null, throws JavaModelException, * or throws JavaModelException. * ] * </p> * @param element the input element; either a compilation unit * (<code>ICompilationUnit</code>) or a class file (</code>IClassFile</code>) * @return the editor, or </code>null</code> if wrong element type or opening failed * @exception PartInitException if the editor could not be initialized * @exception JavaModelException if this element does not exist or if an * exception occurs while accessing its underlying resource */ public static IEditorPart openInEditor(IJavaElement element) throws JavaModelException, PartInitException { ==> Better explanation would be good. * Reveals the source range of the given source reference element in the * given editor. No checking is done if the editor displays a compilation unit or * class file that contains the given source reference. * <p> * [Issue: Explain what is meant by that last sentence.] * </p> * <p> * [Issue: Explain what happens if the source reference is from some other * compilation unit, editor is not open, etc.] * </p> public static void revealInEditor(IEditorPart part, ISourceReference element) { ==> Better explanation would be good. PackageViewer // defensive code. Multithread issue? if (item.isDisposed()) ==> Would write: // guard for thread safety --- or --- remove the ? NOTES:
resolved fixed
c5b5154
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T16:42:37Z
2001-10-11T03:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
* * @see IPackagesViewPart * @see org.eclipse.ui.IWorkbenchPage#findView * @see org.eclipse.ui.IWorkbenchPage#showView */ public static final String ID_PACKAGES= "org.eclipse.jdt.ui.PackageExplorer"; /** * The view part id of the type hierarchy part. * (value <code>"org.eclipse.jdt.ui.TypeHierarchy"</code>). * <p> * When this id is used to access * a view part with <code>IWorkbenchPage.findView</code> or * <code>showView</code>, the returned <code>IViewPart</code> * can be safely cast to an <code>ITypeHierarchyViewPart</code>. * </p> * * @see ITypeHierarchyViewPart * @see org.eclipse.ui.IWorkbenchPage#findView * @see org.eclipse.ui.IWorkbenchPage#showView */ public static final String ID_TYPE_HIERARCHY= "org.eclipse.jdt.ui.TypeHierarchy"; /** * The class org.eclipse.debug.core.model.IProcess allows attaching * String properties to processes. The Java UI contributes a property * page for IProcess that will show the contents of the property * with this key. * The intent of this property is to show the command line a process * was launched with.
3,963
Bug 3963 Clean up the [Issues] in javadoc (1GF9P7T)
Search for Issues in our plug-ins and clean up. This was found for JDT: org.eclipse.jdt.ui.wizards.NewJavaProjectWizardPage * [Issue: It is slightly unfortunate to make appeal to a preference in an API * method but not expose that preference as API. * ] public void setDefaultClassPath(IClasspathEntry[] entries, boolean appendDefaultJRE) { ==> There's a setter but no getter. This is a designed. Remove the Issue comment. org.eclipse.jdt.ui.JavaUI * [Issue: SelectionDialogs must be parented. shell must not be null.] * @param parent the parent shell of the dialog to be created public static SelectionDialog createMainTypeDialog(Shell parent, IRunnableContext cont... ==> This is a designed: we want to allow unparented dialogs. Remove the Issue comment. * [Issue: Explain semantics of opening an editor on a class file.] * </p> * <p> * [Issue: Explain under which conditions it returns null, throws JavaModelException, * or throws JavaModelException. * ] * </p> * @param element the input element; either a compilation unit * (<code>ICompilationUnit</code>) or a class file (</code>IClassFile</code>) * @return the editor, or </code>null</code> if wrong element type or opening failed * @exception PartInitException if the editor could not be initialized * @exception JavaModelException if this element does not exist or if an * exception occurs while accessing its underlying resource */ public static IEditorPart openInEditor(IJavaElement element) throws JavaModelException, PartInitException { ==> Better explanation would be good. * Reveals the source range of the given source reference element in the * given editor. No checking is done if the editor displays a compilation unit or * class file that contains the given source reference. * <p> * [Issue: Explain what is meant by that last sentence.] * </p> * <p> * [Issue: Explain what happens if the source reference is from some other * compilation unit, editor is not open, etc.] * </p> public static void revealInEditor(IEditorPart part, ISourceReference element) { ==> Better explanation would be good. PackageViewer // defensive code. Multithread issue? if (item.isDisposed()) ==> Would write: // guard for thread safety --- or --- remove the ? NOTES:
resolved fixed
c5b5154
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T16:42:37Z
2001-10-11T03:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
* @deprecated */ public final static String ATTR_CMDLINE= JavaPlugin.getPluginId()+".launcher.cmdLine"; /** * Returns the shared images for the Java UI. * * @return the shared images manager */ public static ISharedImages getSharedImages() { if (fgSharedImages == null) fgSharedImages= new SharedImages(); return fgSharedImages; } /** * Creates a selection dialog that lists all packages of the given Java project. * The caller is responsible for opening the dialog with <code>Window.open</code>, * and subsequently extracting the selected packages (of type * <code>IPackageFragment</code>) via <code>SelectionDialog.getResult</code>. * * @param parent the parent shell of the dialog to be created * @param project the Java project * @param style flags defining the style of the dialog; the valid flags are: * <code>IJavaElementSearchConstants.CONSIDER_BINARIES</code>, indicating that * packages from binary package fragment roots should be included in addition * to those from source package fragment roots; * <code>IJavaElementSearchConstants.CONSIDER_REQUIRED_PROJECTS</code>, indicating that * packages from required projects should be included as well. * @param filter the filter
3,963
Bug 3963 Clean up the [Issues] in javadoc (1GF9P7T)
Search for Issues in our plug-ins and clean up. This was found for JDT: org.eclipse.jdt.ui.wizards.NewJavaProjectWizardPage * [Issue: It is slightly unfortunate to make appeal to a preference in an API * method but not expose that preference as API. * ] public void setDefaultClassPath(IClasspathEntry[] entries, boolean appendDefaultJRE) { ==> There's a setter but no getter. This is a designed. Remove the Issue comment. org.eclipse.jdt.ui.JavaUI * [Issue: SelectionDialogs must be parented. shell must not be null.] * @param parent the parent shell of the dialog to be created public static SelectionDialog createMainTypeDialog(Shell parent, IRunnableContext cont... ==> This is a designed: we want to allow unparented dialogs. Remove the Issue comment. * [Issue: Explain semantics of opening an editor on a class file.] * </p> * <p> * [Issue: Explain under which conditions it returns null, throws JavaModelException, * or throws JavaModelException. * ] * </p> * @param element the input element; either a compilation unit * (<code>ICompilationUnit</code>) or a class file (</code>IClassFile</code>) * @return the editor, or </code>null</code> if wrong element type or opening failed * @exception PartInitException if the editor could not be initialized * @exception JavaModelException if this element does not exist or if an * exception occurs while accessing its underlying resource */ public static IEditorPart openInEditor(IJavaElement element) throws JavaModelException, PartInitException { ==> Better explanation would be good. * Reveals the source range of the given source reference element in the * given editor. No checking is done if the editor displays a compilation unit or * class file that contains the given source reference. * <p> * [Issue: Explain what is meant by that last sentence.] * </p> * <p> * [Issue: Explain what happens if the source reference is from some other * compilation unit, editor is not open, etc.] * </p> public static void revealInEditor(IEditorPart part, ISourceReference element) { ==> Better explanation would be good. PackageViewer // defensive code. Multithread issue? if (item.isDisposed()) ==> Would write: // guard for thread safety --- or --- remove the ? NOTES:
resolved fixed
c5b5154
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T16:42:37Z
2001-10-11T03:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
* @return a new selection dialog * @exception JavaModelException if the selection dialog could not be opened */ public static SelectionDialog createPackageDialog(Shell parent, IJavaProject project, int style, String filter) throws JavaModelException { Assert.isTrue((style | IJavaElementSearchConstants.CONSIDER_BINARIES | IJavaElementSearchConstants.CONSIDER_REQUIRED_PROJECTS) == (IJavaElementSearchConstants.CONSIDER_BINARIES | IJavaElementSearchConstants.CONSIDER_REQUIRED_PROJECTS)); IPackageFragmentRoot[] roots= null; if ((style & IJavaElementSearchConstants.CONSIDER_REQUIRED_PROJECTS) != 0) { roots= project.getAllPackageFragmentRoots(); } else { roots= project.getPackageFragmentRoots(); } List consideredRoots= null; if ((style & IJavaElementSearchConstants.CONSIDER_BINARIES) != 0) { consideredRoots= Arrays.asList(roots); } else { consideredRoots= new ArrayList(roots.length); for (int i= 0; i < roots.length; i++) { IPackageFragmentRoot root= roots[i]; if (root.getKind() != IPackageFragmentRoot.K_BINARY) consideredRoots.add(root); } } int flags= JavaElementLabelProvider.SHOW_DEFAULT; if (consideredRoots.size() > 1) flags= flags | JavaElementLabelProvider.SHOW_ROOT; List packages= new ArrayList();
3,963
Bug 3963 Clean up the [Issues] in javadoc (1GF9P7T)
Search for Issues in our plug-ins and clean up. This was found for JDT: org.eclipse.jdt.ui.wizards.NewJavaProjectWizardPage * [Issue: It is slightly unfortunate to make appeal to a preference in an API * method but not expose that preference as API. * ] public void setDefaultClassPath(IClasspathEntry[] entries, boolean appendDefaultJRE) { ==> There's a setter but no getter. This is a designed. Remove the Issue comment. org.eclipse.jdt.ui.JavaUI * [Issue: SelectionDialogs must be parented. shell must not be null.] * @param parent the parent shell of the dialog to be created public static SelectionDialog createMainTypeDialog(Shell parent, IRunnableContext cont... ==> This is a designed: we want to allow unparented dialogs. Remove the Issue comment. * [Issue: Explain semantics of opening an editor on a class file.] * </p> * <p> * [Issue: Explain under which conditions it returns null, throws JavaModelException, * or throws JavaModelException. * ] * </p> * @param element the input element; either a compilation unit * (<code>ICompilationUnit</code>) or a class file (</code>IClassFile</code>) * @return the editor, or </code>null</code> if wrong element type or opening failed * @exception PartInitException if the editor could not be initialized * @exception JavaModelException if this element does not exist or if an * exception occurs while accessing its underlying resource */ public static IEditorPart openInEditor(IJavaElement element) throws JavaModelException, PartInitException { ==> Better explanation would be good. * Reveals the source range of the given source reference element in the * given editor. No checking is done if the editor displays a compilation unit or * class file that contains the given source reference. * <p> * [Issue: Explain what is meant by that last sentence.] * </p> * <p> * [Issue: Explain what happens if the source reference is from some other * compilation unit, editor is not open, etc.] * </p> public static void revealInEditor(IEditorPart part, ISourceReference element) { ==> Better explanation would be good. PackageViewer // defensive code. Multithread issue? if (item.isDisposed()) ==> Would write: // guard for thread safety --- or --- remove the ? NOTES:
resolved fixed
c5b5154
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T16:42:37Z
2001-10-11T03:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
Iterator iter= consideredRoots.iterator(); while(iter.hasNext()) { IPackageFragmentRoot root= (IPackageFragmentRoot)iter.next(); packages.addAll(Arrays.asList(root.getChildren())); } ElementListSelectionDialog dialog= new ElementListSelectionDialog(parent, new JavaElementLabelProvider(flags)); dialog.setIgnoreCase(false); dialog.setElements(packages.toArray()); dialog.setFilter(filter); return dialog; } /** * @see createPackageDialog(Shell,IJavaProject,int,String) */ public static SelectionDialog createPackageDialog(Shell parent, IJavaProject project, int style) throws JavaModelException { return createPackageDialog(parent, project, style, "A"); } /** * Creates a selection dialog that lists all packages under the given package * fragment root. * The caller is responsible for opening the dialog with <code>Window.open</code>, * and subsequently extracting the selected packages (of type * <code>IPackageFragment</code>) via <code>SelectionDialog.getResult</code>. * * @param parent the parent shell of the dialog to be created * @param root the package fragment root * @param filter the filter * @return a new selection dialog * @exception JavaModelException if the selection dialog could not be opened
3,963
Bug 3963 Clean up the [Issues] in javadoc (1GF9P7T)
Search for Issues in our plug-ins and clean up. This was found for JDT: org.eclipse.jdt.ui.wizards.NewJavaProjectWizardPage * [Issue: It is slightly unfortunate to make appeal to a preference in an API * method but not expose that preference as API. * ] public void setDefaultClassPath(IClasspathEntry[] entries, boolean appendDefaultJRE) { ==> There's a setter but no getter. This is a designed. Remove the Issue comment. org.eclipse.jdt.ui.JavaUI * [Issue: SelectionDialogs must be parented. shell must not be null.] * @param parent the parent shell of the dialog to be created public static SelectionDialog createMainTypeDialog(Shell parent, IRunnableContext cont... ==> This is a designed: we want to allow unparented dialogs. Remove the Issue comment. * [Issue: Explain semantics of opening an editor on a class file.] * </p> * <p> * [Issue: Explain under which conditions it returns null, throws JavaModelException, * or throws JavaModelException. * ] * </p> * @param element the input element; either a compilation unit * (<code>ICompilationUnit</code>) or a class file (</code>IClassFile</code>) * @return the editor, or </code>null</code> if wrong element type or opening failed * @exception PartInitException if the editor could not be initialized * @exception JavaModelException if this element does not exist or if an * exception occurs while accessing its underlying resource */ public static IEditorPart openInEditor(IJavaElement element) throws JavaModelException, PartInitException { ==> Better explanation would be good. * Reveals the source range of the given source reference element in the * given editor. No checking is done if the editor displays a compilation unit or * class file that contains the given source reference. * <p> * [Issue: Explain what is meant by that last sentence.] * </p> * <p> * [Issue: Explain what happens if the source reference is from some other * compilation unit, editor is not open, etc.] * </p> public static void revealInEditor(IEditorPart part, ISourceReference element) { ==> Better explanation would be good. PackageViewer // defensive code. Multithread issue? if (item.isDisposed()) ==> Would write: // guard for thread safety --- or --- remove the ? NOTES:
resolved fixed
c5b5154
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T16:42:37Z
2001-10-11T03:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
*/ public static SelectionDialog createPackageDialog(Shell parent, IPackageFragmentRoot root, String filter) throws JavaModelException { ElementListSelectionDialog dialog= new ElementListSelectionDialog(parent, new JavaElementLabelProvider(JavaElementLabelProvider.SHOW_DEFAULT)); dialog.setIgnoreCase(false); dialog.setElements(root.getChildren()); dialog.setFilter(filter); return dialog; } /** * @see createPackageDialog(Shell,IPackageFragmentRoot) */ public static SelectionDialog createPackageDialog(Shell parent, IPackageFragmentRoot root) throws JavaModelException { return createPackageDialog(parent, root, "A"); } /** * Creates a selection dialog that lists all types in the given scope. * The caller is responsible for opening the dialog with <code>Window.open</code>, * and subsequently extracting the selected packages (of type * <code>IType</code>) via <code>SelectionDialog.getResult</code>. * * @param parent the parent shell of the dialog to be created * @param context the runnable context used to show progress when the dialog * is being populated * @param scope the scope that limits which types are included * @param style flags defining the style of the dialog; the only valid values are * <code>IJavaElementSearchConstants.CONSIDER_CLASSES</code>, * <code>CONSIDER_INTERFACES</code>, or their bitwise OR * (equivalent to <code>CONSIDER_TYPES</code>) * @param multipleSelection <code>true</code> if multiple selection is allowed * @param filter the filter
3,963
Bug 3963 Clean up the [Issues] in javadoc (1GF9P7T)
Search for Issues in our plug-ins and clean up. This was found for JDT: org.eclipse.jdt.ui.wizards.NewJavaProjectWizardPage * [Issue: It is slightly unfortunate to make appeal to a preference in an API * method but not expose that preference as API. * ] public void setDefaultClassPath(IClasspathEntry[] entries, boolean appendDefaultJRE) { ==> There's a setter but no getter. This is a designed. Remove the Issue comment. org.eclipse.jdt.ui.JavaUI * [Issue: SelectionDialogs must be parented. shell must not be null.] * @param parent the parent shell of the dialog to be created public static SelectionDialog createMainTypeDialog(Shell parent, IRunnableContext cont... ==> This is a designed: we want to allow unparented dialogs. Remove the Issue comment. * [Issue: Explain semantics of opening an editor on a class file.] * </p> * <p> * [Issue: Explain under which conditions it returns null, throws JavaModelException, * or throws JavaModelException. * ] * </p> * @param element the input element; either a compilation unit * (<code>ICompilationUnit</code>) or a class file (</code>IClassFile</code>) * @return the editor, or </code>null</code> if wrong element type or opening failed * @exception PartInitException if the editor could not be initialized * @exception JavaModelException if this element does not exist or if an * exception occurs while accessing its underlying resource */ public static IEditorPart openInEditor(IJavaElement element) throws JavaModelException, PartInitException { ==> Better explanation would be good. * Reveals the source range of the given source reference element in the * given editor. No checking is done if the editor displays a compilation unit or * class file that contains the given source reference. * <p> * [Issue: Explain what is meant by that last sentence.] * </p> * <p> * [Issue: Explain what happens if the source reference is from some other * compilation unit, editor is not open, etc.] * </p> public static void revealInEditor(IEditorPart part, ISourceReference element) { ==> Better explanation would be good. PackageViewer // defensive code. Multithread issue? if (item.isDisposed()) ==> Would write: // guard for thread safety --- or --- remove the ? NOTES:
resolved fixed
c5b5154
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T16:42:37Z
2001-10-11T03:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
* @return a new selection dialog * @exception JavaModelException if the selection dialog could not be opened */ public static SelectionDialog createTypeDialog(Shell parent, IRunnableContext context, IJavaSearchScope scope, int style, boolean multipleSelection, String filter) throws JavaModelException { Assert.isTrue((style | IJavaElementSearchConstants.CONSIDER_TYPES) == IJavaElementSearchConstants.CONSIDER_TYPES); if (multipleSelection) { MultiTypeSelectionDialog dialog= new MultiTypeSelectionDialog(parent, context, scope, style); dialog.setFilter(filter); return dialog; } else { TypeSelectionDialog dialog= new TypeSelectionDialog(parent, context, scope, style); dialog.setFilter(filter); return dialog; } } /** * @see createTypeDialog(Shell,IRunnableContext,IJavaSearchScope,int,boolean,String) */ public static SelectionDialog createTypeDialog(Shell parent, IRunnableContext context, IJavaSearchScope scope, int style, boolean multipleSelection) throws JavaModelException { return createTypeDialog(parent, context, scope, style, multipleSelection, "A"); } /** * Creates a selection dialog that lists all types in the given scope containing * a standard <code>main</code> method. * The caller is responsible for opening the dialog with <code>Window.open</code>, * and subsequently extracting the selected packages (of type * <code>IType</code>) via <code>SelectionDialog.getResult</code>. * <p> * [Issue: IJavaSearchScope is not currently part of the Java core API.]
3,963
Bug 3963 Clean up the [Issues] in javadoc (1GF9P7T)
Search for Issues in our plug-ins and clean up. This was found for JDT: org.eclipse.jdt.ui.wizards.NewJavaProjectWizardPage * [Issue: It is slightly unfortunate to make appeal to a preference in an API * method but not expose that preference as API. * ] public void setDefaultClassPath(IClasspathEntry[] entries, boolean appendDefaultJRE) { ==> There's a setter but no getter. This is a designed. Remove the Issue comment. org.eclipse.jdt.ui.JavaUI * [Issue: SelectionDialogs must be parented. shell must not be null.] * @param parent the parent shell of the dialog to be created public static SelectionDialog createMainTypeDialog(Shell parent, IRunnableContext cont... ==> This is a designed: we want to allow unparented dialogs. Remove the Issue comment. * [Issue: Explain semantics of opening an editor on a class file.] * </p> * <p> * [Issue: Explain under which conditions it returns null, throws JavaModelException, * or throws JavaModelException. * ] * </p> * @param element the input element; either a compilation unit * (<code>ICompilationUnit</code>) or a class file (</code>IClassFile</code>) * @return the editor, or </code>null</code> if wrong element type or opening failed * @exception PartInitException if the editor could not be initialized * @exception JavaModelException if this element does not exist or if an * exception occurs while accessing its underlying resource */ public static IEditorPart openInEditor(IJavaElement element) throws JavaModelException, PartInitException { ==> Better explanation would be good. * Reveals the source range of the given source reference element in the * given editor. No checking is done if the editor displays a compilation unit or * class file that contains the given source reference. * <p> * [Issue: Explain what is meant by that last sentence.] * </p> * <p> * [Issue: Explain what happens if the source reference is from some other * compilation unit, editor is not open, etc.] * </p> public static void revealInEditor(IEditorPart part, ISourceReference element) { ==> Better explanation would be good. PackageViewer // defensive code. Multithread issue? if (item.isDisposed()) ==> Would write: // guard for thread safety --- or --- remove the ? NOTES:
resolved fixed
c5b5154
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T16:42:37Z
2001-10-11T03:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
* </p> * <p> * [Issue: SelectionDialogs must be parented. shell must not be null.] * </p> * * @param parent the parent shell of the dialog to be created * @param context the runnable context used to show progress when the dialog * is being populated * @param scope the scope that limits which types are included * @param style flags defining the style of the dialog; the only valid values are * <code>IJavaElementSearchConstants.CONSIDER_BINARIES</code>, * <code>CONSIDER_EXTERNAL_JARS</code>, or their bitwise OR, or <code>0</code> * @param multipleSelection <code>true</code> if multiple selection is allowed * @param filter the filter * @return a new selection dialog */ public static SelectionDialog createMainTypeDialog(Shell parent, IRunnableContext context, IJavaSearchScope scope, int style, boolean multipleSelection, String filter) { AbstractElementListSelectionDialog dialog= null; if (multipleSelection) { dialog= new MultiMainTypeSelectionDialog(parent, context, scope, style); } else { dialog= new MainTypeSelectionDialog(parent, context, scope, style); } dialog.setFilter(filter); return dialog; } /** * @see createMainTypeDialog(Shell,IRunnableContext,IJavaSearchScope,int,boolean,String) */ public static SelectionDialog createMainTypeDialog(Shell parent, IRunnableContext context, IJavaSearchScope scope, int style, boolean multipleSelection) {
3,963
Bug 3963 Clean up the [Issues] in javadoc (1GF9P7T)
Search for Issues in our plug-ins and clean up. This was found for JDT: org.eclipse.jdt.ui.wizards.NewJavaProjectWizardPage * [Issue: It is slightly unfortunate to make appeal to a preference in an API * method but not expose that preference as API. * ] public void setDefaultClassPath(IClasspathEntry[] entries, boolean appendDefaultJRE) { ==> There's a setter but no getter. This is a designed. Remove the Issue comment. org.eclipse.jdt.ui.JavaUI * [Issue: SelectionDialogs must be parented. shell must not be null.] * @param parent the parent shell of the dialog to be created public static SelectionDialog createMainTypeDialog(Shell parent, IRunnableContext cont... ==> This is a designed: we want to allow unparented dialogs. Remove the Issue comment. * [Issue: Explain semantics of opening an editor on a class file.] * </p> * <p> * [Issue: Explain under which conditions it returns null, throws JavaModelException, * or throws JavaModelException. * ] * </p> * @param element the input element; either a compilation unit * (<code>ICompilationUnit</code>) or a class file (</code>IClassFile</code>) * @return the editor, or </code>null</code> if wrong element type or opening failed * @exception PartInitException if the editor could not be initialized * @exception JavaModelException if this element does not exist or if an * exception occurs while accessing its underlying resource */ public static IEditorPart openInEditor(IJavaElement element) throws JavaModelException, PartInitException { ==> Better explanation would be good. * Reveals the source range of the given source reference element in the * given editor. No checking is done if the editor displays a compilation unit or * class file that contains the given source reference. * <p> * [Issue: Explain what is meant by that last sentence.] * </p> * <p> * [Issue: Explain what happens if the source reference is from some other * compilation unit, editor is not open, etc.] * </p> public static void revealInEditor(IEditorPart part, ISourceReference element) { ==> Better explanation would be good. PackageViewer // defensive code. Multithread issue? if (item.isDisposed()) ==> Would write: // guard for thread safety --- or --- remove the ? NOTES:
resolved fixed
c5b5154
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T16:42:37Z
2001-10-11T03:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
return createMainTypeDialog(parent, context, scope, style, multipleSelection, "A"); } /** * Creates a selection dialog that lists all types in the given project. * The caller is responsible for opening the dialog with <code>Window.open</code>, * and subsequently extracting the selected packages (of type * <code>IType</code>) via <code>SelectionDialog.getResult</code>. * * @param parent the parent shell of the dialog to be created * @param context the runnable context used to show progress when the dialog * is being populated * @param project the Java project * @param style flags defining the style of the dialog; the only valid values are * <code>IJavaElementSearchConstants.CONSIDER_CLASSES</code>, * <code>CONSIDER_INTERFACES</code>, or their bitwise OR * (equivalent to <code>CONSIDER_TYPES</code>) * @param multipleSelection <code>true</code> if multiple selection is allowed * @return a new selection dialog * @exception JavaModelException if the selection dialog could not be opened */ public static SelectionDialog createTypeDialog(Shell parent, IRunnableContext context, IProject project, int style, boolean multipleSelection) throws JavaModelException { IJavaSearchScope scope= SearchEngine.createJavaSearchScope(new IJavaProject[] { JavaCore.create(project) }); return createTypeDialog(parent, context, scope, style, multipleSelection); } /** * Opens a Java editor on the given Java compilation unit of class file. * If there already is an open Java editor for the given element, it is returned. * <p>
3,963
Bug 3963 Clean up the [Issues] in javadoc (1GF9P7T)
Search for Issues in our plug-ins and clean up. This was found for JDT: org.eclipse.jdt.ui.wizards.NewJavaProjectWizardPage * [Issue: It is slightly unfortunate to make appeal to a preference in an API * method but not expose that preference as API. * ] public void setDefaultClassPath(IClasspathEntry[] entries, boolean appendDefaultJRE) { ==> There's a setter but no getter. This is a designed. Remove the Issue comment. org.eclipse.jdt.ui.JavaUI * [Issue: SelectionDialogs must be parented. shell must not be null.] * @param parent the parent shell of the dialog to be created public static SelectionDialog createMainTypeDialog(Shell parent, IRunnableContext cont... ==> This is a designed: we want to allow unparented dialogs. Remove the Issue comment. * [Issue: Explain semantics of opening an editor on a class file.] * </p> * <p> * [Issue: Explain under which conditions it returns null, throws JavaModelException, * or throws JavaModelException. * ] * </p> * @param element the input element; either a compilation unit * (<code>ICompilationUnit</code>) or a class file (</code>IClassFile</code>) * @return the editor, or </code>null</code> if wrong element type or opening failed * @exception PartInitException if the editor could not be initialized * @exception JavaModelException if this element does not exist or if an * exception occurs while accessing its underlying resource */ public static IEditorPart openInEditor(IJavaElement element) throws JavaModelException, PartInitException { ==> Better explanation would be good. * Reveals the source range of the given source reference element in the * given editor. No checking is done if the editor displays a compilation unit or * class file that contains the given source reference. * <p> * [Issue: Explain what is meant by that last sentence.] * </p> * <p> * [Issue: Explain what happens if the source reference is from some other * compilation unit, editor is not open, etc.] * </p> public static void revealInEditor(IEditorPart part, ISourceReference element) { ==> Better explanation would be good. PackageViewer // defensive code. Multithread issue? if (item.isDisposed()) ==> Would write: // guard for thread safety --- or --- remove the ? NOTES:
resolved fixed
c5b5154
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T16:42:37Z
2001-10-11T03:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
* [Issue: Explain semantics of opening an editor on a class file.] * </p> * <p> * [Issue: Explain under which conditions it returns null, throws JavaModelException, * or throws JavaModelException. * ] * </p> * * @param element the input element; either a compilation unit * (<code>ICompilationUnit</code>) or a class file (</code>IClassFile</code>) * @return the editor, or </code>null</code> if wrong element type or opening failed * @exception PartInitException if the editor could not be initialized * @exception JavaModelException if this element does not exist or if an * exception occurs while accessing its underlying resource */ public static IEditorPart openInEditor(IJavaElement element) throws JavaModelException, PartInitException { return EditorUtility.openInEditor(element); } /** * Reveals the source range of the given source reference element in the * given editor. No checking is done if the editor displays a compilation unit or * class file that contains the given source reference. * <p> * [Issue: Explain what is meant by that last sentence.] * </p> * <p> * [Issue: Explain what happens if the source reference is from some other * compilation unit, editor is not open, etc.] * </p> *
3,963
Bug 3963 Clean up the [Issues] in javadoc (1GF9P7T)
Search for Issues in our plug-ins and clean up. This was found for JDT: org.eclipse.jdt.ui.wizards.NewJavaProjectWizardPage * [Issue: It is slightly unfortunate to make appeal to a preference in an API * method but not expose that preference as API. * ] public void setDefaultClassPath(IClasspathEntry[] entries, boolean appendDefaultJRE) { ==> There's a setter but no getter. This is a designed. Remove the Issue comment. org.eclipse.jdt.ui.JavaUI * [Issue: SelectionDialogs must be parented. shell must not be null.] * @param parent the parent shell of the dialog to be created public static SelectionDialog createMainTypeDialog(Shell parent, IRunnableContext cont... ==> This is a designed: we want to allow unparented dialogs. Remove the Issue comment. * [Issue: Explain semantics of opening an editor on a class file.] * </p> * <p> * [Issue: Explain under which conditions it returns null, throws JavaModelException, * or throws JavaModelException. * ] * </p> * @param element the input element; either a compilation unit * (<code>ICompilationUnit</code>) or a class file (</code>IClassFile</code>) * @return the editor, or </code>null</code> if wrong element type or opening failed * @exception PartInitException if the editor could not be initialized * @exception JavaModelException if this element does not exist or if an * exception occurs while accessing its underlying resource */ public static IEditorPart openInEditor(IJavaElement element) throws JavaModelException, PartInitException { ==> Better explanation would be good. * Reveals the source range of the given source reference element in the * given editor. No checking is done if the editor displays a compilation unit or * class file that contains the given source reference. * <p> * [Issue: Explain what is meant by that last sentence.] * </p> * <p> * [Issue: Explain what happens if the source reference is from some other * compilation unit, editor is not open, etc.] * </p> public static void revealInEditor(IEditorPart part, ISourceReference element) { ==> Better explanation would be good. PackageViewer // defensive code. Multithread issue? if (item.isDisposed()) ==> Would write: // guard for thread safety --- or --- remove the ? NOTES:
resolved fixed
c5b5154
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T16:42:37Z
2001-10-11T03:13:20Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaUI.java
* @param part the editor displaying the compilation unit or class file * @param element the source reference element defining the source range to be revealed * * @deprecated use <code>revealInEditor(IEditorPart, IJavaElement)</code> instead */ public static void revealInEditor(IEditorPart part, ISourceReference element) { if (element instanceof IJavaElement) revealInEditor(part, (IJavaElement) element); } /** * Reveals the given java element in the given editor. No checking is done if the * editor displays a compilation unit or class file that contains the given element. * If the element is not contained, nothing happens. * @param part the editor displaying a compilation unit or class file * @param element the element to be revealed */ public static void revealInEditor(IEditorPart part, IJavaElement element) { EditorUtility.revealInEditor(part, element); } /** * Returns the working copy manager for the Java UI plug-in. * * @return the working copy manager for the Java UI plug-in */ public static IWorkingCopyManager getWorkingCopyManager() { return JavaPlugin.getDefault().getWorkingCopyManager(); } }
7,469
Bug 7469 Preferences -> Java -> Templates
The template body editor window at the bottom part of a Templates preferences page should contain both vertical and horizontal scroll bars.
resolved fixed
b728519
JDT
https://github.com/eclipse-jdt/eclipse.jdt.ui
eclipse-jdt/eclipse.jdt.ui
java
null
null
null
2002-01-16T17:13:56Z
2002-01-11T09:06:40Z
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/TemplatePreferencePage.java
package org.eclipse.jdt.internal.ui.preferences; import java.io.File; import java.util.ArrayList; import java.util.Iterator; import java.util.List; import org.eclipse.swt.SWT; import org.eclipse.swt.graphics.Font; import org.eclipse.swt.layout.GridData; import org.eclipse.swt.layout.GridLayout; import org.eclipse.swt.widgets.Button; import org.eclipse.swt.widgets.Composite; import org.eclipse.swt.widgets.Control; import org.eclipse.swt.widgets.Event; import org.eclipse.swt.widgets.FileDialog; import org.eclipse.swt.widgets.Label; import org.eclipse.swt.widgets.Listener; import org.eclipse.swt.widgets.Table; import org.eclipse.swt.widgets.TableColumn; import org.eclipse.core.runtime.CoreException; import org.eclipse.jface.dialogs.ErrorDialog; import org.eclipse.jface.preference.IPreferenceStore; import org.eclipse.jface.preference.PreferencePage; import org.eclipse.jface.resource.JFaceResources; import org.eclipse.jface.text.Document; import org.eclipse.jface.text.source.SourceViewer; import org.eclipse.jface.viewers.CheckStateChangedEvent;