org.eclipse.jdt.internal.ui.wizards.dialogfields.DialogField Java Examples
The following examples show how to use
org.eclipse.jdt.internal.ui.wizards.dialogfields.DialogField.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: HistoryListAction.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 6 votes |
private void createMaxEntriesField() { fMaxEntriesField= new StringDialogField(); fMaxEntriesField.setLabelText(fHistory.getMaxEntriesMessage()); fMaxEntriesField.setDialogFieldListener(new IDialogFieldListener() { public void dialogFieldChanged(DialogField field) { String maxString= fMaxEntriesField.getText(); boolean valid; try { fMaxEntries= Integer.parseInt(maxString); valid= fMaxEntries > 0 && fMaxEntries < MAX_MAX_ENTRIES; } catch (NumberFormatException e) { valid= false; } if (valid) updateStatus(StatusInfo.OK_STATUS); else updateStatus(new StatusInfo(IStatus.ERROR, Messages.format(JavaUIMessages.HistoryListAction_max_entries_constraint, Integer.toString(MAX_MAX_ENTRIES)))); } }); fMaxEntriesField.setText(Integer.toString(fHistory.getMaxEntries())); }
Example #2
Source File: JavaMethodFilterInputDialog.java From jdt-codemining with Eclipse Public License 1.0 | 6 votes |
@Override protected Control createDialogArea(Composite parent) { Composite composite= (Composite) super.createDialogArea(parent); Composite inner= new Composite(composite, SWT.NONE); LayoutUtil.doDefaultLayout(inner, new DialogField[] { fNameDialogField }, true, 0, 0); int fieldWidthHint= convertWidthInCharsToPixels(60); Text text= fNameDialogField.getTextControl(null); LayoutUtil.setWidthHint(text, fieldWidthHint); LayoutUtil.setHorizontalGrabbing(text); //BidiUtils.applyBidiProcessing(text, StructuredTextTypeHandlerFactory.JAVA); TextFieldNavigationHandler.install(text); fNameDialogField.postSetFocusOnDialogField(parent.getDisplay()); applyDialogFont(composite); return composite; }
Example #3
Source File: AddSourceFolderWizardPage.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 6 votes |
public void changeControlPressed(DialogField field) { final DirectoryDialog dialog= new DirectoryDialog(getShell()); dialog.setMessage(NewWizardMessages.AddSourceFolderWizardPage_directory_message); String directoryName = fLinkLocation.getText().trim(); if (directoryName.length() == 0) { String prevLocation= JavaPlugin.getDefault().getDialogSettings().get(DIALOGSTORE_LAST_EXTERNAL_LOC); if (prevLocation != null) { directoryName= prevLocation; } } if (directoryName.length() > 0) { final File path = new File(directoryName); if (path.exists()) dialog.setFilterPath(directoryName); } final String selectedDirectory = dialog.open(); if (selectedDirectory != null) { fLinkLocation.setText(selectedDirectory); fRootDialogField.setText(selectedDirectory.substring(selectedDirectory.lastIndexOf(File.separatorChar) + 1)); JavaPlugin.getDefault().getDialogSettings().put(DIALOGSTORE_LAST_EXTERNAL_LOC, selectedDirectory); if (fAdapter != null) { fAdapter.dialogFieldChanged(fRootDialogField); } } }
Example #4
Source File: TodoTaskConfigurationBlock.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 6 votes |
protected final void updateModel(DialogField field) { if (field == fTodoTasksList) { StringBuffer tags= new StringBuffer(); StringBuffer prios= new StringBuffer(); List<TodoTask> list= fTodoTasksList.getElements(); for (int i= 0; i < list.size(); i++) { if (i > 0) { tags.append(','); prios.append(','); } TodoTask elem= list.get(i); tags.append(elem.name); prios.append(elem.priority); } setValue(PREF_COMPILER_TASK_TAGS, tags.toString()); setValue(PREF_COMPILER_TASK_PRIORITIES, prios.toString()); validateSettings(PREF_COMPILER_TASK_TAGS, null, null); } else if (field == fCaseSensitiveCheckBox) { String state= fCaseSensitiveCheckBox.isSelected() ? ENABLED : DISABLED; setValue(PREF_COMPILER_TASK_CASE_SENSITIVE, state); } }
Example #5
Source File: HistoryListAction.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 6 votes |
@Override protected Control createDialogArea(Composite parent) { initializeDialogUnits(parent); Composite composite= (Composite) super.createDialogArea(parent); Composite inner= new Composite(composite, SWT.NONE); inner.setLayoutData(new GridData(GridData.FILL_BOTH)); inner.setFont(composite.getFont()); LayoutUtil.doDefaultLayout(inner, new DialogField[] { fHistoryList }, true, 0, 0); LayoutUtil.setHeightHint(fHistoryList.getListControl(null), convertHeightInCharsToPixels(12)); LayoutUtil.setHorizontalGrabbing(fHistoryList.getListControl(null)); applyDialogFont(composite); return composite; }
Example #6
Source File: HistoryListAction.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 6 votes |
@Override protected Control createDialogArea(Composite parent) { initializeDialogUnits(parent); Composite composite= (Composite) super.createDialogArea(parent); Composite inner= new Composite(composite, SWT.NONE); inner.setFont(parent.getFont()); inner.setLayoutData(new GridData(GridData.FILL_BOTH)); LayoutUtil.doDefaultLayout(inner, new DialogField[] { fHistoryList }, true, 0, 0); LayoutUtil.setHeightHint(fHistoryList.getListControl(null), convertHeightInCharsToPixels(12)); LayoutUtil.setHorizontalGrabbing(fHistoryList.getListControl(null)); applyDialogFont(composite); return composite; }
Example #7
Source File: NameConventionConfigurationBlock.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 6 votes |
public NameConventionInputDialog(Shell parent, String title, String message, NameConventionEntry entry) { super(parent); fEntry= entry; setTitle(title); fMessageField= new DialogField(); fMessageField.setLabelText(message); fPrefixField= new StringDialogField(); fPrefixField.setLabelText(PreferencesMessages.NameConventionConfigurationBlock_dialog_prefix); fPrefixField.setDialogFieldListener(this); fSuffixField= new StringDialogField(); fSuffixField.setLabelText(PreferencesMessages.NameConventionConfigurationBlock_dialog_suffix); fSuffixField.setDialogFieldListener(this); fPrefixField.setText(entry.prefix); fSuffixField.setText(entry.suffix); }
Example #8
Source File: ImportOrganizeConfigurationBlock.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 6 votes |
protected final void doDialogFieldChanged(DialogField field) { // set values in working copy if (field == fOrderListField) { setValue(PREF_IMPORTORDER, packOrderList(fOrderListField.getElements())); } else if (field == fThresholdField) { if (doThresholdChanged(fThresholdField.getText())) { setValue(PREF_ONDEMANDTHRESHOLD, fThresholdField.getText()); } } else if (field == fStaticThresholdField) { if (doThresholdChanged(fStaticThresholdField.getText())) { setValue(PREF_STATICONDEMANDTHRESHOLD, fStaticThresholdField.getText()); } } else if (field == fIgnoreLowerCaseTypesField) { setValue(PREF_IGNORELOWERCASE, fIgnoreLowerCaseTypesField.isSelected()); } else if (field == fImportButton) { List<ImportOrderEntry> order= loadImportOrder(); if (order != null) { fOrderListField.setElements(order); } } else if (field == fExportButton) { saveImportOrder(fOrderListField.getElements()); } }
Example #9
Source File: SourceAttachmentBlock.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 6 votes |
private void attachmentDialogFieldChanged(DialogField field) { if (field == fVariableFileNameField) { fVariableNameStatus= updateFileNameStatus(fVariableFileNameField); } else if (field == fWorkspaceFileNameField) { fWorkspaceNameStatus= updateFileNameStatus(fWorkspaceFileNameField); } else if (field == fExternalFileNameField) { fExternalNameStatus= updateFileNameStatus(fExternalFileNameField); } else if (field == fExternalFolderButton) { IPath folderPath= chooseExtFolder(); if (folderPath != null) { fExternalFileNameField.setText(folderPath.toString()); } return; } doStatusLineUpdate(); }
Example #10
Source File: ClasspathContainerDefaultPage.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 6 votes |
/** * Constructor for ClasspathContainerDefaultPage. */ public ClasspathContainerDefaultPage() { super("ClasspathContainerDefaultPage"); //$NON-NLS-1$ setTitle(NewWizardMessages.ClasspathContainerDefaultPage_title); setDescription(NewWizardMessages.ClasspathContainerDefaultPage_description); setImageDescriptor(JavaPluginImages.DESC_WIZBAN_ADD_LIBRARY); fUsedPaths= new ArrayList<IPath>(); fEntryField= new StringDialogField(); fEntryField.setLabelText(NewWizardMessages.ClasspathContainerDefaultPage_path_label); fEntryField.setDialogFieldListener(new IDialogFieldListener() { public void dialogFieldChanged(DialogField field) { validatePath(); } }); validatePath(); }
Example #11
Source File: NLSAccessorConfigurationDialog.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
public void changeControlPressed(DialogField field) { if (field == fResourceBundleFile) { browseForPropertyFile(); } else if (field == fAccessorClassName) { browseForAccessorClass(); } }
Example #12
Source File: VariableCreationDialog.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
private void doChangeControlPressed(DialogField field) { if (field == fPathField) { IPath path= chooseExtJarFile(); if (path != null) { fPathField.setText(path.toString()); } } }
Example #13
Source File: NewClassWizardPage.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
private void createMethodStubSelectionControls(Composite composite, int nColumns) { Control labelControl= fMethodStubsButtons.getLabelControl(composite); LayoutUtil.setHorizontalSpan(labelControl, nColumns); DialogField.createEmptySpace(composite); Control buttonGroup= fMethodStubsButtons.getSelectionButtonsGroup(composite); LayoutUtil.setHorizontalSpan(buttonGroup, nColumns - 1); }
Example #14
Source File: NewPackageWizardPage.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
private void createPackageControls(Composite composite, int nColumns) { fPackageDialogField.doFillIntoGrid(composite, nColumns - 1); Text text= fPackageDialogField.getTextControl(null); LayoutUtil.setWidthHint(text, getMaxFieldWidth()); LayoutUtil.setHorizontalGrabbing(text); DialogField.createEmptySpace(composite); TextFieldNavigationHandler.install(text); fCreatePackageInfoJavaDialogField.doFillIntoGrid(composite, nColumns); BidiUtils.applyBidiProcessing(fPackageDialogField.getTextControl(null), StructuredTextTypeHandlerFactory.JAVA); }
Example #15
Source File: NewSourceFolderWizardPage.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
protected void packRootDialogFieldChanged(DialogField field) { if (field == fRootDialogField) { updateRootStatus(); } else if (field == fProjectField) { updateProjectStatus(); updateRootStatus(); } else if (field == fExcludeInOthersFields) { updateRootStatus(); } else if (field == fIgnoreOptionalProblemsField) { updateRootStatus(); } updateStatus(new IStatus[] { fProjectStatus, fRootStatus }); }
Example #16
Source File: PackageSelectionStringButtonAdapter.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
public void changeControlPressed(DialogField field) { IPackageFragmentRoot root= fPackageSelectionField.getSelectedFragmentRoot(); IJavaElement[] packages= null; try { if (root != null && root.exists()) { packages= root.getChildren(); } } catch (JavaModelException e) { // no need to react } if (packages == null) { packages= new IJavaElement[0]; } ElementListSelectionDialog dialog= new ElementListSelectionDialog(field.getLabelControl(null).getShell(), new JavaElementLabelProvider(JavaElementLabelProvider.SHOW_DEFAULT)); dialog.setIgnoreCase(true); dialog.setTitle(fTitle); dialog.setMessage(fMessage); dialog.setEmptyListMessage(fEmtpyListMessage); dialog.setElements(packages); // TODO initial selection // List selection = new ArrayList(); // selection.add(fPackageSelectionField.fPackageSelection.getPackageFragment()); // dialog.setInitialElementSelections(selection); if (dialog.open() == Window.OK) { IPackageFragment fragment= (IPackageFragment)dialog.getFirstResult(); fPackageSelectionField.setSelected(fragment); } }
Example #17
Source File: PackageBrowseAdapter.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
public void changeControlPressed(DialogField field) { ElementListSelectionDialog dialog= new ElementListSelectionDialog( Display.getCurrent().getActiveShell(), new JavaElementLabelProvider()); dialog.setIgnoreCase(false); dialog.setTitle(NLSUIMessages.PackageBrowseAdapter_package_selection); dialog.setMessage(NLSUIMessages.PackageBrowseAdapter_choose_package); dialog.setElements(createPackageListInput(fCu, null)); if (dialog.open() == Window.OK) { IPackageFragment selectedPackage= (IPackageFragment)dialog.getFirstResult(); if (selectedPackage != null) { fReceiver.setPackage(selectedPackage); } } }
Example #18
Source File: ProjectsWorkbookPage.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
/** * @param field the dialog field */ private void projectPageSelectionChanged(DialogField field) { List<Object> selElements= fProjectsList.getSelectedElements(); fProjectsList.enableButton(IDX_EDIT, canEdit(selElements)); fProjectsList.enableButton(IDX_REMOVE, canRemove(selElements)); boolean enabled; try { enabled= getNotYetRequiredProjects().length > 0; } catch (JavaModelException ex) { enabled= false; } fProjectsList.enableButton(IDX_ADDPROJECT, enabled); }
Example #19
Source File: CleanUpConfigurationBlock.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
/** * {@inheritDoc} */ @Override public Composite createContents(Composite parent) { Composite composite= super.createContents(parent); if (fCurrContext == null) return composite; fShowCleanUpWizardDialogField= new SelectionButtonDialogField(SWT.CHECK); fShowCleanUpWizardDialogField.setLabelText(CleanUpMessages.CleanUpConfigurationBlock_ShowCleanUpWizard_checkBoxLabel); fShowCleanUpWizardDialogField.doFillIntoGrid(composite, 5); IEclipsePreferences node= fCurrContext.getNode(JavaUI.ID_PLUGIN); boolean showWizard; if (node.get(CleanUpConstants.SHOW_CLEAN_UP_WIZARD, null) != null) { showWizard= node.getBoolean(CleanUpConstants.SHOW_CLEAN_UP_WIZARD, true); } else { showWizard= DefaultScope.INSTANCE.getNode(JavaUI.ID_PLUGIN).getBoolean(CleanUpConstants.SHOW_CLEAN_UP_WIZARD, true); } if (showWizard) fShowCleanUpWizardDialogField.setSelection(true); fShowCleanUpWizardDialogField.setDialogFieldListener(new IDialogFieldListener() { public void dialogFieldChanged(DialogField field) { doShowCleanUpWizard(fShowCleanUpWizardDialogField.isSelected()); } }); return composite; }
Example #20
Source File: VariableBlock.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
/** * @param field the dialog field */ private void doSelectionChanged(DialogField field) { List<CPVariableElement> selected= fVariablesList.getSelectedElements(); boolean containsReadOnly= containsReadOnly(selected); // edit fVariablesList.enableButton(1, canEdit(selected, containsReadOnly)); // remove button fVariablesList.enableButton(2, !containsReadOnly); fSelectedElements= selected; updateDeprecationWarning(); }
Example #21
Source File: NewContainerWizardPage.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
private void containerChangeControlPressed(DialogField field) { if (field == fContainerDialogField) { // take the current jproject as init element of the dialog IPackageFragmentRoot root= chooseContainer(); if (root != null) { setPackageFragmentRoot(root, true); } } }
Example #22
Source File: ProjectsWorkbookPage.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
/** * @param field the dialog field */ private void projectPageDialogFieldChanged(DialogField field) { if (fCurrJProject != null) { // already initialized updateClasspathList(); } }
Example #23
Source File: BuildPathsBlock.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
private void buildPathChangeControlPressed(DialogField field) { if (field == fBuildPathDialogField) { IContainer container= chooseContainer(); if (container != null) { fBuildPathDialogField.setText(container.getFullPath().makeRelative().toString()); } } }
Example #24
Source File: AbstractNewSarlElementWizardPage.java From sarl with Apache License 2.0 | 5 votes |
/** Create the controls related to the behavior units to generate. * * @param composite the container of the controls. * @param columns the number of columns. * @param enableConstructors indicates if the constructor creation is enable. * @param enableInherited indicates if the inherited operation creation is enable. * @param defaultEvents indicates if the default events will be generated. * @param lifecycleFunctions indicates if the default lifecycle functions will be generated. */ protected void createMethodStubControls(Composite composite, int columns, boolean enableConstructors, boolean enableInherited, boolean defaultEvents, boolean lifecycleFunctions) { this.isConstructorCreationEnabled = enableConstructors; this.isInheritedCreationEnabled = enableInherited; this.isDefaultEventGenerated = defaultEvents; this.isDefaultLifecycleFunctionsGenerated = lifecycleFunctions; final List<String> nameList = new ArrayList<>(4); if (enableConstructors) { nameList.add(Messages.AbstractNewSarlElementWizardPage_0); } if (enableInherited) { nameList.add(Messages.AbstractNewSarlElementWizardPage_1); } if (defaultEvents) { nameList.add(Messages.AbstractNewSarlElementWizardPage_17); } if (lifecycleFunctions) { nameList.add(Messages.AbstractNewSarlElementWizardPage_18); } if (nameList.isEmpty()) { return; } final String[] buttonNames = new String[nameList.size()]; nameList.toArray(buttonNames); this.methodStubsButtons = new SelectionButtonDialogFieldGroup(SWT.CHECK, buttonNames, 1); this.methodStubsButtons.setLabelText(Messages.AbstractNewSarlElementWizardPage_2); final Control labelControl = this.methodStubsButtons.getLabelControl(composite); LayoutUtil.setHorizontalSpan(labelControl, columns); DialogField.createEmptySpace(composite); final Control buttonGroup = this.methodStubsButtons.getSelectionButtonsGroup(composite); LayoutUtil.setHorizontalSpan(buttonGroup, columns - 1); }
Example #25
Source File: CategoryFilterActionGroup.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
/** * {@inheritDoc} */ @Override protected Control createDialogArea(Composite parent) { Composite composite= (Composite) super.createDialogArea(parent); LayoutUtil.doDefaultLayout(composite, new DialogField[] { fCategoryList }, true, 5, 5); LayoutUtil.setHorizontalGrabbing(fCategoryList.getListControl(null)); Dialog.applyDialogFont(composite); setHelpAvailable(false); PlatformUI.getWorkbench().getHelpSystem().setHelp(parent, IJavaHelpContextIds.VISIBLE_CATEGORIES_DIALOG); return composite; }
Example #26
Source File: MembersOrderPreferencePage.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
@Override protected Control createContents(Composite parent) { // Create both the dialog lists Composite sortComposite= new Composite(parent, SWT.NONE); sortComposite.setFont(parent.getFont()); GridLayout layout= new GridLayout(); layout.numColumns= 2; layout.marginWidth= 0; layout.marginHeight= 0; sortComposite.setLayout(layout); GridData gd= new GridData(); gd.verticalAlignment= GridData.FILL; gd.horizontalAlignment= GridData.FILL_HORIZONTAL; sortComposite.setLayoutData(gd); createListDialogField(sortComposite, fSortOrderList); fUseVisibilitySortField= new SelectionButtonDialogField(SWT.CHECK); fUseVisibilitySortField.setDialogFieldListener(new IDialogFieldListener() { public void dialogFieldChanged(DialogField field) { fVisibilityOrderList.setEnabled(fUseVisibilitySortField.isSelected()); } }); fUseVisibilitySortField.setLabelText(PreferencesMessages.MembersOrderPreferencePage_usevisibilitysort_label); fUseVisibilitySortField.doFillIntoGrid(sortComposite, 2); fUseVisibilitySortField.setSelection(fUseVisibilitySort); createListDialogField(sortComposite, fVisibilityOrderList); fVisibilityOrderList.setEnabled(fUseVisibilitySortField.isSelected()); Dialog.applyDialogFont(sortComposite); return sortComposite; }
Example #27
Source File: VariableCreationDialog.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
@Override protected Control createDialogArea(Composite parent) { Composite composite= (Composite) super.createDialogArea(parent); Composite inner= new Composite(composite, SWT.NONE); inner.setFont(composite.getFont()); GridLayout layout= new GridLayout(); layout.marginWidth= 0; layout.marginHeight= 0; layout.numColumns= 4; inner.setLayout(layout); int fieldWidthHint= convertWidthInCharsToPixels(50); fNameField.doFillIntoGrid(inner, 2); LayoutUtil.setWidthHint(fNameField.getTextControl(null), fieldWidthHint); LayoutUtil.setHorizontalGrabbing(fNameField.getTextControl(null)); DialogField.createEmptySpace(inner, 2); fPathField.doFillIntoGrid(inner, 3); LayoutUtil.setWidthHint(fPathField.getTextControl(null), fieldWidthHint); BidiUtils.applyBidiProcessing(fPathField.getTextControl(null), StructuredTextTypeHandlerFactory.FILE); fDirButton.doFillIntoGrid(inner, 1); DialogField focusField= (fElement == null) ? fNameField : fPathField; focusField.postSetFocusOnDialogField(parent.getDisplay()); applyDialogFont(composite); return composite; }
Example #28
Source File: LibrariesWorkbookPage.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
/** * @param field the dialog field */ private void libaryPageDialogFieldChanged(DialogField field) { if (fCurrJProject != null) { // already initialized updateClasspathList(); } }
Example #29
Source File: SourceContainerWorkbookPage.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
@Override public Control getControl(Composite parent) { PixelConverter converter= new PixelConverter(parent); Composite composite= new Composite(parent, SWT.NONE); LayoutUtil.doDefaultLayout(composite, new DialogField[] { fFoldersList, fUseFolderOutputs , fOutputLocationField}, true, SWT.DEFAULT, SWT.DEFAULT); BidiUtils.applyBidiProcessing(fOutputLocationField.getTextControl(null), StructuredTextTypeHandlerFactory.FILE); LayoutUtil.setHorizontalGrabbing(fFoldersList.getTreeControl(null)); int buttonBarWidth= converter.convertWidthInCharsToPixels(24); fFoldersList.setButtonsMinWidth(buttonBarWidth); fSWTControl= composite; // expand List<CPListElement> elements= fFoldersList.getElements(); for (int i= 0; i < elements.size(); i++) { CPListElement elem= elements.get(i); IPath[] exclusionPatterns= (IPath[]) elem.getAttribute(CPListElement.EXCLUSION); IPath[] inclusionPatterns= (IPath[]) elem.getAttribute(CPListElement.INCLUSION); IPath output= (IPath) elem.getAttribute(CPListElement.OUTPUT); if (exclusionPatterns.length > 0 || inclusionPatterns.length > 0 || output != null) { fFoldersList.expandElement(elem, 3); } } return composite; }
Example #30
Source File: ClasspathOrderingWorkbookPage.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
@Override public Control getControl(Composite parent) { PixelConverter converter= new PixelConverter(parent); Composite composite= new Composite(parent, SWT.NONE); composite.setFont(parent.getFont()); LayoutUtil.doDefaultLayout(composite, new DialogField[] { fClassPathList }, true, SWT.DEFAULT, SWT.DEFAULT); LayoutUtil.setHorizontalGrabbing(fClassPathList.getListControl(null)); int buttonBarWidth= converter.convertWidthInCharsToPixels(24); fClassPathList.setButtonsMinWidth(buttonBarWidth); return composite; }