private void setInput(Object input) { if (fStructurePane != null) { fStructurePane.setInput(input); ((Splitter)fControl).layout(); } }
/** * Feeds input from the page into the content and structured viewers. * @param input the input */ private void setInput(Object input) { CompareViewerPane pane = fContentPane; if (pane != null && !pane.isDisposed()) fContentPane.setInput(input); if (fStructuredComparePane != null && !fStructuredComparePane.isDisposed()) fStructuredComparePane.setInput(input); }
private void setInput(Object input) { if (!fCompare && input instanceof ICompareInput) { ICompareInput ci= (ICompareInput) input; if (fTargetIsRight) input= ci.getLeft(); else input= ci.getRight(); } fContentPane.setInput(input); if (fStructuredComparePane != null) fStructuredComparePane.setInput(input); }
private void setInput(Object input) { if (fStructurePane != null) { fStructurePane.setInput(input); ((Splitter)fControl).layout(); } }
private void setInput(Object input) { if (!fCompare && input instanceof ICompareInput) { ICompareInput ci= (ICompareInput) input; if (fTargetIsRight) input= ci.getLeft(); else input= ci.getRight(); } fContentPane.setInput(input); if (fStructuredComparePane != null) fStructuredComparePane.setInput(input); }
/** * Feeds input from the page into the content and structured viewers. * @param input the input */ private void setInput(Object input) { CompareViewerPane pane = fContentPane; if (pane != null && !pane.isDisposed()) fContentPane.setInput(input); if (fStructuredComparePane != null && !fStructuredComparePane.isDisposed()) fStructuredComparePane.setInput(input); }
/* package */ void internalCompareAsText(Object input) { Set set = (Set)getCompareConfiguration().getProperty(ICompareAsText.PROP_TEXT_INPUTS); if (set == null) { set = new HashSet(); getCompareConfiguration().setProperty(ICompareAsText.PROP_TEXT_INPUTS, set); } set.add(input); if (fContentInputPane.getInput().equals(input)) { // We need to null the input and then reset it so we get the text merge viewer fContentInputPane.setInput(null); fContentInputPane.setInput(input); } }
private void internalSetContentPaneInput(Object input) { Object oldInput = fContentInputPane.getInput(); fContentInputPane.setInput(input); if (fOutlineView != null) fOutlineView.fireInputChange(oldInput, input); }
private void feedInput2(ISelection sel) { if (sel instanceof IStructuredSelection) { IStructuredSelection ss= (IStructuredSelection) sel; if (ss.size() == 1) fContentPane.setInput(ss.getFirstElement()); } } }
private void internalSetContentPaneInput(Object input) { Object oldInput = fContentInputPane.getInput(); fContentInputPane.setInput(input); if (fOutlineView != null) fOutlineView.fireInputChange(oldInput, input); }
private void feedInput2(ISelection sel) { ICompareInput input = getCompareInput(sel); prepareCompareInput(input); if (input != null) fContentPane.setInput(input); }
@Override public void propertyChange(PropertyChangeEvent event) { if (event.getProperty().equals(OutlineViewerCreator.PROP_INPUT)) { fStructurePane.setInput(event.getNewValue()); ((Splitter)fControl).layout(); } }
@Override protected synchronized Control createDialogArea(Composite parent2) { Composite parent= (Composite) super.createDialogArea(parent2); getShell().setText(JavaCompareUtilities.getString(fBundle, "title")); //$NON-NLS-1$ fContentPane= new ViewerSwitchingPane(parent, SWT.BORDER | SWT.FLAT); fContentPane.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_FILL | GridData.GRAB_HORIZONTAL | GridData.VERTICAL_ALIGN_FILL | GridData.GRAB_VERTICAL)); if (fInput != null) fContentPane.setInput(fInput); applyDialogFont(parent); return parent; }
protected synchronized Control createDialogArea(Composite parent2) { Composite parent= (Composite) super.createDialogArea(parent2); getShell().setText(JavaCompareUtilities.getString(fBundle, "title")); //$NON-NLS-1$ fContentPane= new ViewerSwitchingPane(parent, SWT.BORDER | SWT.FLAT); fContentPane.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_FILL | GridData.GRAB_HORIZONTAL | GridData.VERTICAL_ALIGN_FILL | GridData.GRAB_VERTICAL)); if (fInput != null) fContentPane.setInput(fInput); applyDialogFont(parent); return parent; }
@Override protected synchronized Control createDialogArea(Composite parent2) { Composite parent= (Composite) super.createDialogArea(parent2); getShell().setText(JavaCompareUtilities.getString(fBundle, "title")); //$NON-NLS-1$ fContentPane= new ViewerSwitchingPane(parent, SWT.BORDER | SWT.FLAT); fContentPane.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_FILL | GridData.GRAB_HORIZONTAL | GridData.VERTICAL_ALIGN_FILL | GridData.GRAB_VERTICAL)); if (fInput != null) fContentPane.setInput(fInput); applyDialogFont(parent); return parent; }
private void feedDefault1(final ISelection selection) { BusyIndicator.showWhile(fComposite.getDisplay(), () -> { if (!selection.isEmpty()) fStructurePane1.setInput(getElement(selection)); } ); }
@Override public void setInput(Object input) { super.setInput(input); if (getViewer() == null || !Utilities.okToUse(getViewer().getControl())) return; ViewerDescriptor[] vd = null; if (getInput() instanceof ICompareInput) { vd = CompareUIPlugin.getDefault().findStructureViewerDescriptor( getViewer(), (ICompareInput) getInput(), getCompareConfiguration()); } toolBar.setVisible(vd != null && vd.length > 1); }
void compare(ICompareInput input) { fInput= input; fCompareConfiguration.setLeftLabel(fInput.getLeft().getName()); fCompareConfiguration.setLeftImage(fInput.getLeft().getImage()); fCompareConfiguration.setRightLabel(fInput.getRight().getName()); fCompareConfiguration.setRightImage(fInput.getRight().getImage()); if (fContentPane != null) fContentPane.setInput(fInput); open(); }
void compare(ICompareInput input) { fInput= input; fCompareConfiguration.setLeftLabel(fInput.getLeft().getName()); fCompareConfiguration.setLeftImage(fInput.getLeft().getImage()); fCompareConfiguration.setRightLabel(fInput.getRight().getName()); fCompareConfiguration.setRightImage(fInput.getRight().getImage()); if (fContentPane != null) fContentPane.setInput(fInput); open(); }
void compare(ICompareInput input) { fInput= input; fCompareConfiguration.setLeftLabel(fInput.getLeft().getName()); fCompareConfiguration.setLeftImage(fInput.getLeft().getImage()); fCompareConfiguration.setRightLabel(fInput.getRight().getName()); fCompareConfiguration.setRightImage(fInput.getRight().getImage()); if (fContentPane != null) fContentPane.setInput(fInput); open(); }