@Override public ShowInContext getShowInContext() { return new ShowInContext(null, fSelectionProviderMediator.getSelection()); } };
@Override public ShowInContext getShowInContext() { return new ShowInContext(null, fSelectionProviderMediator.getSelection()); } };
@Override public <T> T getAdapter(Class<T> adapterType) { if (adapterType == IShowInSource.class) { return adapterType.cast((IShowInSource) () -> new ShowInContext(null, getSelection())); } if (adapterType == IShowInTargetList.class) { return adapterType.cast((IShowInTargetList) () -> new String[] { IPageLayout.ID_RES_NAV }); } return super.getAdapter(adapterType); }
@Override public <T> T getAdapter(Class<T> adapterClass) { if (adapterClass == IShowInSource.class) { return adapterClass.cast((IShowInSource) () -> new ShowInContext(null, getViewer().getSelection())); } if (adapterClass == IShowInTargetList.class) { return adapterClass.cast((IShowInTargetList) () -> new String[] { IPageLayout.ID_RES_NAV }); } return super.getAdapter(adapterClass); }
@Override public ShowInContext getShowInContext() { ISelection selection= null; ISelectionProvider selectionProvider= getSelectionProvider(); if (selectionProvider != null) selection= selectionProvider.getSelection(); return new ShowInContext(getEditorInput(), selection); } };
@Override public ShowInContext getShowInContext() { return new ShowInContext( null, getSite().getSelectionProvider().getSelection()); } };
@Override public void selectionChanged(SelectionChangedEvent event) { super.selectionChanged(event); showInTarget.show(new ShowInContext(null, event.getSelection())); }
@Override public ShowInContext getShowInContext() { return new ShowInContext( null, getSite().getSelectionProvider().getSelection()); } };
public ShowInContext getShowInContext() { return new ShowInContext( null, getSite().getSelectionProvider().getSelection()); } };
public ShowInContext getShowInContext() { try { IType type = JavaDebugUtils.resolveDeclaringType(fFrame); if (type != null) { return new ShowInContext(null, new StructuredSelection(type)); } } catch (CoreException e) { } return null; }
@Override public ShowInContext getShowInContext() { return new ShowInContext( null, getSite().getSelectionProvider().getSelection()); } };
@Override public ShowInContext getShowInContext() { AntElementNode node = getSelectionNode(); if (node != null) { IFile buildFile = node.getIFile(); if (buildFile != null) { ISelection selection = new StructuredSelection(buildFile); return new ShowInContext(null, selection); } } return null; }
@Override public ShowInContext getShowInContext() { return new ShowInContext( null, getSite().getSelectionProvider().getSelection()); } };
@Override public ShowInContext getShowInContext() { return new ShowInContext( getTreeViewer().getInput(), getTreeViewer().getSelection()); } };
@Override public ShowInContext getShowInContext() { return new ShowInContext( getTreeViewer().getInput(), getTreeViewer().getSelection()); } };
public ShowInContext getShowInContext() { return new ShowInContext( getTreeViewer().getInput(), getTreeViewer().getSelection()); } };
public Object execute(ExecutionEvent event) throws ExecutionException { RepositoriesView view; try { view = (RepositoriesView) PlatformUI.getWorkbench() .getActiveWorkbenchWindow().getActivePage().showView( RepositoriesView.VIEW_ID); ShowInContext ctx = new ShowInContext(ResourcesPlugin.getWorkspace().getRoot(), getSelection(event)); view.show(ctx); } catch (PartInitException e) { throw new ExecutionException(e.getMessage(), e); } return null; }
public ShowInContext getShowInContext() { StructuredViewer v = (StructuredViewer)changesViewer; if (v == null) return null; ISelection s = v.getSelection(); if (s instanceof IStructuredSelection) { Object[] resources = Utils.getResources(((IStructuredSelection)s).toArray()); return new ShowInContext(null, new StructuredSelection(resources)); } return null; } };
public ShowInContext getShowInContext() { OutlineItem item = getNearestMatchingOutlineItem(); return new ShowInContext(getEditorInput(), item == null ? new StructuredSelection() : new StructuredSelection( item)); }
public ShowInContext getShowInContext() { IStructuredSelection selection = (IStructuredSelection) getCommonViewer() .getSelection(); List<Object> elements = getShowInElements(selection); // GenericHistoryView only shows a selection of a single resource (see // bug 392949), so prepare our own history page input which can contain // multiple files to support showing more than one file in history. // It's also necessary for a single file that is outside of the // workspace (and as such is not an IResource). HistoryPageInput historyPageInput = getHistoryPageInput(selection); return new ShowInContext(historyPageInput, new StructuredSelection(elements)); }